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

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

Issue 903353002: X87: Initial switch to Chromium-style CHECK_* and DCHECK_* macros (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 10 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/x87/lithium-codegen-x87.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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/v8.h" 5 #include "src/v8.h"
6 6
7 #if V8_TARGET_ARCH_X87 7 #if V8_TARGET_ARCH_X87
8 8
9 #include "src/base/bits.h" 9 #include "src/base/bits.h"
10 #include "src/bootstrapper.h" 10 #include "src/bootstrapper.h"
(...skipping 1363 matching lines...) Expand 10 before | Expand all | Expand 10 after
1374 if (cc == equal && strict()) { 1374 if (cc == equal && strict()) {
1375 Label slow; // Fallthrough label. 1375 Label slow; // Fallthrough label.
1376 Label not_smis; 1376 Label not_smis;
1377 // If we're doing a strict equality comparison, we don't have to do 1377 // If we're doing a strict equality comparison, we don't have to do
1378 // type conversion, so we generate code to do fast comparison for objects 1378 // type conversion, so we generate code to do fast comparison for objects
1379 // and oddballs. Non-smi numbers and strings still go through the usual 1379 // and oddballs. Non-smi numbers and strings still go through the usual
1380 // slow-case code. 1380 // slow-case code.
1381 // If either is a Smi (we know that not both are), then they can only 1381 // If either is a Smi (we know that not both are), then they can only
1382 // be equal if the other is a HeapNumber. If so, use the slow case. 1382 // be equal if the other is a HeapNumber. If so, use the slow case.
1383 STATIC_ASSERT(kSmiTag == 0); 1383 STATIC_ASSERT(kSmiTag == 0);
1384 DCHECK_EQ(0, Smi::FromInt(0)); 1384 DCHECK_EQ(static_cast<Smi*>(0), Smi::FromInt(0));
1385 __ mov(ecx, Immediate(kSmiTagMask)); 1385 __ mov(ecx, Immediate(kSmiTagMask));
1386 __ and_(ecx, eax); 1386 __ and_(ecx, eax);
1387 __ test(ecx, edx); 1387 __ test(ecx, edx);
1388 __ j(not_zero, &not_smis, Label::kNear); 1388 __ j(not_zero, &not_smis, Label::kNear);
1389 // One operand is a smi. 1389 // One operand is a smi.
1390 1390
1391 // Check whether the non-smi is a heap number. 1391 // Check whether the non-smi is a heap number.
1392 STATIC_ASSERT(kSmiTagMask == 1); 1392 STATIC_ASSERT(kSmiTagMask == 1);
1393 // ecx still holds eax & kSmiTag, which is either zero or one. 1393 // ecx still holds eax & kSmiTag, which is either zero or one.
1394 __ sub(ecx, Immediate(0x01)); 1394 __ sub(ecx, Immediate(0x01));
(...skipping 3334 matching lines...) Expand 10 before | Expand all | Expand 10 after
4729 ApiParameterOperand(2), kStackSpace, nullptr, 4729 ApiParameterOperand(2), kStackSpace, nullptr,
4730 Operand(ebp, 7 * kPointerSize), NULL); 4730 Operand(ebp, 7 * kPointerSize), NULL);
4731 } 4731 }
4732 4732
4733 4733
4734 #undef __ 4734 #undef __
4735 4735
4736 } } // namespace v8::internal 4736 } } // namespace v8::internal
4737 4737
4738 #endif // V8_TARGET_ARCH_X87 4738 #endif // V8_TARGET_ARCH_X87
OLDNEW
« no previous file with comments | « no previous file | src/x87/lithium-codegen-x87.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698