Replies: 2 comments 2 replies
-
|
From reading |
Beta Was this translation helpful? Give feedback.
0 replies
-
|
The macro simply makes an extern "C" function with an unmangled name. You can do that manually and skip using the macro. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello, same person as the stack layout question from the other day, hah.
I am working on code to perform a context switch, which I intend to do by using the Systick timer to set a PendSV interrupt. Looking at the assembly generated for the Rust PendSV handler vs the assembly generated for the C version I wrote, it looks like prologue / epilogue is being generated for this handler. I believe the Rust equivalent to C's
__attribute__((naked))is the#[unsafe(naked)]attribute, but I get the error "this attribute is not allowed on an exception handler controlled by cortex-m-rt". Is there a workaround / separate mechanism for registering the exception handler that will allow me to control the prologue and epilogue sequences for this handler?Beta Was this translation helpful? Give feedback.
All reactions