Microblaze: Fixed missing save of r18 in fast_interrupt. Register 18 is used as a...
authorNagaraju Mekala <nmekala@xilinx.com>
Sat, 4 Apr 2020 09:10:08 +0000 (14:40 +0530)
committerJeff Law <law@redhat.com>
Sun, 5 Apr 2020 16:13:37 +0000 (10:13 -0600)
commita2ccd78027197abb787762d27b63c1a73f82c1f5
treea51d23da09eb1834732ef427d2fe343d97665f1e
parent971c3d0ea28fda1e764c6f47e0d901418adddb93
Microblaze: Fixed missing save of r18 in fast_interrupt. Register 18 is used as a clobber register, and must be stored when entering a fast_interrupt. Before this fix, register 18 was only saved if it was used directly in the interrupt function.

    However, if the fast_interrupt function called a function that used
    r18, the register would not be saved, and thus be mangled
    upon returning from the interrupt.

* config/microblaze/microblaze.c (microblaze_must_save_register): Check
for fast_interrupt.
gcc/ChangeLog
gcc/config/microblaze/microblaze.c