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

Side by Side Diff: src/x64/macro-assembler-x64.cc

Issue 218025: Rename JumpToBuiltin to JumpToRuntime. Add comment to ResolveBuiltin. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 11 years, 3 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/x64/macro-assembler-x64.h ('k') | no next file » | 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 314 matching lines...) Expand 10 before | Expand all | Expand 10 after
325 // -- rsp[8] : argument num_arguments - 1 325 // -- rsp[8] : argument num_arguments - 1
326 // ... 326 // ...
327 // -- rsp[8 * num_arguments] : argument 0 (receiver) 327 // -- rsp[8 * num_arguments] : argument 0 (receiver)
328 // ----------------------------------- 328 // -----------------------------------
329 329
330 // TODO(1236192): Most runtime routines don't need the number of 330 // TODO(1236192): Most runtime routines don't need the number of
331 // arguments passed in because it is constant. At some point we 331 // arguments passed in because it is constant. At some point we
332 // should remove this need and make the runtime routine entry code 332 // should remove this need and make the runtime routine entry code
333 // smarter. 333 // smarter.
334 movq(rax, Immediate(num_arguments)); 334 movq(rax, Immediate(num_arguments));
335 JumpToBuiltin(ext, result_size); 335 JumpToRuntime(ext, result_size);
336 } 336 }
337 337
338 338
339 void MacroAssembler::JumpToBuiltin(const ExternalReference& ext, 339 void MacroAssembler::JumpToRuntime(const ExternalReference& ext,
340 int result_size) { 340 int result_size) {
341 // Set the entry point and jump to the C entry runtime stub. 341 // Set the entry point and jump to the C entry runtime stub.
342 movq(rbx, ext); 342 movq(rbx, ext);
343 CEntryStub ces(result_size); 343 CEntryStub ces(result_size);
344 movq(kScratchRegister, ces.GetCode(), RelocInfo::CODE_TARGET); 344 movq(kScratchRegister, ces.GetCode(), RelocInfo::CODE_TARGET);
345 jmp(kScratchRegister); 345 jmp(kScratchRegister);
346 } 346 }
347 347
348 348
349 void MacroAssembler::GetBuiltinEntry(Register target, Builtins::JavaScript id) { 349 void MacroAssembler::GetBuiltinEntry(Register target, Builtins::JavaScript id) {
(...skipping 1820 matching lines...) Expand 10 before | Expand all | Expand 10 after
2170 // Indicate that code has changed. 2170 // Indicate that code has changed.
2171 CPU::FlushICache(address_, size_); 2171 CPU::FlushICache(address_, size_);
2172 2172
2173 // Check that the code was patched as expected. 2173 // Check that the code was patched as expected.
2174 ASSERT(masm_.pc_ == address_ + size_); 2174 ASSERT(masm_.pc_ == address_ + size_);
2175 ASSERT(masm_.reloc_info_writer.pos() == address_ + size_ + Assembler::kGap); 2175 ASSERT(masm_.reloc_info_writer.pos() == address_ + size_ + Assembler::kGap);
2176 } 2176 }
2177 2177
2178 2178
2179 } } // namespace v8::internal 2179 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/x64/macro-assembler-x64.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698