The origin of the register value was never
moved in the desired register state due to a typo ('rhs' vs. 'rhd').
While looking at the code, I noticed the action taken
for the register value is another copy'n'paste error
from the ADD opcode above -> it added to the register value
instead of MOVing the current value.
Patch submitted upstream.
cppcheck reported:
[lib/unwarminder/unwarm_thumb.c:473]: (warning) Redundant assignment of 'state.regData[rhd].o' to itself.
Change-Id: I78cdbf37a191007a3bddbaa350b906dbce2fe671
Also fix a wrong format specifier for an unsigned variable.
Detected by cppcheck, patch submitted upstream.
Change-Id: I9b84d91eeb242ed77b53ecc16252c5b35190bb9f
When writing a value to PC, execution continues at that location,
so subtracting 4 returns to the next instruction. Previously, two
instructions after the faulting instruction were being skipped, causing
safe_read functions to return true even if a data abort happened.
Change-Id: I3fd02d54646323ea2050d0504e38f6d22f09c749
Implement functions to read from a memory location and indicate
failure in case this is not possible. Since we do not have a MMU,
intercept the data abort handler and simply return when the abort
comes from the safe read routines.
Change-Id: I08f2e59898dcac893319a8150d4cf626f3adabbd
Reviewed-on: http://gerrit.rockbox.org/207
Reviewed-by: Marcin Bukat <marcin.bukat@gmail.com>
__get_sp is missing a return! I don't know how it ever worked.
Use "bx lr" since it works in all cases (armp and thumb).
Change-Id: I26011db333a8a5f96276be83e18da7507c501c38
Reviewed-on: http://gerrit.rockbox.org/206
Reviewed-by: Marcin Bukat <marcin.bukat@gmail.com>
libs in $ROOT/lib now add to $(CORE_LIBS) and $(EXTRA_LIBS) and are
automatically linked by the core and codecs/plugins respectively.
Change-Id: Iff482c792a8c8142718f6a16a450c6e2f1497c9a
cppcheck reported:
[lib/unwarminder/unwarm_thumb.c:399] -> [lib/unwarminder/unwarm_thumb.c:399]: (style) Same expression on both sides of '&&'.
Patch will also be sent to the upstream project.
Change-Id: I57033f290135f4dc09ac7e9b07c31461bc5b471a
Reviewed-on: http://gerrit.rockbox.org/157
Reviewed-by: Thomas Jarosch <tomj@simonv.com>
Simplified stack unwinder for ARM. This is port of
http://www.mcternan.me.uk/ArmStackUnwinding/
backtrace() is called from UIE() on native targets
and from panicf() on both native and ARM RaaA.
Change-Id: I8e4b3c02490dd60b30aa372fe842d193b8929ce0