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

Side by Side Diff: src/full-codegen/ppc/full-codegen-ppc.cc

Issue 1736253003: Revert of PPC: [compiler] Drop the CompareNilIC. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 9 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 | « no previous file | src/ppc/interface-descriptors-ppc.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 #if V8_TARGET_ARCH_PPC 5 #if V8_TARGET_ARCH_PPC
6 6
7 #include "src/ast/scopes.h" 7 #include "src/ast/scopes.h"
8 #include "src/code-factory.h" 8 #include "src/code-factory.h"
9 #include "src/code-stubs.h" 9 #include "src/code-stubs.h"
10 #include "src/codegen.h" 10 #include "src/codegen.h"
(...skipping 4013 matching lines...) Expand 10 before | Expand all | Expand 10 after
4024 VisitForAccumulatorValue(sub_expr); 4024 VisitForAccumulatorValue(sub_expr);
4025 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false); 4025 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false);
4026 if (expr->op() == Token::EQ_STRICT) { 4026 if (expr->op() == Token::EQ_STRICT) {
4027 Heap::RootListIndex nil_value = nil == kNullValue 4027 Heap::RootListIndex nil_value = nil == kNullValue
4028 ? Heap::kNullValueRootIndex 4028 ? Heap::kNullValueRootIndex
4029 : Heap::kUndefinedValueRootIndex; 4029 : Heap::kUndefinedValueRootIndex;
4030 __ LoadRoot(r4, nil_value); 4030 __ LoadRoot(r4, nil_value);
4031 __ cmp(r3, r4); 4031 __ cmp(r3, r4);
4032 Split(eq, if_true, if_false, fall_through); 4032 Split(eq, if_true, if_false, fall_through);
4033 } else { 4033 } else {
4034 __ JumpIfSmi(r3, if_false); 4034 Handle<Code> ic = CompareNilICStub::GetUninitialized(isolate(), nil);
4035 __ LoadP(r3, FieldMemOperand(r3, HeapObject::kMapOffset)); 4035 CallIC(ic, expr->CompareOperationFeedbackId());
4036 __ lbz(r4, FieldMemOperand(r3, Map::kBitFieldOffset)); 4036 __ CompareRoot(r3, Heap::kTrueValueRootIndex);
4037 __ andi(r0, r4, Operand(1 << Map::kIsUndetectable)); 4037 Split(eq, if_true, if_false, fall_through);
4038 Split(ne, if_true, if_false, fall_through, cr0);
4039 } 4038 }
4040 context()->Plug(if_true, if_false); 4039 context()->Plug(if_true, if_false);
4041 } 4040 }
4042 4041
4043 4042
4044 void FullCodeGenerator::VisitThisFunction(ThisFunction* expr) { 4043 void FullCodeGenerator::VisitThisFunction(ThisFunction* expr) {
4045 __ LoadP(r3, MemOperand(fp, JavaScriptFrameConstants::kFunctionOffset)); 4044 __ LoadP(r3, MemOperand(fp, JavaScriptFrameConstants::kFunctionOffset));
4046 context()->Plug(r3); 4045 context()->Plug(r3);
4047 } 4046 }
4048 4047
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after
4223 return ON_STACK_REPLACEMENT; 4222 return ON_STACK_REPLACEMENT;
4224 } 4223 }
4225 4224
4226 DCHECK(interrupt_address == 4225 DCHECK(interrupt_address ==
4227 isolate->builtins()->OsrAfterStackCheck()->entry()); 4226 isolate->builtins()->OsrAfterStackCheck()->entry());
4228 return OSR_AFTER_STACK_CHECK; 4227 return OSR_AFTER_STACK_CHECK;
4229 } 4228 }
4230 } // namespace internal 4229 } // namespace internal
4231 } // namespace v8 4230 } // namespace v8
4232 #endif // V8_TARGET_ARCH_PPC 4231 #endif // V8_TARGET_ARCH_PPC
OLDNEW
« no previous file with comments | « no previous file | src/ppc/interface-descriptors-ppc.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698