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

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

Issue 11413087: Fix corner case in x64 compare stubs. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: added copyright header to test case Created 8 years, 1 month 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | test/mjsunit/regress/regress-2416.js » ('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 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 5517 matching lines...) Expand 10 before | Expand all | Expand 10 after
5528 __ JumpIfNotBothSmi(rdx, rax, &miss, Label::kNear); 5528 __ JumpIfNotBothSmi(rdx, rax, &miss, Label::kNear);
5529 5529
5530 if (GetCondition() == equal) { 5530 if (GetCondition() == equal) {
5531 // For equality we do not care about the sign of the result. 5531 // For equality we do not care about the sign of the result.
5532 __ subq(rax, rdx); 5532 __ subq(rax, rdx);
5533 } else { 5533 } else {
5534 Label done; 5534 Label done;
5535 __ subq(rdx, rax); 5535 __ subq(rdx, rax);
5536 __ j(no_overflow, &done, Label::kNear); 5536 __ j(no_overflow, &done, Label::kNear);
5537 // Correct sign of result in case of overflow. 5537 // Correct sign of result in case of overflow.
5538 __ SmiNot(rdx, rdx); 5538 __ not_(rdx);
5539 __ bind(&done); 5539 __ bind(&done);
5540 __ movq(rax, rdx); 5540 __ movq(rax, rdx);
5541 } 5541 }
5542 __ ret(0); 5542 __ ret(0);
5543 5543
5544 __ bind(&miss); 5544 __ bind(&miss);
5545 GenerateMiss(masm); 5545 GenerateMiss(masm);
5546 } 5546 }
5547 5547
5548 5548
(...skipping 925 matching lines...) Expand 10 before | Expand all | Expand 10 after
6474 #endif 6474 #endif
6475 6475
6476 __ Ret(); 6476 __ Ret();
6477 } 6477 }
6478 6478
6479 #undef __ 6479 #undef __
6480 6480
6481 } } // namespace v8::internal 6481 } } // namespace v8::internal
6482 6482
6483 #endif // V8_TARGET_ARCH_X64 6483 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « no previous file | test/mjsunit/regress/regress-2416.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698