https://gcc.gnu.org/bugzilla/show_bug.cgi?id=121432
Gopi Kumar Bulusu <gopi at sankhya dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |gopi at sankhya dot com
--- Comment #19 from Gopi Kumar Bulusu <gopi at sankhya dot com> ---
This does not look like a compiler defect.
This becomes clear when look at the way stack is setup and used in the
interrupt handler defined in entry.S
C_ENTRY(_interrupt):
Here stack space is allocated for pt_regs structure
addik r1, r1, -PT_SIZE;
SAVE_REGS
However SAVE_REGS does not actually use the top 8 bytes of the stack;
But then this instruction can be seen to access r1(4)
swi r11, r1, PT_R1;
After an rtbd to do_IRQ()
do_IRQ() can be seen to access (what it sees as callers frame) where it expects
space to be allocated for inbound arguments
+ c: f8a10024 swi r5, r1, 36
The value of r5 will be overwriting value of r11 stored in pt_regs
It would be a simple fix in the arch/microblaze/kernel/entry.S
This PR may be marked as INVALID