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

Side by Side Diff: src/ppc/code-stubs-ppc.cc

Issue 1318823006: PPC: Fix "Correctify instanceof and make it optimizable." (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: 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
« no previous file with comments | « no previous file | 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 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/base/bits.h" 7 #include "src/base/bits.h"
8 #include "src/bootstrapper.h" 8 #include "src/bootstrapper.h"
9 #include "src/code-stubs.h" 9 #include "src/code-stubs.h"
10 #include "src/codegen.h" 10 #include "src/codegen.h"
(...skipping 1393 matching lines...) Expand 10 before | Expand all | Expand 10 after
1404 __ Ret(); 1404 __ Ret();
1405 1405
1406 // Fast-case: The {function} must be a valid JSFunction. 1406 // Fast-case: The {function} must be a valid JSFunction.
1407 __ bind(&fast_case); 1407 __ bind(&fast_case);
1408 __ JumpIfSmi(function, &slow_case); 1408 __ JumpIfSmi(function, &slow_case);
1409 __ CompareObjectType(function, function_map, scratch, JS_FUNCTION_TYPE); 1409 __ CompareObjectType(function, function_map, scratch, JS_FUNCTION_TYPE);
1410 __ bne(&slow_case); 1410 __ bne(&slow_case);
1411 1411
1412 // Ensure that {function} has an instance prototype. 1412 // Ensure that {function} has an instance prototype.
1413 __ lbz(scratch, FieldMemOperand(function_map, Map::kBitFieldOffset)); 1413 __ lbz(scratch, FieldMemOperand(function_map, Map::kBitFieldOffset));
1414 __ TestBit(scratch, Map::HasNonInstancePrototype, r0); 1414 __ TestBit(scratch, Map::kHasNonInstancePrototype, r0);
1415 __ bne(&slow_case, cr0); 1415 __ bne(&slow_case, cr0);
1416 1416
1417 // Ensure that {function} is not bound. 1417 // Ensure that {function} is not bound.
1418 Register const shared_info = scratch; 1418 Register const shared_info = scratch;
1419 __ LoadP(shared_info, 1419 __ LoadP(shared_info,
1420 FieldMemOperand(function, JSFunction::kSharedFunctionInfoOffset)); 1420 FieldMemOperand(function, JSFunction::kSharedFunctionInfoOffset));
1421 __ lwz(scratch, FieldMemOperand(shared_info, 1421 __ lwz(scratch, FieldMemOperand(shared_info,
1422 SharedFunctionInfo::kCompilerHintsOffset)); 1422 SharedFunctionInfo::kCompilerHintsOffset));
1423 __ TestBit(scratch, 1423 __ TestBit(scratch,
1424 #if V8_TARGET_ARCH_PPC64 1424 #if V8_TARGET_ARCH_PPC64
(...skipping 4302 matching lines...) Expand 10 before | Expand all | Expand 10 after
5727 kStackUnwindSpace, NULL, 5727 kStackUnwindSpace, NULL,
5728 MemOperand(fp, 6 * kPointerSize), NULL); 5728 MemOperand(fp, 6 * kPointerSize), NULL);
5729 } 5729 }
5730 5730
5731 5731
5732 #undef __ 5732 #undef __
5733 } // namespace internal 5733 } // namespace internal
5734 } // namespace v8 5734 } // namespace v8
5735 5735
5736 #endif // V8_TARGET_ARCH_PPC 5736 #endif // V8_TARGET_ARCH_PPC
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698