Commit f56a48e8 authored by rodolph.perfetta's avatar rodolph.perfetta Committed by Commit Bot

[instruction scheduler] fix ArchDebugBreak.

In TurboFan the ArchDebugBreak opcode is not used for debugging but to
force a crash in unreachable or unimplemented code path. The opcode was
marked as having no side effects allowing the scheduler to bring it "up"
with unfortunate consequences.

This patch also update the behaviour of assembler::debug when not using
the simulator.

Review-Url: https://codereview.chromium.org/2901383004
Cr-Commit-Position: refs/heads/master@{#45608}
parent 9ca164d0
......@@ -2348,7 +2348,7 @@ void Assembler::debug(const char* message, uint32_t code, Instr params) {
#endif
if (params & BREAK) {
hlt(kImmExceptionIsDebug);
brk(0);
}
}
......
......@@ -3889,7 +3889,9 @@ void Simulator::VisitException(Instruction* instr) {
}
break;
}
case BRK:
base::OS::DebugBreak();
break;
default:
UNIMPLEMENTED();
}
......
......@@ -244,7 +244,6 @@ int InstructionScheduler::GetInstructionFlags(const Instruction* instr) const {
case kArchParentFramePointer:
case kArchTruncateDoubleToI:
case kArchStackSlot:
case kArchDebugBreak:
case kArchComment:
case kIeee754Float64Acos:
case kIeee754Float64Acosh:
......@@ -292,6 +291,7 @@ int InstructionScheduler::GetInstructionFlags(const Instruction* instr) const {
case kArchLookupSwitch:
case kArchTableSwitch:
case kArchRet:
case kArchDebugBreak:
case kArchThrowTerminator:
return kIsBlockTerminator;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment