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

Side by Side Diff: test/unittests/compiler/js-builtin-reducer-unittest.cc

Issue 1314473007: [turbofan] Remove usage of Unique<T> from graph. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebased and fixed. Created 5 years, 3 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
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 "src/compiler/js-builtin-reducer.h" 5 #include "src/compiler/js-builtin-reducer.h"
6 #include "src/compiler/js-graph.h" 6 #include "src/compiler/js-graph.h"
7 #include "src/compiler/node-properties.h" 7 #include "src/compiler/node-properties.h"
8 #include "src/compiler/typer.h" 8 #include "src/compiler/typer.h"
9 #include "test/unittests/compiler/graph-unittest.h" 9 #include "test/unittests/compiler/graph-unittest.h"
10 #include "test/unittests/compiler/node-test-utils.h" 10 #include "test/unittests/compiler/node-test-utils.h"
(...skipping 23 matching lines...) Expand all
34 34
35 Node* MathFunction(const char* name) { 35 Node* MathFunction(const char* name) {
36 Handle<Object> m = 36 Handle<Object> m =
37 JSObject::GetProperty(isolate()->global_object(), 37 JSObject::GetProperty(isolate()->global_object(),
38 isolate()->factory()->NewStringFromAsciiChecked( 38 isolate()->factory()->NewStringFromAsciiChecked(
39 "Math")).ToHandleChecked(); 39 "Math")).ToHandleChecked();
40 Handle<JSFunction> f = Handle<JSFunction>::cast( 40 Handle<JSFunction> f = Handle<JSFunction>::cast(
41 JSObject::GetProperty( 41 JSObject::GetProperty(
42 m, isolate()->factory()->NewStringFromAsciiChecked(name)) 42 m, isolate()->factory()->NewStringFromAsciiChecked(name))
43 .ToHandleChecked()); 43 .ToHandleChecked());
44 return HeapConstant(Unique<JSFunction>::CreateUninitialized(f)); 44 return HeapConstant(f);
45 } 45 }
46 46
47 JSOperatorBuilder* javascript() { return &javascript_; } 47 JSOperatorBuilder* javascript() { return &javascript_; }
48 48
49 private: 49 private:
50 JSOperatorBuilder javascript_; 50 JSOperatorBuilder javascript_;
51 }; 51 };
52 52
53 53
54 namespace { 54 namespace {
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after
195 195
196 ASSERT_TRUE(r.Changed()); 196 ASSERT_TRUE(r.Changed());
197 EXPECT_THAT(r.replacement(), IsTruncateFloat64ToFloat32(p0)); 197 EXPECT_THAT(r.replacement(), IsTruncateFloat64ToFloat32(p0));
198 } 198 }
199 } 199 }
200 } 200 }
201 201
202 } // namespace compiler 202 } // namespace compiler
203 } // namespace internal 203 } // namespace internal
204 } // namespace v8 204 } // namespace v8
OLDNEW
« no previous file with comments | « test/unittests/compiler/interpreter-assembler-unittest.cc ('k') | test/unittests/compiler/js-context-relaxation-unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698