OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gdb-7.1/] [gdb/] [testsuite/] [gdb.reverse/] [sigall-reverse.c] - Blame information for rev 231

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 227 jeremybenn
/* This testcase is part of GDB, the GNU debugger.
2
 
3
   Copyright 2009, 2010 Free Software Foundation, Inc.
4
 
5
   This program is free software; you can redistribute it and/or modify
6
   it under the terms of the GNU General Public License as published by
7
   the Free Software Foundation; either version 3 of the License, or
8
   (at your option) any later version.
9
 
10
   This program is distributed in the hope that it will be useful,
11
   but WITHOUT ANY WARRANTY; without even the implied warranty of
12
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13
   GNU General Public License for more details.
14
 
15
   You should have received a copy of the GNU General Public License
16
   along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
17
 
18
#include <signal.h>
19
#include <unistd.h>
20
 
21
#ifdef __sh__
22
#define signal(a,b)     /* Signals not supported on this target - make them go away */
23
#endif
24
 
25
/* Signal handlers, we set breakpoints in them to make sure that the
26
   signals really get delivered.  */
27
 
28
void
29
handle_ABRT (int sig)
30
{
31
}
32
 
33
void
34
handle_HUP (int sig)
35
{
36
}
37
 
38
void
39
handle_QUIT (int sig)
40
{
41
}
42
 
43
void
44
handle_ILL (int sig)
45
{
46
}
47
 
48
void
49
handle_EMT (int sig)
50
{
51
}
52
 
53
void
54
handle_FPE (int sig)
55
{
56
}
57
 
58
void
59
handle_BUS (int sig)
60
{
61
}
62
 
63
void
64
handle_SEGV (int sig)
65
{
66
}
67
 
68
void
69
handle_SYS (int sig)
70
{
71
}
72
 
73
void
74
handle_PIPE (int sig)
75
{
76
}
77
 
78
void
79
handle_ALRM (int sig)
80
{
81
}
82
 
83
void
84
handle_URG (int sig)
85
{
86
}
87
 
88
void
89
handle_TSTP (int sig)
90
{
91
}
92
 
93
void
94
handle_CONT (int sig)
95
{
96
}
97
 
98
void
99
handle_CHLD (int sig)
100
{
101
}
102
 
103
void
104
handle_TTIN (int sig)
105
{
106
}
107
 
108
void
109
handle_TTOU (int sig)
110
{
111
}
112
 
113
void
114
handle_IO (int sig)
115
{
116
}
117
 
118
void
119
handle_XCPU (int sig)
120
{
121
}
122
 
123
void
124
handle_XFSZ (int sig)
125
{
126
}
127
 
128
void
129
handle_VTALRM (int sig)
130
{
131
}
132
 
133
void
134
handle_PROF (int sig)
135
{
136
}
137
 
138
void
139
handle_WINCH (int sig)
140
{
141
}
142
 
143
void
144
handle_LOST (int sig)
145
{
146
}
147
 
148
void
149
handle_USR1 (int sig)
150
{
151
}
152
 
153
void
154
handle_USR2 (int sig)
155
{
156
}
157
 
158
void
159
handle_PWR (int sig)
160
{
161
}
162
 
163
void
164
handle_POLL (int sig)
165
{
166
}
167
 
168
void
169
handle_WIND (int sig)
170
{
171
}
172
 
173
void
174
handle_PHONE (int sig)
175
{
176
}
177
 
178
void
179
handle_WAITING (int sig)
180
{
181
}
182
 
183
void
184
handle_LWP (int sig)
185
{
186
}
187
 
188
void
189
handle_DANGER (int sig)
190
{
191
}
192
 
193
void
194
handle_GRANT (int sig)
195
{
196
}
197
 
198
void
199
handle_RETRACT (int sig)
200
{
201
}
202
 
203
void
204
handle_MSG (int sig)
205
{
206
}
207
 
208
void
209
handle_SOUND (int sig)
210
{
211
}
212
 
213
void
214
handle_SAK (int sig)
215
{
216
}
217
 
