OLD | NEW |
1 // Copyright 2008 the V8 project authors. All rights reserved. | 1 // Copyright 2008 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 15 matching lines...) Expand all Loading... |
26 // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 26 // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
27 | 27 |
28 | 28 |
29 // Declares a Simulator for ARM instructions if we are not generating a native | 29 // Declares a Simulator for ARM instructions if we are not generating a native |
30 // ARM binary. This Simulator allows us to run and debug ARM code generation on | 30 // ARM binary. This Simulator allows us to run and debug ARM code generation on |
31 // regular desktop machines. | 31 // regular desktop machines. |
32 // V8 calls into generated code by "calling" the CALL_GENERATED_CODE macro, | 32 // V8 calls into generated code by "calling" the CALL_GENERATED_CODE macro, |
33 // which will start execution in the Simulator or forwards to the real entry | 33 // which will start execution in the Simulator or forwards to the real entry |
34 // on a ARM HW platform. | 34 // on a ARM HW platform. |
35 | 35 |
36 #ifndef V8_SIMULATOR_ARM_H_ | 36 #ifndef V8_ARM_SIMULATOR_ARM_H_ |
37 #define V8_SIMULATOR_ARM_H_ | 37 #define V8_ARM_SIMULATOR_ARM_H_ |
38 | 38 |
39 #if defined(__arm__) | 39 #if defined(__arm__) |
40 | 40 |
41 // When running without a simulator we call the entry directly. | 41 // When running without a simulator we call the entry directly. |
42 #define CALL_GENERATED_CODE(entry, p0, p1, p2, p3, p4) \ | 42 #define CALL_GENERATED_CODE(entry, p0, p1, p2, p3, p4) \ |
43 reinterpret_cast<Object*>(entry(p0, p1, p2, p3, p4)) | 43 reinterpret_cast<Object*>(entry(p0, p1, p2, p3, p4)) |
44 | 44 |
45 // Calculated the stack limit beyond which we will throw stack overflow errors. | 45 // Calculated the stack limit beyond which we will throw stack overflow errors. |
46 // This macro must be called from a C++ method. It relies on being able to take | 46 // This macro must be called from a C++ method. It relies on being able to take |
47 // the address of "this" to get a value on the current execution stack and then | 47 // the address of "this" to get a value on the current execution stack and then |
(...skipping 146 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
194 | 194 |
195 // registered breakpoints | 195 // registered breakpoints |
196 Instr* break_pc_; | 196 Instr* break_pc_; |
197 instr_t break_instr_; | 197 instr_t break_instr_; |
198 }; | 198 }; |
199 | 199 |
200 } } // namespace assembler::arm | 200 } } // namespace assembler::arm |
201 | 201 |
202 #endif // defined(__arm__) | 202 #endif // defined(__arm__) |
203 | 203 |
204 #endif // V8_SIMULATOR_ARM_H_ | 204 #endif // V8_ARM_SIMULATOR_ARM_H_ |
OLD | NEW |