rsb.h 863 B

12345678910111213141516171819202122232425262728293031
  1. /* $Id$ */
  2. /* The Return Status Block contains, in push order:
  3. FIL, LIN, LB, PC, PI, rsbcode
  4. In a trap this is preceeded by:
  5. FRA, FRASize, FRA_def, trap_nr
  6. */
  7. /* offsets to be added to a local base */
  8. extern int rsb_rsbcode;
  9. extern int rsb_PI;
  10. extern int rsb_PC;
  11. extern int rsb_LB;
  12. extern int rsb_LIN;
  13. extern int rsb_FIL;
  14. extern int rsbsize;
  15. /* The last item stored in the Return Status Block is a word containing
  16. a code describing the type of the RSB.
  17. */
  18. #define RSBMASK 0xfff0
  19. #define RSBCODE 0x2b90 /* 0rrr rrrr rrrr 0000, r = random */
  20. #define RSB_STP (RSBCODE + 1) /* in first RSB */
  21. #define RSB_CAL (RSBCODE + 2) /* in RSB from call */
  22. #define RSB_RTT (RSBCODE + 3) /* in RSB from returnable trap */
  23. #define RSB_NRT (RSBCODE + 4) /* in RSB from non-returnable trap */
  24. #define is_LB(p) ((st_lds(p+rsb_rsbcode, wsize) & RSBMASK) == RSBCODE)