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

Side by Side Diff: src/x87/lithium-x87.h

Issue 1228113008: Crankshaft part of the 'loads and stores to global vars through property cell shortcuts' feature. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Addressed comments + regression test Created 5 years, 5 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
« no previous file with comments | « src/x87/lithium-codegen-x87.cc ('k') | src/x87/lithium-x87.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_X87_LITHIUM_X87_H_ 5 #ifndef V8_X87_LITHIUM_X87_H_
6 #define V8_X87_LITHIUM_X87_H_ 6 #define V8_X87_LITHIUM_X87_H_
7 7
8 #include "src/hydrogen.h" 8 #include "src/hydrogen.h"
9 #include "src/lithium.h" 9 #include "src/lithium.h"
10 #include "src/lithium-allocator.h" 10 #include "src/lithium-allocator.h"
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
99 V(IsObjectAndBranch) \ 99 V(IsObjectAndBranch) \
100 V(IsStringAndBranch) \ 100 V(IsStringAndBranch) \
101 V(IsSmiAndBranch) \ 101 V(IsSmiAndBranch) \
102 V(IsUndetectableAndBranch) \ 102 V(IsUndetectableAndBranch) \
103 V(Label) \ 103 V(Label) \
104 V(LazyBailout) \ 104 V(LazyBailout) \
105 V(LoadContextSlot) \ 105 V(LoadContextSlot) \
106 V(LoadFieldByIndex) \ 106 V(LoadFieldByIndex) \
107 V(LoadFunctionPrototype) \ 107 V(LoadFunctionPrototype) \
108 V(LoadGlobalGeneric) \ 108 V(LoadGlobalGeneric) \
109 V(LoadGlobalViaContext) \
109 V(LoadKeyed) \ 110 V(LoadKeyed) \
110 V(LoadKeyedGeneric) \ 111 V(LoadKeyedGeneric) \
111 V(LoadNamedField) \ 112 V(LoadNamedField) \
112 V(LoadNamedGeneric) \ 113 V(LoadNamedGeneric) \
113 V(LoadRoot) \ 114 V(LoadRoot) \
114 V(MapEnumLength) \ 115 V(MapEnumLength) \
115 V(MathAbs) \ 116 V(MathAbs) \
116 V(MathClz32) \ 117 V(MathClz32) \
117 V(MathExp) \ 118 V(MathExp) \
118 V(MathFloor) \ 119 V(MathFloor) \
(...skipping 20 matching lines...) Expand all
139 V(Return) \ 140 V(Return) \
140 V(SeqStringGetChar) \ 141 V(SeqStringGetChar) \
141 V(SeqStringSetChar) \ 142 V(SeqStringSetChar) \
142 V(ShiftI) \ 143 V(ShiftI) \
143 V(SmiTag) \ 144 V(SmiTag) \
144 V(SmiUntag) \ 145 V(SmiUntag) \
145 V(StackCheck) \ 146 V(StackCheck) \
146 V(StoreCodeEntry) \ 147 V(StoreCodeEntry) \
147 V(StoreContextSlot) \ 148 V(StoreContextSlot) \
148 V(StoreFrameContext) \ 149 V(StoreFrameContext) \
150 V(StoreGlobalViaContext) \
149 V(StoreKeyed) \ 151 V(StoreKeyed) \
150 V(StoreKeyedGeneric) \ 152 V(StoreKeyedGeneric) \
151 V(StoreNamedField) \ 153 V(StoreNamedField) \
152 V(StoreNamedGeneric) \ 154 V(StoreNamedGeneric) \
153 V(StringAdd) \ 155 V(StringAdd) \
154 V(StringCharCodeAt) \ 156 V(StringCharCodeAt) \
155 V(StringCharFromCode) \ 157 V(StringCharFromCode) \
156 V(StringCompareAndBranch) \ 158 V(StringCompareAndBranch) \
157 V(SubI) \ 159 V(SubI) \
158 V(TaggedToI) \ 160 V(TaggedToI) \
(...skipping 1559 matching lines...) Expand 10 before | Expand all | Expand 10 after
1718 LOperand* temp_vector() { return temps_[0]; } 1720 LOperand* temp_vector() { return temps_[0]; }
1719 1721
1720 DECLARE_CONCRETE_INSTRUCTION(LoadGlobalGeneric, "load-global-generic") 1722 DECLARE_CONCRETE_INSTRUCTION(LoadGlobalGeneric, "load-global-generic")
1721 DECLARE_HYDROGEN_ACCESSOR(LoadGlobalGeneric) 1723 DECLARE_HYDROGEN_ACCESSOR(LoadGlobalGeneric)
1722 1724
1723 Handle<Object> name() const { return hydrogen()->name(); } 1725 Handle<Object> name() const { return hydrogen()->name(); }
1724 TypeofMode typeof_mode() const { return hydrogen()->typeof_mode(); } 1726 TypeofMode typeof_mode() const { return hydrogen()->typeof_mode(); }
1725 }; 1727 };
1726 1728
1727 1729
1730 class LLoadGlobalViaContext final : public LTemplateInstruction<1, 1, 1> {
1731 public:
1732 explicit LLoadGlobalViaContext(LOperand* context) { inputs_[0] = context; }
1733
1734 DECLARE_CONCRETE_INSTRUCTION(LoadGlobalViaContext, "load-global-via-context")
1735 DECLARE_HYDROGEN_ACCESSOR(LoadGlobalViaContext)
1736
1737 void PrintDataTo(StringStream* stream) override;
1738
1739 LOperand* context() { return inputs_[0]; }
1740
1741 Handle<Object> name() const { return hydrogen()->name(); }
1742 int depth() const { return hydrogen()->depth(); }
1743 int slot_index() const { return hydrogen()->slot_index(); }
1744 };
1745
1746
1728 class LLoadContextSlot final : public LTemplateInstruction<1, 1, 0> { 1747 class LLoadContextSlot final : public LTemplateInstruction<1, 1, 0> {
1729 public: 1748 public:
1730 explicit LLoadContextSlot(LOperand* context) { 1749 explicit LLoadContextSlot(LOperand* context) {
1731 inputs_[0] = context; 1750 inputs_[0] = context;
1732 } 1751 }
1733 1752
1734 LOperand* context() { return inputs_[0]; } 1753 LOperand* context() { return inputs_[0]; }
1735 1754
1736 DECLARE_CONCRETE_INSTRUCTION(LoadContextSlot, "load-context-slot") 1755 DECLARE_CONCRETE_INSTRUCTION(LoadContextSlot, "load-context-slot")
1737 DECLARE_HYDROGEN_ACCESSOR(LoadContextSlot) 1756 DECLARE_HYDROGEN_ACCESSOR(LoadContextSlot)
(...skipping 468 matching lines...) Expand 10 before | Expand all | Expand 10 after
2206 2225
2207 DECLARE_CONCRETE_INSTRUCTION(StoreNamedGeneric, "store-named-generic") 2226 DECLARE_CONCRETE_INSTRUCTION(StoreNamedGeneric, "store-named-generic")
2208 DECLARE_HYDROGEN_ACCESSOR(StoreNamedGeneric) 2227 DECLARE_HYDROGEN_ACCESSOR(StoreNamedGeneric)
2209 2228
2210 void PrintDataTo(StringStream* stream) override; 2229 void PrintDataTo(StringStream* stream) override;
2211 Handle<Object> name() const { return hydrogen()->name(); } 2230 Handle<Object> name() const { return hydrogen()->name(); }
2212 LanguageMode language_mode() { return hydrogen()->language_mode(); } 2231 LanguageMode language_mode() { return hydrogen()->language_mode(); }
2213 }; 2232 };
2214 2233
2215 2234
2235 class LStoreGlobalViaContext final : public LTemplateInstruction<0, 2, 0> {
2236 public:
2237 LStoreGlobalViaContext(LOperand* context, LOperand* value) {
2238 inputs_[0] = context;
2239 inputs_[1] = value;
2240 }
2241
2242 LOperand* context() { return inputs_[0]; }
2243 LOperand* value() { return inputs_[1]; }
2244
2245 DECLARE_CONCRETE_INSTRUCTION(StoreGlobalViaContext,
2246 "store-global-via-context")
2247 DECLARE_HYDROGEN_ACCESSOR(StoreGlobalViaContext)
2248
2249 void PrintDataTo(StringStream* stream) override;
2250
2251 Handle<Object> name() const { return hydrogen()->name(); }
2252 int depth() { return hydrogen()->depth(); }
2253 int slot_index() { return hydrogen()->slot_index(); }
2254 LanguageMode language_mode() { return hydrogen()->language_mode(); }
2255 };
2256
2257
2216 class LStoreKeyed final : public LTemplateInstruction<0, 3, 0> { 2258 class LStoreKeyed final : public LTemplateInstruction<0, 3, 0> {
2217 public: 2259 public:
2218 LStoreKeyed(LOperand* obj, LOperand* key, LOperand* val) { 2260 LStoreKeyed(LOperand* obj, LOperand* key, LOperand* val) {
2219 inputs_[0] = obj; 2261 inputs_[0] = obj;
2220 inputs_[1] = key; 2262 inputs_[1] = key;
2221 inputs_[2] = val; 2263 inputs_[2] = val;
2222 } 2264 }
2223 2265
2224 bool is_external() const { return hydrogen()->is_external(); } 2266 bool is_external() const { return hydrogen()->is_external(); }
2225 bool is_fixed_typed_array() const { 2267 bool is_fixed_typed_array() const {
(...skipping 676 matching lines...) Expand 10 before | Expand all | Expand 10 after
2902 2944
2903 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); 2945 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder);
2904 }; 2946 };
2905 2947
2906 #undef DECLARE_HYDROGEN_ACCESSOR 2948 #undef DECLARE_HYDROGEN_ACCESSOR
2907 #undef DECLARE_CONCRETE_INSTRUCTION 2949 #undef DECLARE_CONCRETE_INSTRUCTION
2908 2950
2909 } } // namespace v8::internal 2951 } } // namespace v8::internal
2910 2952
2911 #endif // V8_X87_LITHIUM_X87_H_ 2953 #endif // V8_X87_LITHIUM_X87_H_
OLDNEW
« no previous file with comments | « src/x87/lithium-codegen-x87.cc ('k') | src/x87/lithium-x87.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698