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

Unified Diff: src/compiler/wasm-compiler.h

Issue 1901063002: [wasm] Copy the tagged-to-int32/float64 and int32/float64-to-tagged code to the wasm compiler. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/compiler/wasm-compiler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/wasm-compiler.h
diff --git a/src/compiler/wasm-compiler.h b/src/compiler/wasm-compiler.h
index 757cb024688d674e4edb00c776ed471f2ddb5072..ee03d5ea4413a45270accd184fca494a3d568af9 100644
--- a/src/compiler/wasm-compiler.h
+++ b/src/compiler/wasm-compiler.h
@@ -18,6 +18,7 @@ namespace compiler {
class Node;
class JSGraph;
class Graph;
+class Operator;
}
namespace wasm {
@@ -108,8 +109,6 @@ class WasmGraphBuilder {
void BuildWasmToJSWrapper(Handle<JSFunction> function,
wasm::FunctionSig* sig);
- Node* BuildJavaScriptToNumber(Node* node, Node* context, Node* effect,
- Node* control);
Node* ToJS(Node* node, Node* context, wasm::LocalType type);
Node* FromJS(Node* node, Node* context, wasm::LocalType type);
Node* Invert(Node* node);
@@ -158,6 +157,7 @@ class WasmGraphBuilder {
WasmTrapHelper* trap_;
wasm::FunctionSig* function_signature_;
+ SetOncePointer<const Operator> allocate_heap_number_operator_;
// Internal helper methods.
JSGraph* jsgraph() { return jsgraph_; }
@@ -244,6 +244,22 @@ class WasmGraphBuilder {
Node* BuildDiv64Call(Node* left, Node* right, ExternalReference ref,
MachineType result_type, int trap_zero);
+ Node* BuildJavaScriptToNumber(Node* node, Node* context, Node* effect,
+ Node* control);
+ Node* BuildChangeInt32ToTagged(Node* value);
+ Node* BuildChangeFloat64ToTagged(Node* value);
+ Node* BuildChangeTaggedToFloat64(Node* value);
+
+ Node* BuildChangeInt32ToSmi(Node* value);
+ Node* BuildChangeSmiToInt32(Node* value);
+ Node* BuildChangeSmiToFloat64(Node* value);
+ Node* BuildTestNotSmi(Node* value);
+ Node* BuildSmiShiftBitsConstant();
+
+ Node* BuildAllocateHeapNumberWithValue(Node* value, Node* control);
+ Node* BuildLoadHeapNumberValue(Node* value, Node* control);
+ Node* BuildHeapNumberValueIndexConstant();
+
Node** Realloc(Node** buffer, size_t old_count, size_t new_count) {
Node** buf = Buffer(new_count);
if (buf != buffer) memcpy(buf, buffer, old_count * sizeof(Node*));
« no previous file with comments | « no previous file | src/compiler/wasm-compiler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698