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

Unified Diff: src/ic/ic.cc

Issue 1144183004: [strong] Refactor ObjectStrength into a replacement for strong boolean args (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: cl feedback and rebase Created 5 years, 6 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 | « src/ic/ic.h ('k') | src/ic/ic-state.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ic/ic.cc
diff --git a/src/ic/ic.cc b/src/ic/ic.cc
index f938336ba1aa2f95bf6fdbeb1748bbc3504837c6..e8be95ba34a5e9d17a89d2ab76b692b2ebc16f91 100644
--- a/src/ic/ic.cc
+++ b/src/ic/ic.cc
@@ -564,7 +564,7 @@ void CompareIC::Clear(Isolate* isolate, Address address, Code* target,
// Only clear CompareICs that can retain objects.
if (stub.state() != CompareICState::KNOWN_OBJECT) return;
SetTargetAtAddress(address,
- GetRawUninitialized(isolate, stub.op(), stub.strong()),
+ GetRawUninitialized(isolate, stub.op(), stub.strength()),
constant_pool);
PatchInlinedSmiCode(address, DISABLE_INLINED_SMI_CHECK);
}
@@ -2431,7 +2431,7 @@ MaybeHandle<Object> BinaryOpIC::Transition(
// Compute the actual result using the builtin for the binary operation.
Object* builtin = isolate()->js_builtins_object()->javascript_builtin(
- TokenToJSBuiltin(state.op(), state.language_mode()));
+ TokenToJSBuiltin(state.op(), state.strength()));
Handle<JSFunction> function = handle(JSFunction::cast(builtin), isolate());
Handle<Object> result;
ASSIGN_RETURN_ON_EXCEPTION(
@@ -2532,8 +2532,8 @@ RUNTIME_FUNCTION(BinaryOpIC_MissWithAllocationSite) {
Code* CompareIC::GetRawUninitialized(Isolate* isolate, Token::Value op,
- bool strong) {
- CompareICStub stub(isolate, op, strong, CompareICState::UNINITIALIZED,
+ Strength strength) {
+ CompareICStub stub(isolate, op, strength, CompareICState::UNINITIALIZED,
CompareICState::UNINITIALIZED,
CompareICState::UNINITIALIZED);
Code* code = NULL;
@@ -2543,8 +2543,8 @@ Code* CompareIC::GetRawUninitialized(Isolate* isolate, Token::Value op,
Handle<Code> CompareIC::GetUninitialized(Isolate* isolate, Token::Value op,
- bool strong) {
- CompareICStub stub(isolate, op, strong, CompareICState::UNINITIALIZED,
+ Strength strength) {
+ CompareICStub stub(isolate, op, strength, CompareICState::UNINITIALIZED,
CompareICState::UNINITIALIZED,
CompareICState::UNINITIALIZED);
return stub.GetCode();
@@ -2561,7 +2561,7 @@ Code* CompareIC::UpdateCaches(Handle<Object> x, Handle<Object> y) {
CompareICState::State state = CompareICState::TargetState(
old_stub.state(), old_stub.left(), old_stub.right(), op_,
HasInlinedSmiCode(address()), x, y);
- CompareICStub stub(isolate(), op_, old_stub.strong(), new_left, new_right,
+ CompareICStub stub(isolate(), op_, old_stub.strength(), new_left, new_right,
state);
if (state == CompareICState::KNOWN_OBJECT) {
stub.set_known_map(
@@ -2671,8 +2671,8 @@ RUNTIME_FUNCTION(Unreachable) {
Builtins::JavaScript BinaryOpIC::TokenToJSBuiltin(Token::Value op,
- LanguageMode language_mode) {
- if (is_strong(language_mode)) {
+ Strength strength) {
+ if (is_strong(strength)) {
switch (op) {
default: UNREACHABLE();
case Token::ADD: return Builtins::ADD_STRONG;
« no previous file with comments | « src/ic/ic.h ('k') | src/ic/ic-state.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698