1 /* BEGIN INCLUDE FILE lisp_faults.incl.pl1 */
 2 
 3 /*
 4  * Written 14 Aug 72 by D A Moon
 5  * Fault codes changed 4 Feb 73 by DAM, for user interrupt masking and new alarmclock facility
 6  * Names changed 16 Dec 1973 by DAM because of a name conflict with lisp_free_storage.incl.pl1
 7  * Modified 74.06.03 by DAM for new-arrays
 8  * Modified 74.12.16 by DAM to change meaning of 'masked'
 9  */
10 dcl (Alarmclock_fault init(2),
11      Cput_fault init(1),
12      Car_cdr_fault init(6),
13      Quit_fault init(4),
14      Array_fault init(5),
15      Zerodivide_fault init(7),
16      Underflow_fault init(8),
17      Old_store_fault init(9),           /* old/new array compatibility */
18      Pi_fault init(10)                  /* program_interrupt signal */
19     ) fixed bin static;
20 
21 
22           /* structure for saving info when a fault or an error ocuurs.
23              This structure gets pushed onto the unmkd pdl */
24 
25 dcl 1 fault_save aligned based (unm),
26       2 prev_frame bit(18)unaligned,              /* thread */
27       2 stack_ptr bit(18) unaligned,              /* rel(stack_ptr) at time frame was created */
28       2 sv_gc_inhibit bit(1) unaligned,           /* save lisp_static_vars_$garbage_collect_inhibit */
29       2 sv_masked like masked unaligned,          /* save lisp_static_vars_$masked - for err breaks in (nointerrupt t) mode */
30       2 code1 fixed bin,                          /* error code 1, 0 = not errprintable error */
31       2 code2 fixed bin,                          /* error code 2, for file system errors */
32       2 sv_array_info ptr,                        /* save array_info_for_store in stack header */
33       2 sv_rdr_label label,                       /* -> abnormal return from call to ios_$read */
34       2 sv_rdr_ptr ptr,                           /* datum used by reader for readlist control */
35       2 sv_rdr_state fixed bin,                   /* 0=normal, 1=wait for input, 2=readlist */
36       2 sv_array_offset fixed bin(18),            /* save array_offset_for_store in stack header */
37       2 padding bit(36),                          /* make structure an even number of words in size */
38       2 dat_ptr bit(18);                          /* rel ptr to marked pdl slot containing losing form */
39                                                   /* needed by errprint */
40                               /* size(fault_save) must be even */
41 
42 
43           /* declarations of the things that get saved here */
44 
45 dcl lisp_static_vars_$garbage_collect_inhibit bit(1) aligned external,
46     1 lisp_static_vars_$masked aligned external like masked,
47     lisp_static_vars_$pending_ctrl bit(1) aligned external, /* flag that we are doing stacked-up ctrl chars
48                                                                          right now, makes sure none get missed if ^G */
49     lisp_static_vars_$deferred_interrupt bit(1) aligned external,     /* when we  unmask, we test this to */
50                                                                       /* see if we must poll interrupts */
51     lisp_static_vars_$rdr_label label external,
52     lisp_static_vars_$rdr_ptr ptr external,
53     lisp_static_vars_$rdr_state fixed bin external,
54     gc_inhibit bit(1) aligned defined(lisp_static_vars_$garbage_collect_inhibit),
55     deferred_interrupt bit (1) aligned defined (lisp_static_vars_$deferred_interrupt),
56     1 masked aligned based(addr(lisp_static_vars_$masked)), /* defined causes fault in compiler */
57       2 against unaligned,                        /* things masked against: */
58         3 tty bit(1),                             /* tty control characters */
59         3 alarm bit(1),                           /* alarmclock interrupts */
60     pending_ctrl bit(1) aligned defined (lisp_static_vars_$pending_ctrl),
61      lisp_fault_handler_$set_mask entry(1 aligned like masked),
62     rdr_label label defined (lisp_static_vars_$rdr_label),
63     rdr_ptr ptr defined (lisp_static_vars_$rdr_ptr),
64     rdr_state fixed bin defined (lisp_static_vars_$rdr_state);
65 
66 
67 /* END INCLUDE FILE lisp_faults.incl.pl1 */
68