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

Issue 8830: Get the ARM simulator to throw an exception on unaligned accesses. (Closed)

Created:
12 years, 1 month ago by Erik Corry
Modified:
9 years, 7 months ago
Reviewers:
iposva
CC:
v8-dev
Visibility:
Public.

Description

Get the ARM simulator to throw an exception on unaligned accesses. Committed: http://code.google.com/p/v8/source/detail?r=641

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+123 lines, -17 lines) Patch
M src/simulator-arm.h View 1 chunk +14 lines, -0 lines 0 comments Download
M src/simulator-arm.cc View 4 chunks +109 lines, -17 lines 3 comments Download

Messages

Total messages: 2 (0 generated)
Erik Corry
12 years, 1 month ago (2008-10-28 09:51:13 UTC) #1
iposva
12 years, 1 month ago (2008-10-28 15:34:17 UTC) #2
LGTM
-Ivan

http://codereview.chromium.org/8830/diff/1/3
File src/simulator-arm.cc (right):

http://codereview.chromium.org/8830/diff/1/3#newcode444
Line 444: PrintF("Unaligned read at %x\n", addr);
It would be helpful to print the PC and the address in the failure messages such
as:
"Unaligned read from %x at %x\n"

http://codereview.chromium.org/8830/diff/1/3#newcode483
Line 483: void Simulator::WriteH(int32_t addr, uint16_t value) {
The two WriteH and WriteB variants are really hard to distinguish, but I do not
have a better suggestion for you either.
Maybe a comment would help?

http://codereview.chromium.org/8830/diff/1/3#newcode506
Line 506: uint8_t* ptr = reinterpret_cast<uint8_t*>(addr);
Why no alignment check here? ;-)

Powered by Google App Engine
This is Rietveld 408576698