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

Unified Diff: src/compiler/simd-lowering.h

Issue 1991143002: Convert SIMD wasm ops to runtime function calls (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 7 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 | « src/compiler/opcodes.h ('k') | src/compiler/simd-lowering.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/simd-lowering.h
diff --git a/src/compiler/simd-lowering.h b/src/compiler/simd-lowering.h
new file mode 100644
index 0000000000000000000000000000000000000000..56e06117a00546ae07289719b1fbaabeca5674a7
--- /dev/null
+++ b/src/compiler/simd-lowering.h
@@ -0,0 +1,45 @@
+// Copyright 2016 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef V8_COMPILER_SIMD_LOWERING_H_
+#define V8_COMPILER_SIMD_LOWERING_H_
+
+#include "src/compiler/graph-reducer.h"
+#include "src/compiler/wasm-compiler.h"
+#include "src/runtime/runtime.h"
+
+namespace v8 {
+namespace internal {
+namespace compiler {
+
+// Forward declarations.
+class JSGraph;
+class MachineOperatorBuilder;
+
+class SimdLowering final : public Reducer {
+ public:
+ explicit SimdLowering(JSGraph* jsgraph, WasmGraphBuilder* builder,
bbudge 2016/05/19 09:14:28 explicit not necessary
gdeepti 2016/05/19 09:34:09 Done.
+ Handle<Context> context)
+ : jsgraph_(jsgraph), builder_(builder), context_(context) {}
+ ~SimdLowering() final;
bbudge 2016/05/19 09:14:28 virtual
gdeepti 2016/05/19 09:34:09 Done.
+
+ Reduction Reduce(Node* node) final;
bbudge 2016/05/19 09:14:28 override
gdeepti 2016/05/19 09:34:09 Done.
+
+ private:
+ enum Conversion { kNone, kOpaque, kInt32, kFloat32, kFloat64 };
+ Reduction ChangeToRuntimeCall(Node* node, Runtime::FunctionId f,
+ Conversion* signature);
+
+ JSGraph* jsgraph() const { return jsgraph_; }
+
+ JSGraph* const jsgraph_;
+ WasmGraphBuilder* builder_;
+ Handle<Context> context_;
+};
+
+} // namespace compiler
+} // namespace internal
+} // namespace v8
+
+#endif // V8_COMPILER_SIMD_LOWERING_H_
« no previous file with comments | « src/compiler/opcodes.h ('k') | src/compiler/simd-lowering.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698