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/arm/simulator-arm.cc

Issue 10984057: Replace a set of Hydrogen instructions with rotate instructions on ARM (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 8 years, 2 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 | Annotate | Revision Log
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 1480 matching lines...) Expand 10 before | Expand all | Expand 10 after
1491 *carry_out = (result < 0); 1491 *carry_out = (result < 0);
1492 result = 0; 1492 result = 0;
1493 } else { 1493 } else {
1494 *carry_out = false; 1494 *carry_out = false;
1495 result = 0; 1495 result = 0;
1496 } 1496 }
1497 break; 1497 break;
1498 } 1498 }
1499 1499
1500 case ROR: { 1500 case ROR: {
1501 UNIMPLEMENTED(); 1501 if (shift_amount == 0) {
1502 *carry_out = c_flag_;
1503 } else {
1504 int32_t left = result >> shift_amount;
Erik Corry 2012/09/27 14:45:44 How does this work with a negative input?
1505 int32_t right = result << (32 - shift_amount);
1506 result = right | left;
1507 *carry_out = false;
ulan 2012/09/27 14:55:30 The carry_out should contain the last shifted bit
1508 }
1502 break; 1509 break;
1503 } 1510 }
1504 1511
ulan 2012/09/27 14:55:30 We can remove this empty line.
1512
1505 default: { 1513 default: {
1506 UNREACHABLE(); 1514 UNREACHABLE();
1507 break; 1515 break;
1508 } 1516 }
1509 } 1517 }
1510 } 1518 }
1511 return result; 1519 return result;
1512 } 1520 }
1513 1521
1514 1522
(...skipping 1869 matching lines...) Expand 10 before | Expand all | Expand 10 after
3384 uintptr_t address = *stack_slot; 3392 uintptr_t address = *stack_slot;
3385 set_register(sp, current_sp + sizeof(uintptr_t)); 3393 set_register(sp, current_sp + sizeof(uintptr_t));
3386 return address; 3394 return address;
3387 } 3395 }
3388 3396
3389 } } // namespace v8::internal 3397 } } // namespace v8::internal
3390 3398
3391 #endif // USE_SIMULATOR 3399 #endif // USE_SIMULATOR
3392 3400
3393 #endif // V8_TARGET_ARCH_ARM 3401 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « src/arm/lithium-codegen-arm.cc ('k') | src/hydrogen.h » ('j') | src/hydrogen.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698