OLD | NEW |
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 <limits> | 5 #include <limits> |
6 | 6 |
7 #include "src/compiler/access-builder.h" | 7 #include "src/compiler/access-builder.h" |
8 #include "src/compiler/change-lowering.h" | 8 #include "src/compiler/change-lowering.h" |
9 #include "src/compiler/control-builders.h" | 9 #include "src/compiler/control-builders.h" |
10 #include "src/compiler/graph-reducer.h" | 10 #include "src/compiler/graph-reducer.h" |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
75 CHECK(factory()->NewNumber(expected)->SameValue(result)); | 75 CHECK(factory()->NewNumber(expected)->SameValue(result)); |
76 } | 76 } |
77 | 77 |
78 template <typename T> | 78 template <typename T> |
79 T* CallWithPotentialGC() { | 79 T* CallWithPotentialGC() { |
80 // TODO(titzer): we wrap the code in a JSFunction here to reuse the | 80 // TODO(titzer): we wrap the code in a JSFunction here to reuse the |
81 // JSEntryStub; that could be done with a special prologue or other stub. | 81 // JSEntryStub; that could be done with a special prologue or other stub. |
82 Handle<JSFunction> fun = FunctionTester::ForMachineGraph(this->graph()); | 82 Handle<JSFunction> fun = FunctionTester::ForMachineGraph(this->graph()); |
83 Handle<Object>* args = NULL; | 83 Handle<Object>* args = NULL; |
84 MaybeHandle<Object> result = Execution::Call( | 84 MaybeHandle<Object> result = Execution::Call( |
85 this->isolate(), fun, factory()->undefined_value(), 0, args); | 85 this->isolate(), fun, factory()->undefined_value(), 0, args, false); |
86 return T::cast(*result.ToHandleChecked()); | 86 return T::cast(*result.ToHandleChecked()); |
87 } | 87 } |
88 | 88 |
89 Factory* factory() { return this->isolate()->factory(); } | 89 Factory* factory() { return this->isolate()->factory(); } |
90 Heap* heap() { return this->isolate()->heap(); } | 90 Heap* heap() { return this->isolate()->heap(); } |
91 }; | 91 }; |
92 | 92 |
93 | 93 |
94 // TODO(titzer): factor these tests out to test-run-simplifiedops.cc. | 94 // TODO(titzer): factor these tests out to test-run-simplifiedops.cc. |
95 // TODO(titzer): test tagged representation for input to NumberToInt32. | 95 // TODO(titzer): test tagged representation for input to NumberToInt32. |
(...skipping 1888 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1984 Type* phi_type = Type::Union(d.arg1, d.arg2, z); | 1984 Type* phi_type = Type::Union(d.arg1, d.arg2, z); |
1985 NodeProperties::SetType(phi, phi_type); | 1985 NodeProperties::SetType(phi, phi_type); |
1986 | 1986 |
1987 Node* use = t.Use(phi, d.use); | 1987 Node* use = t.Use(phi, d.use); |
1988 t.Return(use); | 1988 t.Return(use); |
1989 t.Lower(); | 1989 t.Lower(); |
1990 | 1990 |
1991 CHECK_EQ(d.expected, OpParameter<MachineType>(phi)); | 1991 CHECK_EQ(d.expected, OpParameter<MachineType>(phi)); |
1992 } | 1992 } |
1993 } | 1993 } |
OLD | NEW |