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

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

Issue 1702313002: [crankshaft] Remove the useless HAllocateBlockContext instruction. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 10 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"
11 #include "src/safepoint-table.h" 11 #include "src/safepoint-table.h"
12 #include "src/utils.h" 12 #include "src/utils.h"
13 13
14 namespace v8 { 14 namespace v8 {
15 namespace internal { 15 namespace internal {
16 16
17 namespace compiler { 17 namespace compiler {
18 class RCodeVisualizer; 18 class RCodeVisualizer;
19 } 19 }
20 20
21 // Forward declarations. 21 // Forward declarations.
22 class LCodeGen; 22 class LCodeGen;
23 23
24 #define LITHIUM_CONCRETE_INSTRUCTION_LIST(V) \ 24 #define LITHIUM_CONCRETE_INSTRUCTION_LIST(V) \
25 V(AccessArgumentsAt) \ 25 V(AccessArgumentsAt) \
26 V(AddI) \ 26 V(AddI) \
27 V(AllocateBlockContext) \
28 V(Allocate) \ 27 V(Allocate) \
29 V(ApplyArguments) \ 28 V(ApplyArguments) \
30 V(ArgumentsElements) \ 29 V(ArgumentsElements) \
31 V(ArgumentsLength) \ 30 V(ArgumentsLength) \
32 V(ArithmeticD) \ 31 V(ArithmeticD) \
33 V(ArithmeticT) \ 32 V(ArithmeticT) \
34 V(BitI) \ 33 V(BitI) \
35 V(BoundsCheck) \ 34 V(BoundsCheck) \
36 V(Branch) \ 35 V(Branch) \
37 V(CallJSFunction) \ 36 V(CallJSFunction) \
(...skipping 2528 matching lines...) Expand 10 before | Expand all | Expand 10 after
2566 explicit LStoreFrameContext(LOperand* context) { 2565 explicit LStoreFrameContext(LOperand* context) {
2567 inputs_[0] = context; 2566 inputs_[0] = context;
2568 } 2567 }
2569 2568
2570 LOperand* context() { return inputs_[0]; } 2569 LOperand* context() { return inputs_[0]; }
2571 2570
2572 DECLARE_CONCRETE_INSTRUCTION(StoreFrameContext, "store-frame-context") 2571 DECLARE_CONCRETE_INSTRUCTION(StoreFrameContext, "store-frame-context")
2573 }; 2572 };
2574 2573
2575 2574
2576 class LAllocateBlockContext: public LTemplateInstruction<1, 2, 0> {
2577 public:
2578 LAllocateBlockContext(LOperand* context, LOperand* function) {
2579 inputs_[0] = context;
2580 inputs_[1] = function;
2581 }
2582
2583 LOperand* context() { return inputs_[0]; }
2584 LOperand* function() { return inputs_[1]; }
2585
2586 Handle<ScopeInfo> scope_info() { return hydrogen()->scope_info(); }
2587
2588 DECLARE_CONCRETE_INSTRUCTION(AllocateBlockContext, "allocate-block-context")
2589 DECLARE_HYDROGEN_ACCESSOR(AllocateBlockContext)
2590 };
2591
2592
2593 class LChunkBuilder; 2575 class LChunkBuilder;
2594 class LPlatformChunk final : public LChunk { 2576 class LPlatformChunk final : public LChunk {
2595 public: 2577 public:
2596 LPlatformChunk(CompilationInfo* info, HGraph* graph) 2578 LPlatformChunk(CompilationInfo* info, HGraph* graph)
2597 : LChunk(info, graph), 2579 : LChunk(info, graph),
2598 num_double_slots_(0) { } 2580 num_double_slots_(0) { }
2599 2581
2600 int GetNextSpillIndex(RegisterKind kind); 2582 int GetNextSpillIndex(RegisterKind kind);
2601 LOperand* GetNextSpillSlot(RegisterKind kind); 2583 LOperand* GetNextSpillSlot(RegisterKind kind);
2602 2584
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after
2745 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); 2727 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder);
2746 }; 2728 };
2747 2729
2748 #undef DECLARE_HYDROGEN_ACCESSOR 2730 #undef DECLARE_HYDROGEN_ACCESSOR
2749 #undef DECLARE_CONCRETE_INSTRUCTION 2731 #undef DECLARE_CONCRETE_INSTRUCTION
2750 2732
2751 } // namespace internal 2733 } // namespace internal
2752 } // namespace v8 2734 } // namespace v8
2753 2735
2754 #endif // V8_CRANKSHAFT_X87_LITHIUM_X87_H_ 2736 #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