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

Unified Diff: src/compiler/instruction.h

Issue 854703002: Reland "[turbofan] simplify gap ordering" (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/compiler/instruction.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/instruction.h
diff --git a/src/compiler/instruction.h b/src/compiler/instruction.h
index 1729d13c16a06cc6c261732edfb2f79ffcaa7b60..c1fdef4aacf648061ce94c1bb1b107e0adac8477 100644
--- a/src/compiler/instruction.h
+++ b/src/compiler/instruction.h
@@ -25,8 +25,7 @@ namespace compiler {
// A couple of reserved opcodes are used for internal use.
const InstructionCode kGapInstruction = -1;
-const InstructionCode kBlockStartInstruction = -2;
-const InstructionCode kSourcePositionInstruction = -3;
+const InstructionCode kSourcePositionInstruction = -2;
#define INSTRUCTION_OPERAND_LIST(V) \
V(Constant, CONSTANT, 0) \
@@ -494,10 +493,7 @@ class Instruction : public ZoneObject {
bool NeedsPointerMap() const { return IsCall(); }
bool HasPointerMap() const { return pointer_map_ != NULL; }
- bool IsGapMoves() const {
- return opcode() == kGapInstruction || opcode() == kBlockStartInstruction;
- }
- bool IsBlockStart() const { return opcode() == kBlockStartInstruction; }
+ bool IsGapMoves() const { return opcode() == kGapInstruction; }
bool IsSourcePosition() const {
return opcode() == kSourcePositionInstruction;
}
@@ -643,30 +639,6 @@ class GapInstruction : public Instruction {
};
-// This special kind of gap move instruction represents the beginning of a
-// block of code.
-class BlockStartInstruction FINAL : public GapInstruction {
- public:
- static BlockStartInstruction* New(Zone* zone) {
- void* buffer = zone->New(sizeof(BlockStartInstruction));
- return new (buffer) BlockStartInstruction();
- }
-
- static BlockStartInstruction* cast(Instruction* instr) {
- DCHECK(instr->IsBlockStart());
- return static_cast<BlockStartInstruction*>(instr);
- }
-
- static const BlockStartInstruction* cast(const Instruction* instr) {
- DCHECK(instr->IsBlockStart());
- return static_cast<const BlockStartInstruction*>(instr);
- }
-
- private:
- BlockStartInstruction() : GapInstruction(kBlockStartInstruction) {}
-};
-
-
class SourcePositionInstruction FINAL : public Instruction {
public:
static SourcePositionInstruction* New(Zone* zone, SourcePosition position) {
@@ -983,7 +955,7 @@ class InstructionSequence FINAL : public ZoneObject {
void AddGapMove(int index, InstructionOperand* from, InstructionOperand* to);
- BlockStartInstruction* GetBlockStart(BasicBlock::RpoNumber rpo) const;
+ GapInstruction* GetBlockStart(BasicBlock::RpoNumber rpo) const;
typedef InstructionDeque::const_iterator const_iterator;
const_iterator begin() const { return instructions_.begin(); }
« no previous file with comments | « no previous file | src/compiler/instruction.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698