src/hotspot/cpu/x86/macroAssembler_x86.cpp
changeset 58638 7be56b2ac50d
parent 58625 9b54aee889b4
parent 58536 1b76d17440a0
child 58679 9c3209ff7550
child 58977 c6a789f495fe
--- a/src/hotspot/cpu/x86/macroAssembler_x86.cpp	Fri Oct 04 13:44:11 2019 -0700
+++ b/src/hotspot/cpu/x86/macroAssembler_x86.cpp	Mon Oct 14 21:01:25 2019 +0000
@@ -824,11 +824,13 @@
 }
 
 void MacroAssembler::stop(const char* msg) {
-  address rip = pc();
-  pusha(); // get regs on stack
+  if (ShowMessageBoxOnError) {
+    address rip = pc();
+    pusha(); // get regs on stack
+    lea(c_rarg1, InternalAddress(rip));
+    movq(c_rarg2, rsp); // pass pointer to regs array
+  }
   lea(c_rarg0, ExternalAddress((address) msg));
-  lea(c_rarg1, InternalAddress(rip));
-  movq(c_rarg2, rsp); // pass pointer to regs array
   andq(rsp, -16); // align stack as required by ABI
   call(RuntimeAddress(CAST_FROM_FN_PTR(address, MacroAssembler::debug64)));
   hlt();