On 05/23/2017 05:40 AM, Maciej W. Rozycki wrote: > Hardcode the absence of the MIPS16e2 ASE for all the systems that do so > for the MIPS16 ASE already, providing for code to be optimized away. > > Signed-off-by: Maciej W. Rozycki <macro@xxxxxxxxxx> > --- Could you switch to using git format-patch such that we have a diffstat at the beginning of the patch which helps the reviewer figure out which files are being touched? It just occurred to me that a bunch of other platforms are lacking a cpu-feature-overrides.h file, but presumably would never be able to support mips16e2, like ar7, emma2rh, pnx833x and so on. > linux-mips16e2-ase-optim.diff > Index: linux-sfr-test/arch/mips/include/asm/mach-ath25/cpu-feature-overrides.h > =================================================================== > --- linux-sfr-test.orig/arch/mips/include/asm/mach-ath25/cpu-feature-overrides.h 2017-05-22 22:42:15.000000000 +0100 > +++ linux-sfr-test/arch/mips/include/asm/mach-ath25/cpu-feature-overrides.h 2017-05-22 22:57:28.987400000 +0100 > @@ -40,6 +40,7 @@ > #endif > > #define cpu_has_mips16 0 > +#define cpu_has_mips16e2 0 > #define cpu_has_mdmx 0 > #define cpu_has_mips3d 0 > #define cpu_has_smartmips 0 > Index: linux-sfr-test/arch/mips/include/asm/mach-au1x00/cpu-feature-overrides.h > =================================================================== > --- linux-sfr-test.orig/arch/mips/include/asm/mach-au1x00/cpu-feature-overrides.h 2017-05-22 22:42:15.000000000 +0100 > +++ linux-sfr-test/arch/mips/include/asm/mach-au1x00/cpu-feature-overrides.h 2017-05-22 22:57:28.991406000 +0100 > @@ -31,6 +31,7 @@ > #define cpu_has_ejtag 1 > #define cpu_has_llsc 1 > #define cpu_has_mips16 0 > +#define cpu_has_mips16e2 0 > #define cpu_has_mdmx 0 > #define cpu_has_mips3d 0 > #define cpu_has_smartmips 0 > Index: linux-sfr-test/arch/mips/include/asm/mach-bcm63xx/cpu-feature-overrides.h > =================================================================== > --- linux-sfr-test.orig/arch/mips/include/asm/mach-bcm63xx/cpu-feature-overrides.h 2017-05-22 22:42:15.000000000 +0100 > +++ linux-sfr-test/arch/mips/include/asm/mach-bcm63xx/cpu-feature-overrides.h 2017-05-22 22:57:28.995412000 +0100 > @@ -19,6 +19,7 @@ > #define cpu_has_ejtag 1 > #define cpu_has_llsc 1 > #define cpu_has_mips16 0 > +#define cpu_has_mips16e2 0 > #define cpu_has_mdmx 0 > #define cpu_has_mips3d 0 > #define cpu_has_smartmips 0 And why not mach-bmips/cpu-features-overrides.h? > Index: linux-sfr-test/arch/mips/include/asm/mach-cobalt/cpu-feature-overrides.h > =================================================================== > --- linux-sfr-test.orig/arch/mips/include/asm/mach-cobalt/cpu-feature-overrides.h 2017-05-22 22:42:15.000000000 +0100 > +++ linux-sfr-test/arch/mips/include/asm/mach-cobalt/cpu-feature-overrides.h 2017-05-22 22:57:29.001406000 +0100 > @@ -37,6 +37,7 @@ > #endif > > #define cpu_has_mips16 0 > +#define cpu_has_mips16e2 0 > #define cpu_has_mdmx 0 > #define cpu_has_mips3d 0 > #define cpu_has_smartmips 0 > Index: linux-sfr-test/arch/mips/include/asm/mach-dec/cpu-feature-overrides.h > =================================================================== > --- linux-sfr-test.orig/arch/mips/include/asm/mach-dec/cpu-feature-overrides.h 2017-05-22 22:42:15.000000000 +0100 > +++ linux-sfr-test/arch/mips/include/asm/mach-dec/cpu-feature-overrides.h 2017-05-22 22:57:29.006398000 +0100 > @@ -27,6 +27,7 @@ > #define cpu_has_mcheck 0 > #define cpu_has_ejtag 0 > #define cpu_has_mips16 0 > +#define cpu_has_mips16e2 0 > #define cpu_has_mdmx 0 > #define cpu_has_mips3d 0 > #define cpu_has_smartmips 0 > Index: linux-sfr-test/arch/mips/include/asm/mach-ip22/cpu-feature-overrides.h > =================================================================== > --- linux-sfr-test.orig/arch/mips/include/asm/mach-ip22/cpu-feature-overrides.h 2017-05-22 22:42:15.000000000 +0100 > +++ linux-sfr-test/arch/mips/include/asm/mach-ip22/cpu-feature-overrides.h 2017-05-22 22:57:29.010397000 +0100 > @@ -19,6 +19,7 @@ > #define cpu_has_32fpr 1 > #define cpu_has_counter 1 > #define cpu_has_mips16 0 > +#define cpu_has_mips16e2 0 > #define cpu_has_divec 0 > #define cpu_has_cache_cdex_p 1 > #define cpu_has_prefetch 0 > Index: linux-sfr-test/arch/mips/include/asm/mach-ip27/cpu-feature-overrides.h > =================================================================== > --- linux-sfr-test.orig/arch/mips/include/asm/mach-ip27/cpu-feature-overrides.h 2017-05-22 22:42:15.000000000 +0100 > +++ linux-sfr-test/arch/mips/include/asm/mach-ip27/cpu-feature-overrides.h 2017-05-22 22:57:29.020398000 +0100 > @@ -43,6 +43,7 @@ > #define cpu_has_ejtag 0 > #define cpu_has_llsc 1 > #define cpu_has_mips16 0 > +#define cpu_has_mips16e2 0 > #define cpu_has_mdmx 0 > #define cpu_has_mips3d 0 > #define cpu_has_smartmips 0 > Index: linux-sfr-test/arch/mips/include/asm/mach-ip28/cpu-feature-overrides.h > =================================================================== > --- linux-sfr-test.orig/arch/mips/include/asm/mach-ip28/cpu-feature-overrides.h 2017-05-22 22:42:15.000000000 +0100 > +++ linux-sfr-test/arch/mips/include/asm/mach-ip28/cpu-feature-overrides.h 2017-05-22 22:57:29.024398000 +0100 > @@ -16,6 +16,7 @@ > */ > #define cpu_has_watch 1 > #define cpu_has_mips16 0 > +#define cpu_has_mips16e2 0 > #define cpu_has_divec 0 > #define cpu_has_vce 0 > #define cpu_has_cache_cdex_p 0 > Index: linux-sfr-test/arch/mips/include/asm/mach-ip32/cpu-feature-overrides.h > =================================================================== > --- linux-sfr-test.orig/arch/mips/include/asm/mach-ip32/cpu-feature-overrides.h 2017-05-22 22:42:15.000000000 +0100 > +++ linux-sfr-test/arch/mips/include/asm/mach-ip32/cpu-feature-overrides.h 2017-05-22 22:57:29.028408000 +0100 > @@ -29,6 +29,7 @@ > #define cpu_has_32fpr 1 > #define cpu_has_counter 1 > #define cpu_has_mips16 0 > +#define cpu_has_mips16e2 0 > #define cpu_has_vce 0 > #define cpu_has_cache_cdex_s 0 > #define cpu_has_mcheck 0 > Index: linux-sfr-test/arch/mips/include/asm/mach-jz4740/cpu-feature-overrides.h > =================================================================== > --- linux-sfr-test.orig/arch/mips/include/asm/mach-jz4740/cpu-feature-overrides.h 2017-05-22 22:42:15.000000000 +0100 > +++ linux-sfr-test/arch/mips/include/asm/mach-jz4740/cpu-feature-overrides.h 2017-05-22 22:57:29.032407000 +0100 > @@ -23,6 +23,7 @@ > #define cpu_has_ejtag 1 > #define cpu_has_llsc 1 > #define cpu_has_mips16 0 > +#define cpu_has_mips16e2 0 > #define cpu_has_mdmx 0 > #define cpu_has_mips3d 0 > #define cpu_has_smartmips 0 > Index: linux-sfr-test/arch/mips/include/asm/mach-loongson64/cpu-feature-overrides.h > =================================================================== > --- linux-sfr-test.orig/arch/mips/include/asm/mach-loongson64/cpu-feature-overrides.h 2017-05-22 22:42:16.000000000 +0100 > +++ linux-sfr-test/arch/mips/include/asm/mach-loongson64/cpu-feature-overrides.h 2017-05-22 22:57:29.043398000 +0100 > @@ -32,6 +32,7 @@ > #define cpu_has_mcheck 0 > #define cpu_has_mdmx 0 > #define cpu_has_mips16 0 > +#define cpu_has_mips16e2 0 > #define cpu_has_mips3d 0 > #define cpu_has_mipsmt 0 > #define cpu_has_smartmips 0 > Index: linux-sfr-test/arch/mips/include/asm/mach-netlogic/cpu-feature-overrides.h > =================================================================== > --- linux-sfr-test.orig/arch/mips/include/asm/mach-netlogic/cpu-feature-overrides.h 2017-05-22 22:42:16.000000000 +0100 > +++ linux-sfr-test/arch/mips/include/asm/mach-netlogic/cpu-feature-overrides.h 2017-05-22 22:57:29.047397000 +0100 > @@ -13,6 +13,7 @@ > #define cpu_has_4k_cache 1 > #define cpu_has_watch 1 > #define cpu_has_mips16 0 > +#define cpu_has_mips16e2 0 > #define cpu_has_counter 1 > #define cpu_has_divec 1 > #define cpu_has_vce 0 > Index: linux-sfr-test/arch/mips/include/asm/mach-rc32434/cpu-feature-overrides.h > =================================================================== > --- linux-sfr-test.orig/arch/mips/include/asm/mach-rc32434/cpu-feature-overrides.h 2017-05-22 22:42:16.000000000 +0100 > +++ linux-sfr-test/arch/mips/include/asm/mach-rc32434/cpu-feature-overrides.h 2017-05-22 22:57:29.051411000 +0100 > @@ -48,6 +48,7 @@ > #define cpu_has_llsc 1 > > #define cpu_has_mips16 0 > +#define cpu_has_mips16e2 0 > #define cpu_has_mdmx 0 > #define cpu_has_mips3d 0 > #define cpu_has_smartmips 0 > Index: linux-sfr-test/arch/mips/include/asm/mach-rm/cpu-feature-overrides.h > =================================================================== > --- linux-sfr-test.orig/arch/mips/include/asm/mach-rm/cpu-feature-overrides.h 2017-05-22 22:42:16.000000000 +0100 > +++ linux-sfr-test/arch/mips/include/asm/mach-rm/cpu-feature-overrides.h 2017-05-22 22:57:29.066402000 +0100 > @@ -17,6 +17,7 @@ > #define cpu_has_counter 1 > #define cpu_has_watch 0 > #define cpu_has_mips16 0 > +#define cpu_has_mips16e2 0 > #define cpu_has_divec 0 > #define cpu_has_cache_cdex_p 1 > #define cpu_has_prefetch 0 > Index: linux-sfr-test/arch/mips/include/asm/mach-sibyte/cpu-feature-overrides.h > =================================================================== > --- linux-sfr-test.orig/arch/mips/include/asm/mach-sibyte/cpu-feature-overrides.h 2017-05-22 22:42:16.000000000 +0100 > +++ linux-sfr-test/arch/mips/include/asm/mach-sibyte/cpu-feature-overrides.h 2017-05-22 22:57:29.070404000 +0100 > @@ -13,6 +13,7 @@ > */ > #define cpu_has_watch 1 > #define cpu_has_mips16 0 > +#define cpu_has_mips16e2 0 > #define cpu_has_divec 1 > #define cpu_has_vce 0 > #define cpu_has_cache_cdex_p 0 > Index: linux-sfr-test/arch/mips/include/asm/mach-tx49xx/cpu-feature-overrides.h > =================================================================== > --- linux-sfr-test.orig/arch/mips/include/asm/mach-tx49xx/cpu-feature-overrides.h 2017-05-22 22:42:16.000000000 +0100 > +++ linux-sfr-test/arch/mips/include/asm/mach-tx49xx/cpu-feature-overrides.h 2017-05-22 22:57:29.074404000 +0100 > @@ -6,6 +6,7 @@ > #define cpu_has_inclusive_pcaches 0 > > #define cpu_has_mips16 0 > +#define cpu_has_mips16e2 0 > #define cpu_has_mdmx 0 > #define cpu_has_mips3d 0 > #define cpu_has_smartmips 0 > -- Florian