Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(421)

Unified Diff: src/ia32/macro-assembler-ia32.cc

Issue 2156923002: [builtins] Introduce a builtin for Abort(). (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Moved comment one line down. Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/ia32/macro-assembler-ia32.cc
diff --git a/src/ia32/macro-assembler-ia32.cc b/src/ia32/macro-assembler-ia32.cc
index 1a9d70dda5d171537ad23a34166b95c8276f348d..f97761788b8b78954b21a4a317b5e2cb73f33ec2 100644
--- a/src/ia32/macro-assembler-ia32.cc
+++ b/src/ia32/macro-assembler-ia32.cc
@@ -2951,16 +2951,17 @@ void MacroAssembler::Abort(BailoutReason reason) {
return;
}
#endif
-
- push(Immediate(reinterpret_cast<intptr_t>(Smi::FromInt(reason))));
+ // Check if Abort() has already been initialized.
+ DCHECK(isolate()->builtins()->Abort()->IsHeapObject());
+ Move(edx, Smi::FromInt(static_cast<int>(reason)));
Michael Starzinger 2016/07/18 08:51:11 nit: Empty newline before and after this block for
ahaas 2016/07/18 09:04:16 Done
// Disable stub call restrictions to always allow calls to abort.
if (!has_frame_) {
// We don't actually want to generate a pile of code for this, so just
// claim there is a stack frame, without generating one.
FrameScope scope(this, StackFrame::NONE);
- CallRuntime(Runtime::kAbort);
+ Call(isolate()->builtins()->Abort(), RelocInfo::CODE_TARGET);
} else {
- CallRuntime(Runtime::kAbort);
+ Call(isolate()->builtins()->Abort(), RelocInfo::CODE_TARGET);
}
// will not return here
int3();

Powered by Google App Engine
This is Rietveld 408576698