From be24b71ffe3fb5d8807ddb4972cfe4fa7c6414bb Mon Sep 17 00:00:00 2001 From: "svenpanne@chromium.org" Date: Thu, 14 Jul 2011 07:44:04 +0000 Subject: [PATCH] Harmonize naming a bit, x64 was the only platform where Register::from_code was called Register::toRegister. Review URL: http://codereview.chromium.org/7364001 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8648 ce2b1a6d-e550-0410-aec6-3dcde31c8c00 --- src/x64/assembler-x64.h | 2 +- src/x64/deoptimizer-x64.cc | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/x64/assembler-x64.h b/src/x64/assembler-x64.h index 4c12904147..c23eb16897 100644 --- a/src/x64/assembler-x64.h +++ b/src/x64/assembler-x64.h @@ -125,7 +125,7 @@ struct Register { return names[index]; } - static Register toRegister(int code) { + static Register from_code(int code) { Register r = { code }; return r; } diff --git a/src/x64/deoptimizer-x64.cc b/src/x64/deoptimizer-x64.cc index 7eb08f7e0d..6f48320bbf 100644 --- a/src/x64/deoptimizer-x64.cc +++ b/src/x64/deoptimizer-x64.cc @@ -643,7 +643,7 @@ void Deoptimizer::EntryGenerator::Generate() { // We push all registers onto the stack, even though we do not need // to restore all later. for (int i = 0; i < kNumberOfRegisters; i++) { - Register r = Register::toRegister(i); + Register r = Register::from_code(i); __ push(r); } @@ -801,12 +801,12 @@ void Deoptimizer::EntryGenerator::Generate() { // Restore the registers from the stack. for (int i = kNumberOfRegisters - 1; i >= 0 ; i--) { - Register r = Register::toRegister(i); + Register r = Register::from_code(i); // Do not restore rsp, simply pop the value into the next register // and overwrite this afterwards. if (r.is(rsp)) { ASSERT(i > 0); - r = Register::toRegister(i - 1); + r = Register::from_code(i - 1); } __ pop(r); }