| Index: src/compiler/instruction.h
|
| diff --git a/src/compiler/instruction.h b/src/compiler/instruction.h
|
| index 1740dfbf25b970054417d75c533ba95e8ea65366..19d50a530aa0b33a474b85efe81ea1dac1a68f68 100644
|
| --- a/src/compiler/instruction.h
|
| +++ b/src/compiler/instruction.h
|
| @@ -495,9 +495,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 IsGapMoves() const { return opcode() == kGapInstruction; }
|
| bool IsBlockStart() const { return opcode() == kBlockStartInstruction; }
|
| bool IsSourcePosition() const {
|
| return opcode() == kSourcePositionInstruction;
|
| @@ -601,7 +599,7 @@ class GapInstruction : public Instruction {
|
|
|
| static GapInstruction* New(Zone* zone) {
|
| void* buffer = zone->New(sizeof(GapInstruction));
|
| - return new (buffer) GapInstruction(kGapInstruction);
|
| + return new (buffer) GapInstruction();
|
| }
|
|
|
| static GapInstruction* cast(Instruction* instr) {
|
| @@ -614,24 +612,22 @@ class GapInstruction : public Instruction {
|
| return static_cast<const GapInstruction*>(instr);
|
| }
|
|
|
| - protected:
|
| - explicit GapInstruction(InstructionCode opcode) : Instruction(opcode) {
|
| + private:
|
| + GapInstruction() : Instruction(kGapInstruction) {
|
| parallel_moves_[BEFORE] = NULL;
|
| parallel_moves_[START] = NULL;
|
| parallel_moves_[END] = NULL;
|
| parallel_moves_[AFTER] = NULL;
|
| }
|
|
|
| - private:
|
| friend std::ostream& operator<<(std::ostream& os,
|
| const PrintableInstruction& instr);
|
| ParallelMove* parallel_moves_[LAST_INNER_POSITION + 1];
|
| };
|
|
|
|
|
| -// This special kind of gap move instruction represents the beginning of a
|
| -// block of code.
|
| -class BlockStartInstruction FINAL : public GapInstruction {
|
| +// This is a placeholder instruction marking the start of a block.
|
| +class BlockStartInstruction FINAL : public Instruction {
|
| public:
|
| static BlockStartInstruction* New(Zone* zone) {
|
| void* buffer = zone->New(sizeof(BlockStartInstruction));
|
| @@ -649,7 +645,7 @@ class BlockStartInstruction FINAL : public GapInstruction {
|
| }
|
|
|
| private:
|
| - BlockStartInstruction() : GapInstruction(kBlockStartInstruction) {}
|
| + BlockStartInstruction() : Instruction(kBlockStartInstruction) {}
|
| };
|
|
|
|
|
| @@ -957,7 +953,7 @@ class InstructionSequence FINAL : public ZoneObject {
|
|
|
| void AddGapMove(int index, InstructionOperand* from, InstructionOperand* to);
|
|
|
| - BlockStartInstruction* GetBlockStart(BasicBlock::RpoNumber rpo) const;
|
| + const BlockStartInstruction* GetBlockStart(BasicBlock::RpoNumber rpo) const;
|
|
|
| typedef InstructionDeque::const_iterator const_iterator;
|
| const_iterator begin() const { return instructions_.begin(); }
|
|
|