218
void
219
handle_PRIO (int sig)
220
{
221
}
222
 
223
void
224
handle_33 (int sig)
225
{
226
}
227
 
228
void
229
handle_34 (int sig)
230
{
231
}
232
 
233
void
234
handle_35 (int sig)
235
{
236
}
237
 
238
void
239
handle_36 (int sig)
240
{
241
}
242
 
243
void
244
handle_37 (int sig)
245
{
246
}
247
 
248
void
249
handle_38 (int sig)
250
{
251
}
252
 
253
void
254
handle_39 (int sig)
255
{
256
}
257
 
258
void
259
handle_40 (int sig)
260
{
261
}
262
 
263
void
264
handle_41 (int sig)
265
{
266
}
267
 
268
void
269
handle_42 (int sig)
270
{
271
}
272
 
273
void
274
handle_43 (int sig)
275
{
276
}
277
 
278
void
279
handle_44 (int sig)
280
{
281
}
282
 
283
void
284
handle_45 (int sig)
285
{
286
}
287
 
288
void
289
handle_46 (int sig)
290
{
291
}
292
 
293
void
294
handle_47 (int sig)
295
{
296
}
297
 
298
void
299
handle_48 (int sig)
300
{
301
}
302
 
303
void
304
handle_49 (int sig)
305
{
306
}
307
 
308
void
309
handle_50 (int sig)
310
{
311
}
312
 
313
void
314
handle_51 (int sig)
315
{
316
}
317
 
318
void
319
handle_52 (int sig)
320
{
321
}
322
 
323
void
324
handle_53 (int sig)
325
{
326
}
327
 
328
void
329
handle_54 (int sig)
330
{
331
}
332
 
333
void
334
handle_55 (int sig)
335
{
336
}
337
 
338
void
339
handle_56 (int sig)
340
{
341
}
342
 
343
void
344
handle_57 (int sig)
345
{
346
}
347
 
348
void
349
handle_58 (int sig)
350
{
351
}
352
 
353
void
354
handle_59 (int sig)
355
{
356
}
357
 
358
void
359
handle_60 (int sig)
360
{
361
}
362
 
363
void
364
handle_61 (int sig)
365
{
366
}
367
 
368
void
369
handle_62 (int sig)
370
{
371
}
372
 
373
void
374
handle_63 (int sig)
375
{
376
}
377
 
378
void
379
handle_TERM (int sig)
380
{
381
}
382
 
383
/* Functions to send signals.  These also serve as markers.  */
384
int
385
gen_ABRT (void)
386
{
387
  kill (getpid (), SIGABRT);
388
  return 0;
389
}
390
 
391
int
392
gen_HUP (void)
393
{
394
#ifdef SIGHUP
395
  kill (getpid (), SIGHUP);
396
#else
397
  handle_HUP (0);
398
#endif
399
return 0;
400
}
401
 
402
int
403
gen_QUIT (void)
404
{
405
#ifdef SIGQUIT
406
  kill (getpid (), SIGQUIT);
407
#else
408
  handle_QUIT (0);
409
#endif
410
return 0;
411
}
412
 
413
int
414
gen_ILL (void)
415
{
416
#ifdef SIGILL
417
  kill (getpid (), SIGILL);
418
#else
419
  handle_ILL (0);
420
#endif
421
return 0;
422
}
423
 
424
int
425
gen_EMT (void)
426
{
427
#ifdef SIGEMT
428
  kill (getpid (), SIGEMT);
429
#else
430
  handle_EMT (0);
431
#endif
432
return 0;
433
}
434
 
435
int x;
436
 
437
int
438
gen_FPE (void)
439
{
440
  /* The intent behind generating SIGFPE this way is to check the mapping
441
     from the CPU exception itself to the signals.  It would be nice to
442
     do the same for SIGBUS, SIGSEGV, etc., but I suspect that even this
443
     test might turn out to be insufficiently portable.  */
444
 
445
#if 0
446
  /* Loses on the PA because after the signal handler executes we try to
447
     re-execute the failing instruction again.  Perhaps we could siglongjmp
448
     out of the signal handler?  */
449
  /* The expect script looks for the word "kill"; don't delete it.  */
450
  return 5 / x; /* and we both started jumping up and down yelling kill */
451
#else
452
  kill (getpid (), SIGFPE);
453
#endif
454
return 0;
455
}
456
 
