Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

arch/arm: change up_saveusercontext to assembly code #9019

Merged
merged 2 commits into from Apr 21, 2023

Conversation

zyfeier
Copy link
Contributor

@zyfeier zyfeier commented Apr 13, 2023

Summary

gdb will backtrace failure when use C code to save user context, because the stack push operation in C code can disrupt the stack information.

Impact

debug

Testing

tools/checkpatch.sh

minidump will backtrace failure when use C code to save user context,
because the stack push operation in C code can disrupt the stack information.

Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
minidump will backtrace failure when use C code to save user context,
because the stack push operation in C code can disrupt the stack information.

Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
Copy link
Contributor

@davids5 davids5 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@zyfeier
In looking at this, I am wondering, how is it that a memcopy after the SVC save is not just the SVC stack up save and a copy. Also why is the code not using stmia when it can?

arch/arm/src/armv6-m/arm_saveusercontext.S Show resolved Hide resolved
arch/arm/src/armv7-a/arm_saveusercontext.S Show resolved Hide resolved
arch/arm/src/armv7-m/arm_saveusercontext.S Show resolved Hide resolved
@davids5
Copy link
Contributor

davids5 commented Apr 20, 2023

@masayuki2009 Any feedback?

@xiaoxiang781216 xiaoxiang781216 merged commit 41f83a0 into apache:master Apr 21, 2023
26 checks passed
@zyfeier zyfeier deleted the assert_2 branch April 28, 2023 01:58
@jerpelea jerpelea added this to To-Add in Release Notes - 12.2.0 Jun 13, 2023
@jerpelea jerpelea moved this from To-Add to In Progress in Release Notes - 12.2.0 Jun 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Development

Successfully merging this pull request may close these issues.

None yet

3 participants