Index: src/a64/lithium-codegen-a64.cc |
diff --git a/src/a64/lithium-codegen-a64.cc b/src/a64/lithium-codegen-a64.cc |
index 4766fa55fd078d3ad2d902732094fec8dc38cc0e..a0c0c7a804eb016f0990f7bd8d37d32148920e54 100644 |
--- a/src/a64/lithium-codegen-a64.cc |
+++ b/src/a64/lithium-codegen-a64.cc |
@@ -1507,7 +1507,11 @@ void LCodeGen::DoAllocate(LAllocate* instr) { |
if (instr->size()->IsConstantOperand()) { |
int32_t size = ToInteger32(LConstantOperand::cast(instr->size())); |
- __ Allocate(size, result, temp1, temp2, deferred->entry(), flags); |
+ if (size <= Page::kMaxRegularHeapObjectSize) { |
+ __ Allocate(size, result, temp1, temp2, deferred->entry(), flags); |
+ } else { |
+ __ B(deferred->entry()); |
+ } |
} else { |
Register size = ToRegister32(instr->size()); |
__ Sxtw(size.X(), size); |