Index: src/full-codegen/ia32/full-codegen-ia32.cc |
diff --git a/src/full-codegen/ia32/full-codegen-ia32.cc b/src/full-codegen/ia32/full-codegen-ia32.cc |
index 953ba260be321981dd34d094b3a4f8d63486cec6..a0852b0d2181c0771653ce238aa21aad9b337b39 100644 |
--- a/src/full-codegen/ia32/full-codegen-ia32.cc |
+++ b/src/full-codegen/ia32/full-codegen-ia32.cc |
@@ -4160,6 +4160,11 @@ void FullCodeGenerator::EmitFastOneByteArrayJoin(CallRuntime* expr) { |
__ j(overflow, &bailout); |
__ shr(string_length, 1); |
+ |
+ // Bailout for large object allocations. |
+ __ cmp(string_length, Page::kMaxRegularHeapObjectSize); |
+ __ j(greater, &bailout); |
+ |
// Live registers and stack values: |
// string_length |
// elements |