diff options
author | Torbjörn SVENSSON <torbjorn.svensson@foss.st.com> | 2022-10-06 16:01:10 +0200 |
---|---|---|
committer | Yvan Roux <yvan.roux@foss.st.com> | 2022-10-06 16:01:10 +0200 |
commit | 60c90d8c6d4b8345b41ab6a0b4d5169d5f78edb3 (patch) | |
tree | 27be0a0f682216227f1f469874293a1e6d6cc0da /configure.ac | |
parent | ca10a126c67f03e4e56dbbb6966c1682014912d8 (diff) | |
download | gdb-60c90d8c6d4b8345b41ab6a0b4d5169d5f78edb3.zip gdb-60c90d8c6d4b8345b41ab6a0b4d5169d5f78edb3.tar.gz gdb-60c90d8c6d4b8345b41ab6a0b4d5169d5f78edb3.tar.bz2 |
gdb/arm: Handle lazy FPU state preservation
Read LSPEN, ASPEN and LSPACT bits from FPCCR and use them together
with FPCAR to identify if lazy FPU state preservation is active for
the current frame. See "Lazy context save of FP state", in B1.5.7,
also ARM AN298, supported by Cortex-M4F architecture for details on
lazy FPU register stacking. The same conditions are valid for other
Cortex-M cores with FPU.
This patch has been verified on a STM32F4-Discovery board by:
a) writing a non-zero value (lets use 0x1122334455667788 as an
example) to all the D-registers in the main function
b) configured the SysTick to fire
c) in the SysTick_Handler, write some other value (lets use
0x0022446688aaccee as an example) to one of the D-registers (D0 as
an example) and then do "SVC #0"
d) in the SVC_Handler, write some other value (lets use
0x0099aabbccddeeff) to one of the D-registers (D0 as an example)
In GDB, suspend the execution in the SVC_Handler function and compare
the value of the D-registers for the SVC_handler frame and the
SysTick_Handler frame. With the patch, the value of the modified
D-register (D0) should be the new value (0x009..eff) on the
SVC_Handler frame, and the intermediate value (0x002..cee) for the
SysTick_Handler frame. Now compare the D-register value for the
SysTick_Handler frame and the main frame. The main frame should
have the initial value (0x112..788).
Signed-off-by: Torbjörn SVENSSON <torbjorn.svensson@foss.st.com>
Signed-off-by: Yvan ROUX <yvan.roux@foss.st.com>
Diffstat (limited to 'configure.ac')
0 files changed, 0 insertions, 0 deletions