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

Side by Side Diff: src/x64/builtins-x64.cc

Issue 3146008: Change lazy compilation stub to a builtin.... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 10 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/stub-cache.cc ('k') | src/x64/stub-cache-x64.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2009 the V8 project authors. All rights reserved. 1 // Copyright 2009 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 1273 matching lines...) Expand 10 before | Expand all | Expand 10 after
1284 1284
1285 void Builtins::Generate_JSEntryTrampoline(MacroAssembler* masm) { 1285 void Builtins::Generate_JSEntryTrampoline(MacroAssembler* masm) {
1286 Generate_JSEntryTrampolineHelper(masm, false); 1286 Generate_JSEntryTrampolineHelper(masm, false);
1287 } 1287 }
1288 1288
1289 1289
1290 void Builtins::Generate_JSConstructEntryTrampoline(MacroAssembler* masm) { 1290 void Builtins::Generate_JSConstructEntryTrampoline(MacroAssembler* masm) {
1291 Generate_JSEntryTrampolineHelper(masm, true); 1291 Generate_JSEntryTrampolineHelper(masm, true);
1292 } 1292 }
1293 1293
1294
1295 void Builtins::Generate_LazyCompile(MacroAssembler* masm) {
1296 // Enter an internal frame.
1297 __ EnterInternalFrame();
1298
1299 // Push a copy of the function onto the stack.
1300 __ push(rdi);
1301
1302 __ push(rdi); // Function is also the parameter to the runtime call.
1303 __ CallRuntime(Runtime::kLazyCompile, 1);
1304 __ pop(rdi);
1305
1306 // Tear down temporary frame.
1307 __ LeaveInternalFrame();
1308
1309 // Do a tail-call of the compiled function.
1310 __ lea(rcx, FieldOperand(rax, Code::kHeaderSize));
1311 __ jmp(rcx);
1312 }
1313
1294 } } // namespace v8::internal 1314 } } // namespace v8::internal
1295 1315
1296 #endif // V8_TARGET_ARCH_X64 1316 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/stub-cache.cc ('k') | src/x64/stub-cache-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698