457
int
458
gen_BUS (void)
459
{
460
#ifdef SIGBUS
461
  kill (getpid (), SIGBUS);
462
#else
463
  handle_BUS (0);
464
#endif
465
return 0;
466
}
467
 
468
int
469
gen_SEGV (void)
470
{
471
#ifdef SIGSEGV
472
  kill (getpid (), SIGSEGV);
473
#else
474
  handle_SEGV (0);
475
#endif
476
return 0;
477
}
478
 
479
int
480
gen_SYS (void)
481
{
482
#ifdef SIGSYS
483
  kill (getpid (), SIGSYS);
484
#else
485
  handle_SYS (0);
486
#endif
487
return 0;
488
}
489
 
490
int
491
gen_PIPE (void)
492
{
493
#ifdef SIGPIPE
494
  kill (getpid (), SIGPIPE);
495
#else
496
  handle_PIPE (0);
497
#endif
498
return 0;
499
}
500
 
501
int
502
gen_ALRM (void)
503
{
504
#ifdef SIGALRM
505
  kill (getpid (), SIGALRM);
506
#else
507
  handle_ALRM (0);
508
#endif
509
return 0;
510
}
511
 
512
int
513
gen_URG (void)
514
{
515
#ifdef SIGURG
516
  kill (getpid (), SIGURG);
517
#else
518
  handle_URG (0);
519
#endif
520
return 0;
521
}
522
 
523
int
524
gen_TSTP (void)
525
{
526
#ifdef SIGTSTP
527
  kill (getpid (), SIGTSTP);
528
#else
529
  handle_TSTP (0);
530
#endif
531
return 0;
532
}
533
 
534
int
535
gen_CONT (void)
536
{
537
#ifdef SIGCONT
538
  kill (getpid (), SIGCONT);
539
#else
540
  handle_CONT (0);
541
#endif
542
return 0;
543
}
544
 
545
int
546
gen_CHLD (void)
547
{
548
#ifdef SIGCHLD
549
  kill (getpid (), SIGCHLD);
550
#else
551
  handle_CHLD (0);
552
#endif
553
return 0;
554
}
555
 
556
int
557
gen_TTIN (void)
558
{
559
#ifdef SIGTTIN
560
  kill (getpid (), SIGTTIN);
561
#else
562
  handle_TTIN (0);
563
#endif
564
return 0;
565
}
566
 
567
int
568
gen_TTOU (void)
569
{
570
#ifdef SIGTTOU
571
  kill (getpid (), SIGTTOU);
572
#else
573
  handle_TTOU (0);
574
#endif
575
return 0;
576
}
577
 
578
int
579
gen_IO (void)
580
{
581
#ifdef SIGIO
582
  kill (getpid (), SIGIO);
583
#else
584
  handle_IO (0);
585
#endif
586
return 0;
587
}
588
 
589
int
590
gen_XCPU (void)
591
{
592
#ifdef SIGXCPU
593
  kill (getpid (), SIGXCPU);
594
#else
595
  handle_XCPU (0);
596
#endif
597
return 0;
598
}
599
 
600
int
601
gen_XFSZ (void)
602
{
603
#ifdef SIGXFSZ
604
  kill (getpid (), SIGXFSZ);
605
#else
606
  handle_XFSZ (0);
607
#endif
608
return 0;
609
}
610
 
611
int
612
gen_VTALRM (void)
613
{
614
#ifdef SIGVTALRM
615
  kill (getpid (), SIGVTALRM);
616
#else
617
  handle_VTALRM (0);
618
#endif
619
return 0;
620
}
621
 
622
int
623
gen_PROF (void)
624
{
625
#ifdef SIGPROF
626
  kill (getpid (), SIGPROF);
627
#else
628
  handle_PROF (0);
629
#endif
630
return 0;
631
}
632
 
