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

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

Issue 3402014: Generate inline code for contextual loads. (Closed)
Patch Set: Created 10 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
OLDNEW
1 // Copyright 2010 the V8 project authors. All rights reserved. 1 // Copyright 2010 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 1708 matching lines...) Expand 10 before | Expand all | Expand 10 after
1719 // The offset is in the 32-bit displacement of a seven byte 1719 // The offset is in the 32-bit displacement of a seven byte
1720 // memory-to-register move instruction (REX.W 0x88 ModR/M disp32), 1720 // memory-to-register move instruction (REX.W 0x88 ModR/M disp32),
1721 // so we add 3 to get the offset of the displacement. 1721 // so we add 3 to get the offset of the displacement.
1722 Address offset_address = 1722 Address offset_address =
1723 test_instruction_address + delta + kOffsetToLoadInstruction + 3; 1723 test_instruction_address + delta + kOffsetToLoadInstruction + 3;
1724 *reinterpret_cast<int*>(offset_address) = offset - kHeapObjectTag; 1724 *reinterpret_cast<int*>(offset_address) = offset - kHeapObjectTag;
1725 return true; 1725 return true;
1726 } 1726 }
1727 1727
1728 1728
1729 bool LoadIC::PatchInlinedContextualLoad(Address address,
1730 Object* map,
1731 Object* cell) {
1732 // TODO(<bug#>): implement this.
1733 return false;
1734 }
1735
1736
1729 // The offset from the inlined patch site to the start of the inlined 1737 // The offset from the inlined patch site to the start of the inlined
1730 // store instruction. 1738 // store instruction.
1731 const int StoreIC::kOffsetToStoreInstruction = 20; 1739 const int StoreIC::kOffsetToStoreInstruction = 20;
1732 1740
1733 1741
1734 bool StoreIC::PatchInlinedStore(Address address, Object* map, int offset) { 1742 bool StoreIC::PatchInlinedStore(Address address, Object* map, int offset) {
1735 // The address of the instruction following the call. 1743 // The address of the instruction following the call.
1736 Address test_instruction_address = 1744 Address test_instruction_address =
1737 address + Assembler::kCallTargetAddressOffset; 1745 address + Assembler::kCallTargetAddressOffset;
1738 1746
(...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after
1889 GenerateMiss(masm); 1897 GenerateMiss(masm);
1890 } 1898 }
1891 1899
1892 1900
1893 #undef __ 1901 #undef __
1894 1902
1895 1903
1896 } } // namespace v8::internal 1904 } } // namespace v8::internal
1897 1905
1898 #endif // V8_TARGET_ARCH_X64 1906 #endif // V8_TARGET_ARCH_X64
OLDNEW
« src/ia32/codegen-ia32.cc ('K') | « src/v8-counters.h ('k') | src/x64/stub-cache-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698