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

Side by Side Diff: src/compiler/x64/instruction-selector-x64.cc

Issue 2215403002: [turbofan] Make Float32Neg and Float64Neg mandatory operators. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 4 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/wasm-compiler.cc ('k') | test/cctest/compiler/test-run-machops.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 <algorithm> 5 #include <algorithm>
6 6
7 #include "src/base/adapters.h" 7 #include "src/base/adapters.h"
8 #include "src/compiler/instruction-selector-impl.h" 8 #include "src/compiler/instruction-selector-impl.h"
9 #include "src/compiler/node-matchers.h" 9 #include "src/compiler/node-matchers.h"
10 #include "src/compiler/node-properties.h" 10 #include "src/compiler/node-properties.h"
(...skipping 2168 matching lines...) Expand 10 before | Expand all | Expand 10 after
2179 inputs[input_count++] = g.UseUniqueRegister(value); 2179 inputs[input_count++] = g.UseUniqueRegister(value);
2180 InstructionCode code = opcode | AddressingModeField::encode(addressing_mode); 2180 InstructionCode code = opcode | AddressingModeField::encode(addressing_mode);
2181 Emit(code, 0, static_cast<InstructionOperand*>(nullptr), input_count, inputs); 2181 Emit(code, 0, static_cast<InstructionOperand*>(nullptr), input_count, inputs);
2182 } 2182 }
2183 2183
2184 // static 2184 // static
2185 MachineOperatorBuilder::Flags 2185 MachineOperatorBuilder::Flags
2186 InstructionSelector::SupportedMachineOperatorFlags() { 2186 InstructionSelector::SupportedMachineOperatorFlags() {
2187 MachineOperatorBuilder::Flags flags = 2187 MachineOperatorBuilder::Flags flags =
2188 MachineOperatorBuilder::kWord32ShiftIsSafe | 2188 MachineOperatorBuilder::kWord32ShiftIsSafe |
2189 MachineOperatorBuilder::kWord32Ctz | MachineOperatorBuilder::kWord64Ctz | 2189 MachineOperatorBuilder::kWord32Ctz | MachineOperatorBuilder::kWord64Ctz;
2190 MachineOperatorBuilder::kFloat32Neg | MachineOperatorBuilder::kFloat64Neg;
2191 if (CpuFeatures::IsSupported(POPCNT)) { 2190 if (CpuFeatures::IsSupported(POPCNT)) {
2192 flags |= MachineOperatorBuilder::kWord32Popcnt | 2191 flags |= MachineOperatorBuilder::kWord32Popcnt |
2193 MachineOperatorBuilder::kWord64Popcnt; 2192 MachineOperatorBuilder::kWord64Popcnt;
2194 } 2193 }
2195 if (CpuFeatures::IsSupported(SSE4_1)) { 2194 if (CpuFeatures::IsSupported(SSE4_1)) {
2196 flags |= MachineOperatorBuilder::kFloat32RoundDown | 2195 flags |= MachineOperatorBuilder::kFloat32RoundDown |
2197 MachineOperatorBuilder::kFloat64RoundDown | 2196 MachineOperatorBuilder::kFloat64RoundDown |
2198 MachineOperatorBuilder::kFloat32RoundUp | 2197 MachineOperatorBuilder::kFloat32RoundUp |
2199 MachineOperatorBuilder::kFloat64RoundUp | 2198 MachineOperatorBuilder::kFloat64RoundUp |
2200 MachineOperatorBuilder::kFloat32RoundTruncate | 2199 MachineOperatorBuilder::kFloat32RoundTruncate |
2201 MachineOperatorBuilder::kFloat64RoundTruncate | 2200 MachineOperatorBuilder::kFloat64RoundTruncate |
2202 MachineOperatorBuilder::kFloat32RoundTiesEven | 2201 MachineOperatorBuilder::kFloat32RoundTiesEven |
2203 MachineOperatorBuilder::kFloat64RoundTiesEven; 2202 MachineOperatorBuilder::kFloat64RoundTiesEven;
2204 } 2203 }
2205 return flags; 2204 return flags;
2206 } 2205 }
2207 2206
2208 // static 2207 // static
2209 MachineOperatorBuilder::AlignmentRequirements 2208 MachineOperatorBuilder::AlignmentRequirements
2210 InstructionSelector::AlignmentRequirements() { 2209 InstructionSelector::AlignmentRequirements() {
2211 return MachineOperatorBuilder::AlignmentRequirements:: 2210 return MachineOperatorBuilder::AlignmentRequirements::
2212 FullUnalignedAccessSupport(); 2211 FullUnalignedAccessSupport();
2213 } 2212 }
2214 2213
2215 } // namespace compiler 2214 } // namespace compiler
2216 } // namespace internal 2215 } // namespace internal
2217 } // namespace v8 2216 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/wasm-compiler.cc ('k') | test/cctest/compiler/test-run-machops.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698