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

Unified Diff: runtime/vm/assembler_arm.cc

Issue 14192032: Implement missing features to run Hello world! in checked mode on simulated ARM. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 8 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/assembler_arm.h ('k') | runtime/vm/flow_graph_compiler_arm.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/assembler_arm.cc
===================================================================
--- runtime/vm/assembler_arm.cc (revision 21778)
+++ runtime/vm/assembler_arm.cc (working copy)
@@ -1224,27 +1224,29 @@
// Uses a code sequence that can easily be decoded.
-void Assembler::LoadWordFromPoolOffset(Register rd, int32_t offset) {
+void Assembler::LoadWordFromPoolOffset(Register rd,
+ int32_t offset,
+ Condition cond) {
ASSERT(rd != PP);
int32_t offset_mask = 0;
if (Address::CanHoldLoadOffset(kLoadWord, offset, &offset_mask)) {
- ldr(rd, Address(PP, offset));
+ ldr(rd, Address(PP, offset), cond);
} else {
int32_t offset_hi = offset & ~offset_mask; // signed
uint32_t offset_lo = offset & offset_mask; // unsigned
// Inline a simplified version of AddImmediate(rd, PP, offset_hi).
ShifterOperand shifter_op;
if (ShifterOperand::CanHold(offset_hi, &shifter_op)) {
- add(rd, PP, shifter_op);
+ add(rd, PP, shifter_op, cond);
} else {
movw(rd, Utils::Low16Bits(offset_hi));
const uint16_t value_high = Utils::High16Bits(offset_hi);
if (value_high != 0) {
- movt(rd, value_high);
+ movt(rd, value_high, cond);
}
- add(rd, PP, ShifterOperand(LR));
+ add(rd, PP, ShifterOperand(LR), cond);
}
- ldr(rd, Address(rd, offset_lo));
+ ldr(rd, Address(rd, offset_lo), cond);
}
}
@@ -1257,24 +1259,24 @@
}
-void Assembler::LoadObject(Register rd, const Object& object) {
+void Assembler::LoadObject(Register rd, const Object& object, Condition cond) {
// Smis and VM heap objects are never relocated; do not use object pool.
if (object.IsSmi()) {
- LoadImmediate(rd, reinterpret_cast<int32_t>(object.raw()));
+ LoadImmediate(rd, reinterpret_cast<int32_t>(object.raw()), cond);
} else if (object.InVMHeap()) {
// Make sure that class CallPattern is able to decode this load immediate.
const int32_t object_raw = reinterpret_cast<int32_t>(object.raw());
- movw(rd, Utils::Low16Bits(object_raw));
+ movw(rd, Utils::Low16Bits(object_raw), cond);
const uint16_t value_high = Utils::High16Bits(object_raw);
if (value_high != 0) {
- movt(rd, value_high);
+ movt(rd, value_high, cond);
}
} else {
// Make sure that class CallPattern is able to decode this load from the
// object pool.
const int32_t offset =
Array::data_offset() + 4*AddObject(object) - kHeapObjectTag;
- LoadWordFromPoolOffset(rd, offset);
+ LoadWordFromPoolOffset(rd, offset, cond);
}
}
« no previous file with comments | « runtime/vm/assembler_arm.h ('k') | runtime/vm/flow_graph_compiler_arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698