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

Unified Diff: src/builtins/x64/builtins-x64.cc

Issue 2401653002: [turbofan] Discard the shared code entry in the optimized code map. (Closed)
Patch Set: Comments and REBASE. Created 4 years, 2 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/builtins/mips64/builtins-mips64.cc ('k') | src/compiler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/builtins/x64/builtins-x64.cc
diff --git a/src/builtins/x64/builtins-x64.cc b/src/builtins/x64/builtins-x64.cc
index fb1c5982d3360c991fe2e8db5267fef3de6309d4..afd678fa25c353568031d0ef42050bc5de7d3e54 100644
--- a/src/builtins/x64/builtins-x64.cc
+++ b/src/builtins/x64/builtins-x64.cc
@@ -1031,7 +1031,6 @@ void Builtins::Generate_CompileLazy(MacroAssembler* masm) {
// -----------------------------------
// First lookup code, maybe we don't need to compile!
Label gotta_call_runtime;
- Label maybe_call_runtime;
Label try_shared;
Label loop_top, loop_bottom;
@@ -1085,13 +1084,10 @@ void Builtins::Generate_CompileLazy(MacroAssembler* masm) {
__ movp(entry, FieldOperand(map, index, times_pointer_size,
SharedFunctionInfo::kOffsetToPreviousCachedCode));
__ movp(entry, FieldOperand(entry, WeakCell::kValueOffset));
- __ JumpIfSmi(entry, &maybe_call_runtime);
+ __ JumpIfSmi(entry, &try_shared);
// Found literals and code. Get them into the closure and return.
__ leap(entry, FieldOperand(entry, Code::kHeaderSize));
-
- Label install_optimized_code_and_tailcall;
- __ bind(&install_optimized_code_and_tailcall);
__ movp(FieldOperand(closure, JSFunction::kCodeEntryOffset), entry);
__ RecordWriteCodeEntryField(closure, entry, r15);
@@ -1124,18 +1120,6 @@ void Builtins::Generate_CompileLazy(MacroAssembler* masm) {
// We found neither literals nor code.
__ jmp(&gotta_call_runtime);
- __ bind(&maybe_call_runtime);
-
- // Last possibility. Check the context free optimized code map entry.
- __ movp(entry, FieldOperand(map, FixedArray::kHeaderSize +
- SharedFunctionInfo::kSharedCodeIndex));
- __ movp(entry, FieldOperand(entry, WeakCell::kValueOffset));
- __ JumpIfSmi(entry, &try_shared);
-
- // Store code entry in the closure.
- __ leap(entry, FieldOperand(entry, Code::kHeaderSize));
- __ jmp(&install_optimized_code_and_tailcall);
-
__ bind(&try_shared);
// Is the full code valid?
__ movp(entry, FieldOperand(closure, JSFunction::kSharedFunctionInfoOffset));
« no previous file with comments | « src/builtins/mips64/builtins-mips64.cc ('k') | src/compiler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698