OLD | NEW |
1 // Copyright 2009 the V8 project authors. All rights reserved. | 1 // Copyright 2009 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 20 matching lines...) Expand all Loading... |
31 #include "codegen-inl.h" | 31 #include "codegen-inl.h" |
32 #include "debug.h" | 32 #include "debug.h" |
33 | 33 |
34 | 34 |
35 namespace v8 { | 35 namespace v8 { |
36 namespace internal { | 36 namespace internal { |
37 | 37 |
38 #ifdef ENABLE_DEBUGGER_SUPPORT | 38 #ifdef ENABLE_DEBUGGER_SUPPORT |
39 | 39 |
40 bool Debug::IsDebugBreakAtReturn(v8::internal::RelocInfo* rinfo) { | 40 bool Debug::IsDebugBreakAtReturn(v8::internal::RelocInfo* rinfo) { |
41 UNIMPLEMENTED(); | 41 ASSERT(RelocInfo::IsJSReturn(rinfo->rmode())); |
42 return false; | 42 // 11th byte of patch is 0x49, 11th byte of JS return is 0xCC (int3). |
| 43 ASSERT(*(rinfo->pc() + 10) == 0x49 || *(rinfo->pc() + 10) == 0xCC); |
| 44 return (*(rinfo->pc() + 10) == 0x49); |
43 } | 45 } |
44 | 46 |
45 void Debug::GenerateCallICDebugBreak(MacroAssembler* masm) { | 47 void Debug::GenerateCallICDebugBreak(MacroAssembler* masm) { |
46 masm->int3(); // UNIMPLEMENTED | 48 masm->int3(); // UNIMPLEMENTED |
47 } | 49 } |
48 | 50 |
49 void Debug::GenerateConstructCallDebugBreak(MacroAssembler* masm) { | 51 void Debug::GenerateConstructCallDebugBreak(MacroAssembler* masm) { |
50 masm->int3(); // UNIMPLEMENTED | 52 masm->int3(); // UNIMPLEMENTED |
51 } | 53 } |
52 | 54 |
(...skipping 21 matching lines...) Expand all Loading... |
74 masm->int3(); // UNIMPLEMENTED | 76 masm->int3(); // UNIMPLEMENTED |
75 } | 77 } |
76 | 78 |
77 void Debug::GenerateStubNoRegistersDebugBreak(MacroAssembler* masm) { | 79 void Debug::GenerateStubNoRegistersDebugBreak(MacroAssembler* masm) { |
78 masm->int3(); // UNIMPLEMENTED | 80 masm->int3(); // UNIMPLEMENTED |
79 } | 81 } |
80 | 82 |
81 #endif // ENABLE_DEBUGGER_SUPPORT | 83 #endif // ENABLE_DEBUGGER_SUPPORT |
82 | 84 |
83 } } // namespace v8::internal | 85 } } // namespace v8::internal |
OLD | NEW |