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

Side by Side Diff: src/compiler/instruction-selector-impl.h

Issue 600383002: [turbofan] Add backend support for Float32Constant. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Add InstructionSelector unit test. Created 6 years, 2 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 | Annotate | Revision Log
« no previous file with comments | « src/compiler/instruction-selector.cc ('k') | src/compiler/instruction-selector-unittest.h » ('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 #ifndef V8_COMPILER_INSTRUCTION_SELECTOR_IMPL_H_ 5 #ifndef V8_COMPILER_INSTRUCTION_SELECTOR_IMPL_H_
6 #define V8_COMPILER_INSTRUCTION_SELECTOR_IMPL_H_ 6 #define V8_COMPILER_INSTRUCTION_SELECTOR_IMPL_H_
7 7
8 #include "src/compiler/instruction.h" 8 #include "src/compiler/instruction.h"
9 #include "src/compiler/instruction-selector.h" 9 #include "src/compiler/instruction-selector.h"
10 #include "src/compiler/linkage.h" 10 #include "src/compiler/linkage.h"
(...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after
139 Isolate* isolate() const { return zone()->isolate(); } 139 Isolate* isolate() const { return zone()->isolate(); }
140 Zone* zone() const { return selector()->instruction_zone(); } 140 Zone* zone() const { return selector()->instruction_zone(); }
141 141
142 private: 142 private:
143 static Constant ToConstant(const Node* node) { 143 static Constant ToConstant(const Node* node) {
144 switch (node->opcode()) { 144 switch (node->opcode()) {
145 case IrOpcode::kInt32Constant: 145 case IrOpcode::kInt32Constant:
146 return Constant(OpParameter<int32_t>(node)); 146 return Constant(OpParameter<int32_t>(node));
147 case IrOpcode::kInt64Constant: 147 case IrOpcode::kInt64Constant:
148 return Constant(OpParameter<int64_t>(node)); 148 return Constant(OpParameter<int64_t>(node));
149 case IrOpcode::kFloat32Constant:
150 return Constant(OpParameter<float>(node));
151 case IrOpcode::kFloat64Constant:
149 case IrOpcode::kNumberConstant: 152 case IrOpcode::kNumberConstant:
150 case IrOpcode::kFloat64Constant:
151 return Constant(OpParameter<double>(node)); 153 return Constant(OpParameter<double>(node));
152 case IrOpcode::kExternalConstant: 154 case IrOpcode::kExternalConstant:
153 return Constant(OpParameter<ExternalReference>(node)); 155 return Constant(OpParameter<ExternalReference>(node));
154 case IrOpcode::kHeapConstant: 156 case IrOpcode::kHeapConstant:
155 return Constant(OpParameter<Unique<HeapObject> >(node).handle()); 157 return Constant(OpParameter<Unique<HeapObject> >(node).handle());
156 default: 158 default:
157 break; 159 break;
158 } 160 }
159 UNREACHABLE(); 161 UNREACHABLE();
160 return Constant(static_cast<int32_t>(0)); 162 return Constant(static_cast<int32_t>(0));
(...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after
351 : (frame_state_descriptor->GetTotalSize() + 353 : (frame_state_descriptor->GetTotalSize() +
352 1); // Include deopt id. 354 1); // Include deopt id.
353 } 355 }
354 }; 356 };
355 357
356 } // namespace compiler 358 } // namespace compiler
357 } // namespace internal 359 } // namespace internal
358 } // namespace v8 360 } // namespace v8
359 361
360 #endif // V8_COMPILER_INSTRUCTION_SELECTOR_IMPL_H_ 362 #endif // V8_COMPILER_INSTRUCTION_SELECTOR_IMPL_H_
OLDNEW
« no previous file with comments | « src/compiler/instruction-selector.cc ('k') | src/compiler/instruction-selector-unittest.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698