633
int
634
gen_WINCH (void)
635
{
636
#ifdef SIGWINCH
637
  kill (getpid (), SIGWINCH);
638
#else
639
  handle_WINCH (0);
640
#endif
641
return 0;
642
}
643
 
644
int
645
gen_LOST (void)
646
{
647
#if defined(SIGLOST) && (!defined(SIGABRT) || SIGLOST != SIGABRT)
648
  kill (getpid (), SIGLOST);
649
#else
650
  handle_LOST (0);
651
#endif
652
return 0;
653
}
654
 
655
int
656
gen_USR1 (void)
657
{
658
#ifdef SIGUSR1
659
  kill (getpid (), SIGUSR1);
660
#else
661
  handle_USR1 (0);
662
#endif
663
return 0;
664
}
665
 
666
int
667
gen_USR2 (void)
668
{
669
#ifdef SIGUSR2
670
  kill (getpid (), SIGUSR2);
671
#else
672
  handle_USR2 (0);
673
#endif
674
return 0;
675
}
676
 
677
int
678
gen_PWR (void)
679
{
680
#ifdef SIGPWR
681
  kill (getpid (), SIGPWR);
682
#else
683
  handle_PWR (0);
684
#endif
685
return 0;
686
}
687
 
688
int
689
gen_POLL (void)
690
{
691
#if defined (SIGPOLL) && (!defined (SIGIO) || SIGPOLL != SIGIO)
692
  kill (getpid (), SIGPOLL);
693
#else
694
  handle_POLL (0);
695
#endif
696
return 0;
697
}
698
 
699
int
700
gen_WIND (void)
701
{
702
#ifdef SIGWIND
703
  kill (getpid (), SIGWIND);
704
#else
705
  handle_WIND (0);
706
#endif
707
return 0;
708
}
709
 
710
int
711
gen_PHONE (void)
712
{
713
#ifdef SIGPHONE
714
  kill (getpid (), SIGPHONE);
715
#else
716
  handle_PHONE (0);
717
#endif
718
return 0;
719
}
720
 
721
int
722
gen_WAITING (void)
723
{
724
#ifdef SIGWAITING
725
  kill (getpid (), SIGWAITING);
726
#else
727
  handle_WAITING (0);
728
#endif
729
return 0;
730
}
731
 
732
int
733
gen_LWP (void)
734
{
735
#ifdef SIGLWP
736
  kill (getpid (), SIGLWP);
737
#else
738
  handle_LWP (0);
739
#endif
740
return 0;
741
}
742
 
743
int
744
gen_DANGER (void)
745
{
746
#ifdef SIGDANGER
747
  kill (getpid (), SIGDANGER);
748
#else
749
  handle_DANGER (0);
750
#endif
751
return 0;
752
}
753
 
754
int
755
gen_GRANT (void)
756
{
757
#ifdef SIGGRANT
758
  kill (getpid (), SIGGRANT);
759
#else
760
  handle_GRANT (0);
761
#endif
762
return 0;
763
}
764
 
765
int
766
gen_RETRACT (void)
767
{
768
#ifdef SIGRETRACT
769
  kill (getpid (), SIGRETRACT);
770
#else
771
  handle_RETRACT (0);
772
#endif
773
return 0;
774
}
775
 
776
int
777
gen_MSG (void)
778
{
779
#ifdef SIGMSG
780
  kill (getpid (), SIGMSG);
781
#else
782
  handle_MSG (0);
783
#endif
784
return 0;
785
}
786
 
787
int
788
gen_SOUND (void)
789
{
790
#ifdef SIGSOUND
791
  kill (getpid (), SIGSOUND);
792
#else
793
  handle_SOUND (0);
794
#endif
795
return 0;
796
}
797
 
798
int
799
gen_SAK (void)
800
{
801
#ifdef SIGSAK
802
  kill (getpid (), SIGSAK);
803
#else
804
  handle_SAK (0);
805
#endif
806
return 0;
807
}
808
 
