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

Unified Diff: src/interpreter/bytecode-generator.cc

Issue 2228503004: [Interpreter] Don't try to create bytecode array if HasStackOverflow(). (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix test Created 4 years, 4 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
« no previous file with comments | « no previous file | test/mjsunit/regress/regress-635429.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/interpreter/bytecode-generator.cc
diff --git a/src/interpreter/bytecode-generator.cc b/src/interpreter/bytecode-generator.cc
index b4f03b73fd6e547c6d9ec15dbf90c4aa380dbf13..14a5b52b172492ef627c21a9323adf9b9f6656d6 100644
--- a/src/interpreter/bytecode-generator.cc
+++ b/src/interpreter/bytecode-generator.cc
@@ -629,6 +629,9 @@ BytecodeGenerator::BytecodeGenerator(CompilationInfo* info)
Handle<BytecodeArray> BytecodeGenerator::MakeBytecode() {
GenerateBytecode();
FinalizeBytecode();
+
+ if (HasStackOverflow()) return Handle<BytecodeArray>();
+
return builder()->ToBytecodeArray();
}
« no previous file with comments | « no previous file | test/mjsunit/regress/regress-635429.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698