Guardian Programmer's Guide

Table Of Contents
Contents
Guardian Programmer’s Guide421922-014
xx
27. Fault-Tolerant Programming in C (continued)
27. Fault-Tolerant Programming in C (continued)
Updating State Information 27-11
Types of State Information 27-13
Updating Control State Information 27-14
Updating File State Information 27-15
Updating Application State Information 27-18
Guidelines for Updating State Information 27-18
Example of Updating State Information 27-20
Saving State Information for Multiple Disk Updates 27-23
Providing Communication Between the Primary and Backup Processes 27-23
Sending Messages From the Primary to the Backup 27-24
Receiving Messages in the Backup Process 27-25
Monitoring the Backup Process 27-26
Programming Considerations 27-27
Compile-Time and Linker Considerations 27-27
Run-Time Considerations 27-28
Comparison of Active Backup and Passive Backup 27-29
Active Backup Example 1 27-32
Program Declarations 27-35
Creating and Starting the Backup Process 27-39
Updating State Information 27-41
Primary and Backup Processing 27-43
Compiling and Running the Example 27-48
Example With Debugging Options 27-48
Active Backup Example 2 27-52
Program Declarations 27-53
Creating and Starting the Backup Process 27-58
Updating State Information 27-58
Primary and Backup Processing 27-59
Compiling and Running the Example 27-65
28. Using Floating-Point Formats
Differences Between Tandem and IEEE Floating-Point Formats 28-1
Building and Running IEEE Floating-Point Programs 28-2
Compiling and Linking Floating-Point Programs 28-2
Link-Time Consistency Checking 28-3
Run-Time Consistency Checking 28-4
Run-Time Support 28-4
Debugging Options 28-4