809
int
810
gen_PRIO (void)
811
{
812
#ifdef SIGPRIO
813
  kill (getpid (), SIGPRIO);
814
#else
815
  handle_PRIO (0);
816
#endif
817
return 0;
818
}
819
 
820
int
821
gen_33 (void)
822
{
823
#ifdef SIG33
824
  kill (getpid (), 33);
825
#else
826
  handle_33 (0);
827
#endif
828
return 0;
829
}
830
 
831
int
832
gen_34 (void)
833
{
834
#ifdef SIG34
835
  kill (getpid (), 34);
836
#else
837
  handle_34 (0);
838
#endif
839
return 0;
840
}
841
 
842
int
843
gen_35 (void)
844
{
845
#ifdef SIG35
846
  kill (getpid (), 35);
847
#else
848
  handle_35 (0);
849
#endif
850
return 0;
851
}
852
 
853
int
854
gen_36 (void)
855
{
856
#ifdef SIG36
857
  kill (getpid (), 36);
858
#else
859
  handle_36 (0);
860
#endif
861
return 0;
862
}
863
 
864
int
865
gen_37 (void)
866
{
867
#ifdef SIG37
868
  kill (getpid (), 37);
869
#else
870
  handle_37 (0);
871
#endif
872
return 0;
873
}
874
 
875
int
876
gen_38 (void)
877
{
878
#ifdef SIG38
879
  kill (getpid (), 38);
880
#else
881
  handle_38 (0);
882
#endif
883
return 0;
884
}
885
 
886
int
887
gen_39 (void)
888
{
889
#ifdef SIG39
890
  kill (getpid (), 39);
891
#else
892
  handle_39 (0);
893
#endif
894
return 0;
895
}
896
 
897
int
898
gen_40 (void)
899
{
900
#ifdef SIG40
901
  kill (getpid (), 40);
902
#else
903
  handle_40 (0);
904
#endif
905
return 0;
906
}
907
 
908
int
909
gen_41 (void)
910
{
911
#ifdef SIG41
912
  kill (getpid (), 41);
913
#else
914
  handle_41 (0);
915
#endif
916
return 0;
917
}
918
 
919
int
920
gen_42 (void)
921
{
922
#ifdef SIG42
923
  kill (getpid (), 42);
924
#else
925
  handle_42 (0);
926
#endif
927
return 0;
928
}
929
 
930
int
931
gen_43 (void)
932
{
933
#ifdef SIG43
934
  kill (getpid (), 43);
935
#else
936
  handle_43 (0);
937
#endif
938
return 0;
939
}
940
 
941
int
942
gen_44 (void)
943
{
944
#ifdef SIG44
945
  kill (getpid (), 44);
946
#else
947
  handle_44 (0);
948
#endif
949
return 0;
950
}
951
 
952
int
953
gen_45 (void)
954
{
955
#ifdef SIG45
956
  kill (getpid (), 45);
957
#else
958
  handle_45 (0);
959
#endif
960
return 0;
961
}
962
 
963
int
964
gen_46 (void)
965
{
966
#ifdef SIG46
967
  kill (getpid (), 46);
968
#else
969
  handle_46 (0);
970
#endif
971
return 0;
972
}
973
 
974
int
975
gen_47 (void)
976
{
977
#ifdef SIG47
978
  kill (getpid (), 47);
979
#else
980
  handle_47 (0);
981
#endif
982
return 0;
983
}
984
 
985
int
986
gen_48 (void)
987
{
988
#ifdef SIG48
989
  kill (getpid (), 48);
990
#else
991
  handle_48 (0);
992
#endif
993
return 0;
994
}
995
 
996
int
997
gen_49 (void)
998
{
999
#ifdef SIG49
1000
  kill (getpid (), 49);
1001
#else
1002
  handle_49 (0);
1003
#endif
1004
return 0;
1005
}
1006
 
1007
int
1008
gen_50 (void)
1009
{
1010
#ifdef SIG50
1011
  kill (getpid (), 50);
1012
#else
1013
  handle_50 (0);
1014
#endif
1015
return 0;
1016
}
1017
 
