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

Side by Side Diff: src/compiler/ppc/code-generator-ppc.cc

Issue 1088993003: Replace OVERRIDE->override and FINAL->final since we now require C++11. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 8 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/compiler/pipeline.cc ('k') | src/compiler/ppc/instruction-selector-ppc.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 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 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 #include "src/compiler/code-generator.h" 5 #include "src/compiler/code-generator.h"
6 6
7 #include "src/compiler/code-generator-impl.h" 7 #include "src/compiler/code-generator-impl.h"
8 #include "src/compiler/gap-resolver.h" 8 #include "src/compiler/gap-resolver.h"
9 #include "src/compiler/node-matchers.h" 9 #include "src/compiler/node-matchers.h"
10 #include "src/ppc/macro-assembler-ppc.h" 10 #include "src/ppc/macro-assembler-ppc.h"
11 #include "src/scopes.h" 11 #include "src/scopes.h"
12 12
13 namespace v8 { 13 namespace v8 {
14 namespace internal { 14 namespace internal {
15 namespace compiler { 15 namespace compiler {
16 16
17 #define __ masm()-> 17 #define __ masm()->
18 18
19 19
20 #define kScratchReg r11 20 #define kScratchReg r11
21 21
22 22
23 // Adds PPC-specific methods to convert InstructionOperands. 23 // Adds PPC-specific methods to convert InstructionOperands.
24 class PPCOperandConverter FINAL : public InstructionOperandConverter { 24 class PPCOperandConverter final : public InstructionOperandConverter {
25 public: 25 public:
26 PPCOperandConverter(CodeGenerator* gen, Instruction* instr) 26 PPCOperandConverter(CodeGenerator* gen, Instruction* instr)
27 : InstructionOperandConverter(gen, instr) {} 27 : InstructionOperandConverter(gen, instr) {}
28 28
29 RCBit OutputRCBit() const { 29 RCBit OutputRCBit() const {
30 switch (instr_->flags_mode()) { 30 switch (instr_->flags_mode()) {
31 case kFlags_branch: 31 case kFlags_branch:
32 case kFlags_set: 32 case kFlags_set:
33 return SetRC; 33 return SetRC;
34 case kFlags_none: 34 case kFlags_none:
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 }; 110 };
111 111
112 112
113 static inline bool HasRegisterInput(Instruction* instr, size_t index) { 113 static inline bool HasRegisterInput(Instruction* instr, size_t index) {
114 return instr->InputAt(index)->IsRegister(); 114 return instr->InputAt(index)->IsRegister();
115 } 115 }
116 116
117 117
118 namespace { 118 namespace {
119 119
120 class OutOfLineLoadNAN32 FINAL : public OutOfLineCode { 120 class OutOfLineLoadNAN32 final : public OutOfLineCode {
121 public: 121 public:
122 OutOfLineLoadNAN32(CodeGenerator* gen, DoubleRegister result) 122 OutOfLineLoadNAN32(CodeGenerator* gen, DoubleRegister result)
123 : OutOfLineCode(gen), result_(result) {} 123 : OutOfLineCode(gen), result_(result) {}
124 124
125 void Generate() FINAL { 125 void Generate() final {
126 __ LoadDoubleLiteral(result_, std::numeric_limits<float>::quiet_NaN(), 126 __ LoadDoubleLiteral(result_, std::numeric_limits<float>::quiet_NaN(),
127 kScratchReg); 127 kScratchReg);
128 } 128 }
129 129
130 private: 130 private:
131 DoubleRegister const result_; 131 DoubleRegister const result_;
132 }; 132 };
133 133
134 134
135 class OutOfLineLoadNAN64 FINAL : public OutOfLineCode { 135 class OutOfLineLoadNAN64 final : public OutOfLineCode {
136 public: 136 public:
137 OutOfLineLoadNAN64(CodeGenerator* gen, DoubleRegister result) 137 OutOfLineLoadNAN64(CodeGenerator* gen, DoubleRegister result)
138 : OutOfLineCode(gen), result_(result) {} 138 : OutOfLineCode(gen), result_(result) {}
139 139
140 void Generate() FINAL { 140 void Generate() final {
141 __ LoadDoubleLiteral(result_, std::numeric_limits<double>::quiet_NaN(), 141 __ LoadDoubleLiteral(result_, std::numeric_limits<double>::quiet_NaN(),
142 kScratchReg); 142 kScratchReg);
143 } 143 }
144 144
145 private: 145 private:
146 DoubleRegister const result_; 146 DoubleRegister const result_;
147 }; 147 };
148 148
149 149
150 class OutOfLineLoadZero FINAL : public OutOfLineCode { 150 class OutOfLineLoadZero final : public OutOfLineCode {
151 public: 151 public:
152 OutOfLineLoadZero(CodeGenerator* gen, Register result) 152 OutOfLineLoadZero(CodeGenerator* gen, Register result)
153 : OutOfLineCode(gen), result_(result) {} 153 : OutOfLineCode(gen), result_(result) {}
154 154
155 void Generate() FINAL { __ li(result_, Operand::Zero()); } 155 void Generate() final { __ li(result_, Operand::Zero()); }
156 156
157 private: 157 private:
158 Register const result_; 158 Register const result_;
159 }; 159 };
160 160
161 161
162 Condition FlagsConditionToCondition(FlagsCondition condition) { 162 Condition FlagsConditionToCondition(FlagsCondition condition) {
163 switch (condition) { 163 switch (condition) {
164 case kEqual: 164 case kEqual:
165 return eq; 165 return eq;
(...skipping 1335 matching lines...) Expand 10 before | Expand all | Expand 10 after
1501 } 1501 }
1502 } 1502 }
1503 MarkLazyDeoptSite(); 1503 MarkLazyDeoptSite();
1504 } 1504 }
1505 1505
1506 #undef __ 1506 #undef __
1507 1507
1508 } // namespace compiler 1508 } // namespace compiler
1509 } // namespace internal 1509 } // namespace internal
1510 } // namespace v8 1510 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/pipeline.cc ('k') | src/compiler/ppc/instruction-selector-ppc.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698