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

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

Issue 6716018: X64: Optimize access to external references. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 9 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 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 739 matching lines...) Expand 10 before | Expand all | Expand 10 after
750 // Do not restore rsp, simply pop the value into the next register 750 // Do not restore rsp, simply pop the value into the next register
751 // and overwrite this afterwards. 751 // and overwrite this afterwards.
752 if (r.is(rsp)) { 752 if (r.is(rsp)) {
753 ASSERT(i > 0); 753 ASSERT(i > 0);
754 r = Register::toRegister(i - 1); 754 r = Register::toRegister(i - 1);
755 } 755 }
756 __ pop(r); 756 __ pop(r);
757 } 757 }
758 758
759 // Set up the roots register. 759 // Set up the roots register.
760 ExternalReference roots_address = ExternalReference::roots_address();
William Hesse 2011/03/22 14:05:08 Could this be necessary for serialization reasons?
Lasse Reichstein 2011/03/22 14:12:21 I don't see how. It's a local variable that isn't
761 __ InitializeRootRegister(); 760 __ InitializeRootRegister();
762 __ InitializeSmiConstantRegister(); 761 __ InitializeSmiConstantRegister();
763 762
764 // Return to the continuation point. 763 // Return to the continuation point.
765 __ ret(0); 764 __ ret(0);
766 } 765 }
767 766
768 767
769 void Deoptimizer::TableEntryGenerator::GeneratePrologue() { 768 void Deoptimizer::TableEntryGenerator::GeneratePrologue() {
770 // Create a sequence of deoptimization entries. 769 // Create a sequence of deoptimization entries.
771 Label done; 770 Label done;
772 for (int i = 0; i < count(); i++) { 771 for (int i = 0; i < count(); i++) {
773 int start = masm()->pc_offset(); 772 int start = masm()->pc_offset();
774 USE(start); 773 USE(start);
775 __ push_imm32(i); 774 __ push_imm32(i);
776 __ jmp(&done); 775 __ jmp(&done);
777 ASSERT(masm()->pc_offset() - start == table_entry_size_); 776 ASSERT(masm()->pc_offset() - start == table_entry_size_);
778 } 777 }
779 __ bind(&done); 778 __ bind(&done);
780 } 779 }
781 780
782 #undef __ 781 #undef __
783 782
784 783
785 } } // namespace v8::internal 784 } } // namespace v8::internal
786 785
787 #endif // V8_TARGET_ARCH_X64 786 #endif // V8_TARGET_ARCH_X64
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698