1018
int
1019
gen_51 (void)
1020
{
1021
#ifdef SIG51
1022
  kill (getpid (), 51);
1023
#else
1024
  handle_51 (0);
1025
#endif
1026
return 0;
1027
}
1028
 
1029
int
1030
gen_52 (void)
1031
{
1032
#ifdef SIG52
1033
  kill (getpid (), 52);
1034
#else
1035
  handle_52 (0);
1036
#endif
1037
return 0;
1038
}
1039
 
1040
int
1041
gen_53 (void)
1042
{
1043
#ifdef SIG53
1044
  kill (getpid (), 53);
1045
#else
1046
  handle_53 (0);
1047
#endif
1048
return 0;
1049
}
1050
 
1051
int
1052
gen_54 (void)
1053
{
1054
#ifdef SIG54
1055
  kill (getpid (), 54);
1056
#else
1057
  handle_54 (0);
1058
#endif
1059
return 0;
1060
}
1061
 
1062
int
1063
gen_55 (void)
1064
{
1065
#ifdef SIG55
1066
  kill (getpid (), 55);
1067
#else
1068
  handle_55 (0);
1069
#endif
1070
return 0;
1071
}
1072
 
1073
int
1074
gen_56 (void)
1075
{
1076
#ifdef SIG56
1077
  kill (getpid (), 56);
1078
#else
1079
  handle_56 (0);
1080
#endif
1081
return 0;
1082
}
1083
 
1084
int
1085
gen_57 (void)
1086
{
1087
#ifdef SIG57
1088
  kill (getpid (), 57);
1089
#else
1090
  handle_57 (0);
1091
#endif
1092
return 0;
1093
}
1094
 
1095
int
1096
gen_58 (void)
1097
{
1098
#ifdef SIG58
1099
  kill (getpid (), 58);
1100
#else
1101
  handle_58 (0);
1102
#endif
1103
return 0;
1104
}
1105
 
1106
int
1107
gen_59 (void)
1108
{
1109
#ifdef SIG59
1110
  kill (getpid (), 59);
1111
#else
1112
  handle_59 (0);
1113
#endif
1114
return 0;
1115
}
1116
 
1117
int
1118
gen_60 (void)
1119
{
1120
#ifdef SIG60
1121
  kill (getpid (), 60);
1122
#else
1123
  handle_60 (0);
1124
#endif
1125
return 0;
1126
}
1127
 
1128
int
1129
gen_61 (void)
1130
{
1131
#ifdef SIG61
1132
  kill (getpid (), 61);
1133
#else
1134
  handle_61 (0);
1135
#endif
1136
return 0;
1137
}
1138
 
1139
int
1140
gen_62 (void)
1141
{
1142
#ifdef SIG62
1143
  kill (getpid (), 62);
1144
#else
1145
  handle_62 (0);
1146
#endif
1147
return 0;
1148
}
1149
 
1150
int
1151
gen_63 (void)
1152
{
1153
#ifdef SIG63
1154
  kill (getpid (), 63);
1155
#else
1156
  handle_63 (0);
1157
#endif
1158
return 0;
1159
}
1160
 
1161
int
1162
gen_TERM (void)
1163
{
1164
  kill (getpid (), SIGTERM);
1165
return 0;
1166
}
1167
 
