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

Unified Diff: runtime/vm/intrinsifier_arm.cc

Issue 467103005: Fixes to support ARMv5 lego mindstorm. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/intermediate_language_arm.cc ('k') | runtime/vm/raw_object.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/intrinsifier_arm.cc
===================================================================
--- runtime/vm/intrinsifier_arm.cc (revision 39210)
+++ runtime/vm/intrinsifier_arm.cc (working copy)
@@ -476,6 +476,9 @@
void Intrinsifier::Float64Array_getIndexed(Assembler* assembler) {
+ if (!TargetCPUFeatures::vfp_supported()) {
+ return;
+ }
Label fall_through;
__ ldr(R0, Address(SP, + 0 * kWordSize)); // Index.
__ ldr(R1, Address(SP, + 1 * kWordSize)); // Array.
@@ -511,6 +514,9 @@
void Intrinsifier::Float64Array_setIndexed(Assembler* assembler) {
+ if (!TargetCPUFeatures::vfp_supported()) {
+ return;
+ }
Label fall_through;
__ ldr(R0, Address(SP, + 1 * kWordSize)); // Index.
__ ldr(R1, Address(SP, + 2 * kWordSize)); // Array.
@@ -623,22 +629,23 @@
void Intrinsifier::Integer_mulFromInteger(Assembler* assembler) {
- Label fall_through;
-
- TestBothArgumentsSmis(assembler, &fall_through); // checks two smis
- __ SmiUntag(R0); // Untags R6. We only want result shifted by one.
-
if (TargetCPUFeatures::arm_version() == ARMv7) {
+ Label fall_through;
+ TestBothArgumentsSmis(assembler, &fall_through); // checks two smis
+ __ SmiUntag(R0); // Untags R6. We only want result shifted by one.
__ smull(R0, IP, R0, R1); // IP:R0 <- R0 * R1.
__ cmp(IP, Operand(R0, ASR, 31));
__ bx(LR, EQ);
- } else {
+ __ Bind(&fall_through); // Fall through on overflow.
+ } else if (TargetCPUFeatures::can_divide()) {
+ Label fall_through;
+ TestBothArgumentsSmis(assembler, &fall_through); // checks two smis
+ __ SmiUntag(R0); // Untags R6. We only want result shifted by one.
__ CheckMultSignedOverflow(R0, R1, IP, D0, D1, &fall_through);
__ mul(R0, R0, R1);
__ Ret();
+ __ Bind(&fall_through); // Fall through on overflow.
}
-
- __ Bind(&fall_through); // Fall through on overflow.
}
@@ -704,6 +711,9 @@
// }
// }
void Intrinsifier::Integer_moduloFromInteger(Assembler* assembler) {
+ if (!TargetCPUFeatures::can_divide()) {
+ return;
+ }
// Check to see if we have integer division
Label fall_through;
__ ldr(R1, Address(SP, + 0 * kWordSize));
@@ -735,6 +745,9 @@
void Intrinsifier::Integer_truncDivide(Assembler* assembler) {
+ if (!TargetCPUFeatures::can_divide()) {
+ return;
+ }
// Check to see if we have integer division
Label fall_through;
« no previous file with comments | « runtime/vm/intermediate_language_arm.cc ('k') | runtime/vm/raw_object.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698