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

Unified Diff: src/arm/simulator-arm.cc

Issue 19243002: Fix cctest/test-cpu-profiler/FunctionApplySample fakiness on ARM simulator (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 5 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 | « src/arm/simulator-arm.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/arm/simulator-arm.cc
diff --git a/src/arm/simulator-arm.cc b/src/arm/simulator-arm.cc
index 00af77796101d2a2eeb07bba68f2a9b43fbed79f..c47f2ab80c9a4d9cf4e32cb1caaf47609140fad7 100644
--- a/src/arm/simulator-arm.cc
+++ b/src/arm/simulator-arm.cc
@@ -1534,11 +1534,11 @@ static int count_bits(int bit_vector) {
}
-void Simulator::ProcessPUW(Instruction* instr,
- int num_regs,
- int reg_size,
- intptr_t* start_address,
- intptr_t* end_address) {
+int32_t Simulator::ProcessPU(Instruction* instr,
+ int num_regs,
+ int reg_size,
+ intptr_t* start_address,
+ intptr_t* end_address) {
int rn = instr->RnValue();
int32_t rn_val = get_register(rn);
switch (instr->PUField()) {
@@ -1569,9 +1569,7 @@ void Simulator::ProcessPUW(Instruction* instr,
break;
}
}
- if (instr->HasW()) {
- set_register(rn, rn_val);
- }
+ return rn_val;
}
@@ -1582,7 +1580,8 @@ void Simulator::HandleRList(Instruction* instr, bool load) {
intptr_t start_address = 0;
intptr_t end_address = 0;
- ProcessPUW(instr, num_regs, kPointerSize, &start_address, &end_address);
+ int32_t rn_val =
+ ProcessPU(instr, num_regs, kPointerSize, &start_address, &end_address);
intptr_t* address = reinterpret_cast<intptr_t*>(start_address);
// Catch null pointers a little earlier.
@@ -1601,6 +1600,9 @@ void Simulator::HandleRList(Instruction* instr, bool load) {
rlist >>= 1;
}
ASSERT(end_address == ((intptr_t)address) - 4);
+ if (instr->HasW()) {
+ set_register(instr->RnValue(), rn_val);
+ }
}
@@ -1623,7 +1625,8 @@ void Simulator::HandleVList(Instruction* instr) {
intptr_t start_address = 0;
intptr_t end_address = 0;
- ProcessPUW(instr, num_regs, operand_size, &start_address, &end_address);
+ int32_t rn_val =
+ ProcessPU(instr, num_regs, operand_size, &start_address, &end_address);
intptr_t* address = reinterpret_cast<intptr_t*>(start_address);
for (int reg = vd; reg < vd + num_regs; reg++) {
@@ -1656,6 +1659,9 @@ void Simulator::HandleVList(Instruction* instr) {
}
}
ASSERT(reinterpret_cast<intptr_t>(address) - operand_size == end_address);
+ if (instr->HasW()) {
+ set_register(instr->RnValue(), rn_val);
+ }
}
« no previous file with comments | « src/arm/simulator-arm.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698