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

Side by Side Diff: test/cctest/test-code-stub-assembler.cc

Issue 2426923002: [stubs] Removes the BranchIf.*() methods from CodeAssembler, changes their uses to Branch(). (Closed)
Patch Set: Created 4 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
« no previous file with comments | « src/interpreter/interpreter-assembler.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 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/base/utils/random-number-generator.h" 5 #include "src/base/utils/random-number-generator.h"
6 #include "src/code-factory.h" 6 #include "src/code-factory.h"
7 #include "src/code-stub-assembler.h" 7 #include "src/code-stub-assembler.h"
8 #include "src/compiler/node.h" 8 #include "src/compiler/node.h"
9 #include "src/ic/stub-cache.h" 9 #include "src/ic/stub-cache.h"
10 #include "src/isolate.h" 10 #include "src/isolate.h"
(...skipping 1239 matching lines...) Expand 10 before | Expand all | Expand 10 after
1250 Node* expected_handler = m.Parameter(2); 1250 Node* expected_handler = m.Parameter(2);
1251 1251
1252 Label passed(&m), failed(&m); 1252 Label passed(&m), failed(&m);
1253 1253
1254 Variable var_handler(&m, MachineRepresentation::kTagged); 1254 Variable var_handler(&m, MachineRepresentation::kTagged);
1255 Label if_handler(&m), if_miss(&m); 1255 Label if_handler(&m), if_miss(&m);
1256 1256
1257 m.TryProbeStubCache(&stub_cache, receiver, name, &if_handler, &var_handler, 1257 m.TryProbeStubCache(&stub_cache, receiver, name, &if_handler, &var_handler,
1258 &if_miss); 1258 &if_miss);
1259 m.Bind(&if_handler); 1259 m.Bind(&if_handler);
1260 m.BranchIfWordEqual(expected_handler, var_handler.value(), &passed, 1260 m.Branch(m.WordEqual(expected_handler, var_handler.value()), &passed,
1261 &failed); 1261 &failed);
1262 1262
1263 m.Bind(&if_miss); 1263 m.Bind(&if_miss);
1264 m.BranchIfWordEqual(expected_handler, m.IntPtrConstant(0), &passed, 1264 m.Branch(m.WordEqual(expected_handler, m.IntPtrConstant(0)), &passed,
1265 &failed); 1265 &failed);
1266 1266
1267 m.Bind(&passed); 1267 m.Bind(&passed);
1268 m.Return(m.BooleanConstant(true)); 1268 m.Return(m.BooleanConstant(true));
1269 1269
1270 m.Bind(&failed); 1270 m.Bind(&failed);
1271 m.Return(m.BooleanConstant(false)); 1271 m.Return(m.BooleanConstant(false));
1272 } 1272 }
1273 1273
1274 Handle<Code> code = m.GenerateCode(); 1274 Handle<Code> code = m.GenerateCode();
1275 FunctionTester ft(code, kNumParams); 1275 FunctionTester ft(code, kNumParams);
(...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after
1504 1504
1505 Handle<Object> constructor = 1505 Handle<Object> constructor =
1506 Object::GetPropertyOrElement(result, 1506 Object::GetPropertyOrElement(result,
1507 isolate->factory()->constructor_string()) 1507 isolate->factory()->constructor_string())
1508 .ToHandleChecked(); 1508 .ToHandleChecked();
1509 CHECK(constructor->SameValue(*isolate->type_error_function())); 1509 CHECK(constructor->SameValue(*isolate->type_error_function()));
1510 } 1510 }
1511 1511
1512 } // namespace internal 1512 } // namespace internal
1513 } // namespace v8 1513 } // namespace v8
OLDNEW
« no previous file with comments | « src/interpreter/interpreter-assembler.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698