* trad-core.c (trad_unix_core_file_failing_signal): Use new macro
[deliverable/binutils-gdb.git] / sim / h8300 / p3.c
CommitLineData
ea6bbfba 1/* Interpreter fragment for the Hitachi H8/300 architecture simulator.
b0c9f026 2
ea6bbfba
SC
3 Written by Steve Chamberlain of Cygnus Support.
4 sac@cygnus.com
b0c9f026 5
ea6bbfba 6 This file is part of H8/300 sim
b0c9f026 7
b0c9f026 8
ea6bbfba 9 THIS SOFTWARE IS NOT COPYRIGHTED
b0c9f026 10
ea6bbfba
SC
11 Cygnus offers the following for use in the public domain. Cygnus
12 makes no warranty with regard to the software or it's performance
13 and the user accepts the software "AS IS" with all faults.
14
15 CYGNUS DISCLAIMS ANY WARRANTIES, EXPRESS OR IMPLIED, WITH REGARD TO
16 THIS SOFTWARE INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
17 MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
18
19*/
b0c9f026 20
19139515 21 movflags8:
19139515
SC
22 n = dst & 0x80;
23 z = !(dst & 0xff);
24 v = 0;
25goto next;
26 movflags16:
19139515
SC
27 n = dst & 0x8000;
28 z = !(dst & 0xffff);
29 v = 0;
30goto next;
31 aluflags8:
19139515
SC
32 n = dst & 0x80;
33 z = !(dst & 0xff);
34 v = ((srca & 0x80) == (srcb & 0x80)) && ((srca & 0x80) != (dst & 0x80));
35 c = dst & 0x100;
36 goto next;
37 aluflags16:
19139515
SC
38 n = dst & 0x8000;
39 z = !(dst & 0xffff);
40 v = ((srca & 0x8000) == (srcb & 0x8000)) && ((srca & 0x8000) != (dst & 0x8000));
41 c = dst & 0x10000;
42 goto next;
43 setflags:;
44SET_CCR(tmp);
62b66d6d 45 goto next;
19139515
SC
46 logflags:
47 shiftflags:
48 v = 0;
49 incflags:
19139515
SC
50 z = !(dst & 0xff);
51 n = dst & 0x80;
52goto next;
53 next: ;
54pc = npc;
62b66d6d
SC
55if (ni > checkfreq)
56{
57 ni = 0;
58 SAVE_INTERPRETER_STATE();
59 perifs();
60 LOAD_INTERPRETER_STATE();
06137fcb 61#ifdef __GO32__
62b66d6d
SC
62 if (kbhit())
63 saved_state.exception = SIGINT;
06137fcb 64#endif
62b66d6d
SC
65}
66ni++;
67} while (!saved_state.exception);
68
19139515 69
62b66d6d 70SAVE_INTERPRETER_STATE();
19139515 71}
This page took 0.040086 seconds and 4 git commands to generate.