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

Unified Diff: src/objects-inl.h

Issue 1019293003: Fix broken JSFunction::is_compiled predicate. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Remove stray assert. Created 5 years, 9 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 | « src/objects.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/objects-inl.h
diff --git a/src/objects-inl.h b/src/objects-inl.h
index 94a3cb3c947a63512d0515cee178bc5e47bcbee5..c588f8345c90fb8098aee8239ff8a59df0c0596d 100644
--- a/src/objects-inl.h
+++ b/src/objects-inl.h
@@ -5843,7 +5843,10 @@ void SharedFunctionInfo::set_scope_info(ScopeInfo* value,
bool SharedFunctionInfo::is_compiled() {
- return code() != GetIsolate()->builtins()->builtin(Builtins::kCompileLazy);
+ Builtins* builtins = GetIsolate()->builtins();
+ DCHECK(code() != builtins->builtin(Builtins::kCompileOptimizedConcurrent));
+ DCHECK(code() != builtins->builtin(Builtins::kCompileOptimized));
+ return code() != builtins->builtin(Builtins::kCompileLazy);
}
@@ -6126,7 +6129,10 @@ bool JSFunction::should_have_prototype() {
bool JSFunction::is_compiled() {
- return code() != GetIsolate()->builtins()->builtin(Builtins::kCompileLazy);
+ Builtins* builtins = GetIsolate()->builtins();
+ return code() != builtins->builtin(Builtins::kCompileLazy) &&
+ code() != builtins->builtin(Builtins::kCompileOptimized) &&
+ code() != builtins->builtin(Builtins::kCompileOptimizedConcurrent);
}
« no previous file with comments | « src/objects.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698