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

Side by Side Diff: test/cctest/compiler/test-typer.cc

Issue 636283009: [turbofan] Use range types to type and lower arithmetic ops. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rename MaybeWeaken and rebase Created 6 years, 2 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 | Annotate | Revision Log
« no previous file with comments | « test/cctest/compiler/test-simplified-lowering.cc ('k') | test/cctest/test-types.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 <functional> 5 #include <functional>
6 6
7 #include "src/compiler/node-properties-inl.h" 7 #include "src/compiler/node-properties-inl.h"
8 #include "src/compiler/typer.h" 8 #include "src/compiler/typer.h"
9 #include "test/cctest/cctest.h" 9 #include "test/cctest/cctest.h"
10 #include "test/cctest/compiler/graph-builder-tester.h" 10 #include "test/cctest/compiler/graph-builder-tester.h"
(...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after
187 187
188 //------------------------------------------------------------------------------ 188 //------------------------------------------------------------------------------
189 // Soundness 189 // Soundness
190 // For simplicity, we currently only test soundness on expression operators 190 // For simplicity, we currently only test soundness on expression operators
191 // that have a direct equivalent in C++. Also, testing is currently limited 191 // that have a direct equivalent in C++. Also, testing is currently limited
192 // to ranges as input types. 192 // to ranges as input types.
193 193
194 194
195 TEST(TypeJSAdd) { 195 TEST(TypeJSAdd) {
196 TyperTester t; 196 TyperTester t;
197 t.TestBinaryArithOp(t.javascript_.Subtract(), std::plus<double>()); 197 t.TestBinaryArithOp(t.javascript_.Add(), std::plus<double>());
198 } 198 }
199 199
200 200
201 TEST(TypeJSSubtract) { 201 TEST(TypeJSSubtract) {
202 TyperTester t; 202 TyperTester t;
203 t.TestBinaryArithOp(t.javascript_.Subtract(), std::minus<double>()); 203 t.TestBinaryArithOp(t.javascript_.Subtract(), std::minus<double>());
204 } 204 }
205 205
206 206
207 TEST(TypeJSMultiply) { 207 TEST(TypeJSMultiply) {
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
325 V(Modulus) 325 V(Modulus)
326 326
327 327
328 TEST(Monotonicity) { 328 TEST(Monotonicity) {
329 TyperTester t; 329 TyperTester t;
330 #define TEST_OP(name) \ 330 #define TEST_OP(name) \
331 t.TestBinaryMonotonicity(t.javascript_.name()); 331 t.TestBinaryMonotonicity(t.javascript_.name());
332 JSBINOP_LIST(TEST_OP) 332 JSBINOP_LIST(TEST_OP)
333 #undef TEST_OP 333 #undef TEST_OP
334 } 334 }
OLDNEW
« no previous file with comments | « test/cctest/compiler/test-simplified-lowering.cc ('k') | test/cctest/test-types.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698