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

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

Issue 1579613002: [builtins] Refactor the remaining Date builtins. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: As per offline discussion, remove the weird test, which does not add a lot of value. Created 4 years, 11 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/crankshaft/x87/lithium-codegen-x87.cc ('k') | src/crankshaft/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_CRANKSHAFT_X87_LITHIUM_X87_H_ 5 #ifndef V8_CRANKSHAFT_X87_LITHIUM_X87_H_
6 #define V8_CRANKSHAFT_X87_LITHIUM_X87_H_ 6 #define V8_CRANKSHAFT_X87_LITHIUM_X87_H_
7 7
8 #include "src/crankshaft/hydrogen.h" 8 #include "src/crankshaft/hydrogen.h"
9 #include "src/crankshaft/lithium.h" 9 #include "src/crankshaft/lithium.h"
10 #include "src/crankshaft/lithium-allocator.h" 10 #include "src/crankshaft/lithium-allocator.h"
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 V(CmpHoleAndBranch) \ 58 V(CmpHoleAndBranch) \
59 V(CmpMapAndBranch) \ 59 V(CmpMapAndBranch) \
60 V(CmpT) \ 60 V(CmpT) \
61 V(ConstantD) \ 61 V(ConstantD) \
62 V(ConstantE) \ 62 V(ConstantE) \
63 V(ConstantI) \ 63 V(ConstantI) \
64 V(ConstantS) \ 64 V(ConstantS) \
65 V(ConstantT) \ 65 V(ConstantT) \
66 V(ConstructDouble) \ 66 V(ConstructDouble) \
67 V(Context) \ 67 V(Context) \
68 V(DateField) \
69 V(DebugBreak) \ 68 V(DebugBreak) \
70 V(DeclareGlobals) \ 69 V(DeclareGlobals) \
71 V(Deoptimize) \ 70 V(Deoptimize) \
72 V(DivByConstI) \ 71 V(DivByConstI) \
73 V(DivByPowerOf2I) \ 72 V(DivByPowerOf2I) \
74 V(DivI) \ 73 V(DivI) \
75 V(DoubleBits) \ 74 V(DoubleBits) \
76 V(DoubleToI) \ 75 V(DoubleToI) \
77 V(DoubleToSmi) \ 76 V(DoubleToSmi) \
78 V(Drop) \ 77 V(Drop) \
(...skipping 1271 matching lines...) Expand 10 before | Expand all | Expand 10 after
1350 explicit LMapEnumLength(LOperand* value) { 1349 explicit LMapEnumLength(LOperand* value) {
1351 inputs_[0] = value; 1350 inputs_[0] = value;
1352 } 1351 }
1353 1352
1354 LOperand* value() { return inputs_[0]; } 1353 LOperand* value() { return inputs_[0]; }
1355 1354
1356 DECLARE_CONCRETE_INSTRUCTION(MapEnumLength, "map-enum-length") 1355 DECLARE_CONCRETE_INSTRUCTION(MapEnumLength, "map-enum-length")
1357 }; 1356 };
1358 1357
1359 1358
1360 class LDateField final : public LTemplateInstruction<1, 1, 1> {
1361 public:
1362 LDateField(LOperand* date, LOperand* temp, Smi* index)
1363 : index_(index) {
1364 inputs_[0] = date;
1365 temps_[0] = temp;
1366 }
1367
1368 LOperand* date() { return inputs_[0]; }
1369 LOperand* temp() { return temps_[0]; }
1370
1371 DECLARE_CONCRETE_INSTRUCTION(DateField, "date-field")
1372 DECLARE_HYDROGEN_ACCESSOR(DateField)
1373
1374 Smi* index() const { return index_; }
1375
1376 private:
1377 Smi* index_;
1378 };
1379
1380
1381 class LSeqStringGetChar final : public LTemplateInstruction<1, 2, 0> { 1359 class LSeqStringGetChar final : public LTemplateInstruction<1, 2, 0> {
1382 public: 1360 public:
1383 LSeqStringGetChar(LOperand* string, LOperand* index) { 1361 LSeqStringGetChar(LOperand* string, LOperand* index) {
1384 inputs_[0] = string; 1362 inputs_[0] = string;
1385 inputs_[1] = index; 1363 inputs_[1] = index;
1386 } 1364 }
1387 1365
1388 LOperand* string() const { return inputs_[0]; } 1366 LOperand* string() const { return inputs_[0]; }
1389 LOperand* index() const { return inputs_[1]; } 1367 LOperand* index() const { return inputs_[1]; }
1390 1368
(...skipping 1420 matching lines...) Expand 10 before | Expand all | Expand 10 after
2811 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); 2789 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder);
2812 }; 2790 };
2813 2791
2814 #undef DECLARE_HYDROGEN_ACCESSOR 2792 #undef DECLARE_HYDROGEN_ACCESSOR
2815 #undef DECLARE_CONCRETE_INSTRUCTION 2793 #undef DECLARE_CONCRETE_INSTRUCTION
2816 2794
2817 } // namespace internal 2795 } // namespace internal
2818 } // namespace v8 2796 } // namespace v8
2819 2797
2820 #endif // V8_CRANKSHAFT_X87_LITHIUM_X87_H_ 2798 #endif // V8_CRANKSHAFT_X87_LITHIUM_X87_H_
OLDNEW
« no previous file with comments | « src/crankshaft/x87/lithium-codegen-x87.cc ('k') | src/crankshaft/x87/lithium-x87.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698