Index: src/arm/macro-assembler-arm.cc |
diff --git a/src/arm/macro-assembler-arm.cc b/src/arm/macro-assembler-arm.cc |
index 5b5b7ea52c17404350b7e09f04a743d5eb47a67c..4ffae76391a0430b49b1eedd7ce5da2ca9ebd4ac 100644 |
--- a/src/arm/macro-assembler-arm.cc |
+++ b/src/arm/macro-assembler-arm.cc |
@@ -2447,14 +2447,6 @@ bool MacroAssembler::AllowThisStubCall(CodeStub* stub) { |
} |
-void MacroAssembler::IllegalOperation(int num_arguments) { |
- if (num_arguments > 0) { |
- add(sp, sp, Operand(num_arguments * kPointerSize)); |
- } |
- LoadRoot(r0, Heap::kUndefinedValueRootIndex); |
-} |
- |
- |
void MacroAssembler::IndexFromHash(Register hash, Register index) { |
// If the hash field contains an array index pick it out. The assert checks |
// that the constants for the maximum number of digits for an array index |
@@ -2650,10 +2642,7 @@ void MacroAssembler::CallRuntime(const Runtime::Function* f, |
// If the expected number of arguments of the runtime function is |
// constant, we check that the actual number of arguments match the |
// expectation. |
- if (f->nargs >= 0 && f->nargs != num_arguments) { |
- IllegalOperation(num_arguments); |
- return; |
- } |
+ CHECK(f->nargs < 0 || f->nargs == num_arguments); |
// TODO(1236192): Most runtime routines don't need the number of |
// arguments passed in because it is constant. At some point we |