1168
int
1169
main ()
1170
{
1171
#ifdef usestubs
1172
  set_debug_traps ();
1173
  breakpoint ();
1174
#endif
1175
 
1176
#ifdef SIG_SETMASK
1177
  /* Ensure all the signals aren't blocked.
1178
     The environment in which the testsuite is run may have blocked some
1179
     for whatever reason.  */
1180
  {
1181
    sigset_t newset;
1182
    sigemptyset (&newset);
1183
    sigprocmask (SIG_SETMASK, &newset, NULL);
1184
  }
1185
#endif
1186
 
1187
  signal (SIGABRT, handle_ABRT);
1188
#ifdef SIGHUP
1189
  signal (SIGHUP, handle_HUP);
1190
#endif
1191
#ifdef SIGQUIT
1192
  signal (SIGQUIT, handle_QUIT);
1193
#endif
1194
#ifdef SIGILL
1195
  signal (SIGILL, handle_ILL);
1196
#endif
1197
#ifdef SIGEMT
1198
  signal (SIGEMT, handle_EMT);
1199
#endif
1200
#ifdef SIGFPE
1201
  signal (SIGFPE, handle_FPE);
1202
#endif
1203
#ifdef SIGBUS
1204
  signal (SIGBUS, handle_BUS);
1205
#endif
1206
#ifdef SIGSEGV
1207
  signal (SIGSEGV, handle_SEGV);
1208
#endif
1209
#ifdef SIGSYS
1210
  signal (SIGSYS, handle_SYS);
1211
#endif
1212
#ifdef SIGPIPE
1213
  signal (SIGPIPE, handle_PIPE);
1214
#endif
1215
#ifdef SIGALRM
1216
  signal (SIGALRM, handle_ALRM);
1217
#endif
1218
#ifdef SIGURG
1219
  signal (SIGURG, handle_URG);
1220
#endif
1221
#ifdef SIGTSTP
1222
  signal (SIGTSTP, handle_TSTP);
1223
#endif
1224
#ifdef SIGCONT
1225
  signal (SIGCONT, handle_CONT);
1226
#endif
1227
#ifdef SIGCHLD
1228
  signal (SIGCHLD, handle_CHLD);
1229
#endif
1230
#ifdef SIGTTIN
1231
  signal (SIGTTIN, handle_TTIN);
1232
#endif
1233
#ifdef SIGTTOU
1234
  signal (SIGTTOU, handle_TTOU);
1235
#endif
1236
#ifdef SIGIO
1237
  signal (SIGIO, handle_IO);
1238
#endif
1239
#ifdef SIGXCPU
1240
  signal (SIGXCPU, handle_XCPU);
1241
#endif
1242
#ifdef SIGXFSZ
1243
  signal (SIGXFSZ, handle_XFSZ);
1244
#endif
1245
#ifdef SIGVTALRM
1246
  signal (SIGVTALRM, handle_VTALRM);
1247
#endif
1248
#ifdef SIGPROF
1249
  signal (SIGPROF, handle_PROF);
1250
#endif
1251
#ifdef SIGWINCH
1252
  signal (SIGWINCH, handle_WINCH);
1253
#endif
1254
#if defined(SIGLOST) && (!defined(SIGABRT) || SIGLOST != SIGABRT)
1255
  signal (SIGLOST, handle_LOST);
1256
#endif
1257
#ifdef SIGUSR1
1258
  signal (SIGUSR1, handle_USR1);
1259
#endif
1260
#ifdef SIGUSR2
1261
  signal (SIGUSR2, handle_USR2);
1262
#endif
1263
#ifdef SIGPWR
1264
  signal (SIGPWR, handle_PWR);
1265
#endif
1266
#if defined (SIGPOLL) && (!defined (SIGIO) || SIGPOLL != SIGIO)
1267
  signal (SIGPOLL, handle_POLL);
1268
#endif
1269
#ifdef SIGWIND
1270
  signal (SIGWIND, handle_WIND);
1271
#endif
1272
#ifdef SIGPHONE
1273
  signal (SIGPHONE, handle_PHONE);
1274
#endif
1275
#ifdef SIGWAITING
1276
  signal (SIGWAITING, handle_WAITING);
1277
#endif
1278
#ifdef SIGLWP
1279
  signal (SIGLWP, handle_LWP);
1280
#endif
1281
#ifdef SIGDANGER
1282
  signal (SIGDANGER, handle_DANGER);
1283
#endif
1284
#ifdef SIGGRANT
1285
  signal (SIGGRANT, handle_GRANT);
1286
#endif
1287
#ifdef SIGRETRACT
1288
  signal (SIGRETRACT, handle_RETRACT);
1289
#endif
1290
#ifdef SIGMSG
1291
  signal (SIGMSG, handle_MSG);
1292
#endif
1293
#ifdef SIGSOUND
1294
  signal (SIGSOUND, handle_SOUND);
1295
#endif
1296
#ifdef SIGSAK
1297
  signal (SIGSAK, handle_SAK);
1298
#endif
1299
#ifdef SIGPRIO
1300
  signal (SIGPRIO, handle_PRIO);
1301
#endif
1302
#ifdef __Lynx__
1303
  /* Lynx doesn't seem to have anything in signal.h for this.  */
1304
  signal (33, handle_33);
1305
  signal (34, handle_34);
1306
  signal (35, handle_35);
1307
  signal (36, handle_36);
1308
  signal (37, handle_37);
1309
  signal (38, handle_38);
1310
  signal (39, handle_39);
1311
  signal (40, handle_40);
1312
  signal (41, handle_41);
1313
  signal (42, handle_42);
1314
  signal (43, handle_43);
1315
  signal (44, handle_44);
1316
  signal (45, handle_45);
1317
  signal (46, handle_46);
1318
  signal (47, handle_47);
1319
  signal (48, handle_48);
1320
  signal (49, handle_49);
1321
  signal (50, handle_50);
1322
  signal (51, handle_51);
1323
  signal (52, handle_52);
1324
  signal (53, handle_53);
1325
  signal (54, handle_54);
1326
  signal (55, handle_55);
1327
  signal (56, handle_56);
1328
  signal (57, handle_57);
1329
  signal (58, handle_58);
1330
  signal (59, handle_59);
1331
  signal (60, handle_60);
1332
  signal (61, handle_61);
1333
  signal (62, handle_62);
1334
  signal (63, handle_63);
1335
#endif /* lynx */
1336
  signal (SIGTERM, handle_TERM);
1337
 
1338
  x = 0;
1339
 
1340
  gen_ABRT ();
1341
  gen_HUP ();
1342
  gen_QUIT ();
1343
  gen_ILL ();
1344
  gen_EMT ();
1345
  gen_FPE ();
1346
  gen_BUS ();
1347
  gen_SEGV ();
1348
  gen_SYS ();
1349
  gen_PIPE ();
1350
  gen_ALRM ();
1351
  gen_URG ();
1352
  gen_TSTP ();
1353
  gen_CONT ();
1354
  gen_CHLD ();
1355
  gen_TTIN ();
1356
  gen_TTOU ();
1357
  gen_IO ();
1358
  gen_XCPU ();
1359
  gen_XFSZ ();
1360
  gen_VTALRM ();
1361
  gen_PROF ();
1362
  gen_WINCH ();
1363
  gen_LOST ();
1364
  gen_USR1 ();
1365
  gen_USR2 ();
1366
  gen_PWR ();
1367
  gen_POLL ();
1368
  gen_WIND ();
1369
  gen_PHONE ();
1370
  gen_WAITING ();
1371
  gen_LWP ();
1372
  gen_DANGER ();
1373
  gen_GRANT ();
1374
  gen_RETRACT ();
1375
  gen_MSG ();
1376
  gen_SOUND ();
1377
  gen_SAK ();
1378
  gen_PRIO ();
1379
  gen_33 ();
1380
  gen_34 ();
1381
  gen_35 ();
1382
  gen_36 ();
1383
  gen_37 ();
1384
  gen_38 ();
1385
  gen_39 ();
1386
  gen_40 ();
1387
  gen_41 ();
1388
  gen_42 ();
1389
  gen_43 ();
1390
  gen_44 ();
1391
  gen_45 ();
1392
  gen_46 ();
1393
  gen_47 ();
1394
  gen_48 ();
1395
  gen_49 ();
1396
  gen_50 ();
1397
  gen_51 ();
1398
  gen_52 ();
1399
  gen_53 ();
1400
  gen_54 ();
1401
  gen_55 ();
1402
  gen_56 ();
1403
  gen_57 ();
1404
  gen_58 ();
1405
  gen_59 ();
1406
  gen_60 ();
1407
  gen_61 ();
1408
  gen_62 ();
1409
  gen_63 ();
1410
  gen_TERM ();
1411
 
1412
  return 0;      /* end of main */
1413
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.