On Tue, 20 Jan 2015, Markos Chandras wrote: > >> We have tools out there based on 4.9. If we make gcc < 5.0 to fail with > >> R6, then nobody will be able to build it until 5.0 is released. > >> Perhaps it makes sense to add some checks in arch/mips/Makefile, see if > >> our gcc supports -mips32r6 or something and then decide what to do. > > > > Indeed, I think it is worthwhile supporting the use of tools which have R6 > > backported to them owing to long lead times for new versions of GCC to be > > released. > > > > I think you could actually just switch the check around and remove the > > check for micromips entirely, putting the GCC 4.9 check first: > > > > #if __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 9) > > #define GCC_OFF12_ASM() "ZC" > > #else > > #define GCC_OFF12_ASM() "R" > > #endif > > > > From what I can see this is safe. It was presumably written with a micromips > > check out of caution to not change older non-micromips code-gen but that > > doesn't seem particularly important. It is an improvement to older code if > > anything. > > For non-micromips kernel, this will start using "ZC" instead of "R", > whereas before, it only used "ZC" for micromips and "R" for everything > else. Is that safe? Maciej was the one committed this code, so if that's > still safe, then I will change it as requested. I'm fine with this proposal; a separate Makefile check for `-march=mips32r6' support would be good too. Maciej