[Bug target/103383] Microblaze bswaphi2 can cause issues with delay slots

kujoth at gmail dot com gcc-bugzilla@gcc.gnu.org
Thu Dec 2 03:00:58 GMT 2021


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103383

--- Comment #6 from Rich Kujoth <kujoth at gmail dot com> ---
I'm not really in a position to change toolchains, so I needed to make it work
with the version of GCC I have. Since the issue is specific to swap16, I made
my own swap16 function that explicitly calls the two microblaze instructions,
rather than using the GCC built-in. This resolves the issue and I don't see any
instances of swapb/swaph following a delayed branch in the compiled code.


More information about the Gcc-bugs mailing list