Chromium Code Reviews| Index: runtime/vm/assembler_ia32.cc |
| =================================================================== |
| --- runtime/vm/assembler_ia32.cc (revision 3058) |
| +++ runtime/vm/assembler_ia32.cc (working copy) |
| @@ -9,9 +9,13 @@ |
| #include "vm/heap.h" |
| #include "vm/memory_region.h" |
| #include "vm/runtime_entry.h" |
| +#include "vm/stub_code.h" |
| namespace dart { |
| +DEFINE_FLAG(bool, print_stop_message, true, "Print stop message."); |
| + |
| + |
| class DirectCallRelocation : public AssemblerFixup { |
| public: |
| void Process(const MemoryRegion& region, int position) { |
| @@ -1438,6 +1442,11 @@ |
| void Assembler::Stop(const char* message) { |
| + if (FLAG_print_stop_message) { |
| + pushl(Immediate(reinterpret_cast<int32_t>(message))); |
| + call(&StubCode::PrintStopMessageLabel()); |
| + popl(EAX); |
|
Ivan Posva
2012/01/09 17:26:42
This destroys whatever was in EAX.
regis
2012/01/10 00:09:16
Done.
|
| + } |
| // Emit the message address as immediate operand in the test rax instruction, |
| // followed by the int3 instruction. |
| // Execution can be resumed with the 'cont' command in gdb. |