public inbox for gentoo-dev@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-dev] [PATCH] flag-o-matic.eclass: add some missing MIPS CPU errata options to ALLOWED_FLAGS
@ 2020-03-28 19:17 Joshua Kinard
  2020-03-28 19:31 ` Matt Turner
  2020-03-28 19:43 ` Sergei Trofimovich
  0 siblings, 2 replies; 3+ messages in thread
From: Joshua Kinard @ 2020-03-28 19:17 UTC (permalink / raw
  To: gentoo-dev

Noticed during a glibc build for MIPS-III ISA that the -mfix-r4000
and -mfix-r4400 gcc flags got stripped off.  These are needed to work
around known CPU errata in R4000 and R4400 CPUs.  In addition, also
add the -mfix-rm7000 option (and it's -mno form) to fix errata in the
PMC RM7000 CPU, and the -mr10k-cache-barrier to control the generation
of cache barriers to work around the side-effects of R10000's
speculative execution capabilities.

Signed-off-by: Joshua Kinard <kumba@gentoo.org>
---
 eclass/flag-o-matic.eclass | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/eclass/flag-o-matic.eclass b/eclass/flag-o-matic.eclass
index e76eef293e..0c67ec9f7a 100644
--- a/eclass/flag-o-matic.eclass
+++ b/eclass/flag-o-matic.eclass
@@ -56,7 +56,9 @@ setup-allowed-flags() {
 		-mno-faster-structs -mfaster-structs -m32 -m64 -mx32 -mabi
 		-mlittle-endian -mbig-endian -EL -EB -fPIC -mlive-g0 -mcmodel
 		-mstack-bias -mno-stack-bias -msecure-plt '-m*-toc' -mfloat-abi
-		-mfix-r10000 -mno-fix-r10000 -mthumb -marm
+		-mfix-r4000 -mno-fix-r4000 -mfix-r4400 -mno-fix-r4400
+		-mfix-rm7000 -mno-fix-rm7000 -mfix-r10000 -mno-fix-r10000
+		-mr10k-cache-barrier -mthumb -marm
 
 		# gcc 4.5
 		-mno-fma4 -mno-movbe -mno-xop -mno-lwp



^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [gentoo-dev] [PATCH] flag-o-matic.eclass: add some missing MIPS CPU errata options to ALLOWED_FLAGS
  2020-03-28 19:17 [gentoo-dev] [PATCH] flag-o-matic.eclass: add some missing MIPS CPU errata options to ALLOWED_FLAGS Joshua Kinard
@ 2020-03-28 19:31 ` Matt Turner
  2020-03-28 19:43 ` Sergei Trofimovich
  1 sibling, 0 replies; 3+ messages in thread
From: Matt Turner @ 2020-03-28 19:31 UTC (permalink / raw
  To: gentoo development

On Sat, Mar 28, 2020 at 12:17 PM Joshua Kinard <kumba@gentoo.org> wrote:
>
> Noticed during a glibc build for MIPS-III ISA that the -mfix-r4000
> and -mfix-r4400 gcc flags got stripped off.  These are needed to work
> around known CPU errata in R4000 and R4400 CPUs.  In addition, also
> add the -mfix-rm7000 option (and it's -mno form) to fix errata in the
> PMC RM7000 CPU, and the -mr10k-cache-barrier to control the generation
> of cache barriers to work around the side-effects of R10000's
> speculative execution capabilities.

Hah, I guess that tells us how many users we have :)

Reviewed-by: Matt Turner <mattst88@gentoo.org>


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [gentoo-dev] [PATCH] flag-o-matic.eclass: add some missing MIPS CPU errata options to ALLOWED_FLAGS
  2020-03-28 19:17 [gentoo-dev] [PATCH] flag-o-matic.eclass: add some missing MIPS CPU errata options to ALLOWED_FLAGS Joshua Kinard
  2020-03-28 19:31 ` Matt Turner
@ 2020-03-28 19:43 ` Sergei Trofimovich
  1 sibling, 0 replies; 3+ messages in thread
From: Sergei Trofimovich @ 2020-03-28 19:43 UTC (permalink / raw
  To: Joshua Kinard; +Cc: gentoo-dev

On Sat, 28 Mar 2020 15:17:12 -0400
Joshua Kinard <kumba@gentoo.org> wrote:

> Noticed during a glibc build for MIPS-III ISA that the -mfix-r4000
> and -mfix-r4400 gcc flags got stripped off.  These are needed to work
> around known CPU errata in R4000 and R4400 CPUs.  In addition, also
> add the -mfix-rm7000 option (and it's -mno form) to fix errata in the
> PMC RM7000 CPU, and the -mr10k-cache-barrier to control the generation
> of cache barriers to work around the side-effects of R10000's
> speculative execution capabilities.
> 
> Signed-off-by: Joshua Kinard <kumba@gentoo.org>
> ---
>  eclass/flag-o-matic.eclass | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/eclass/flag-o-matic.eclass b/eclass/flag-o-matic.eclass
> index e76eef293e..0c67ec9f7a 100644
> --- a/eclass/flag-o-matic.eclass
> +++ b/eclass/flag-o-matic.eclass
> @@ -56,7 +56,9 @@ setup-allowed-flags() {
>  		-mno-faster-structs -mfaster-structs -m32 -m64 -mx32 -mabi
>  		-mlittle-endian -mbig-endian -EL -EB -fPIC -mlive-g0 -mcmodel
>  		-mstack-bias -mno-stack-bias -msecure-plt '-m*-toc' -mfloat-abi
> -		-mfix-r10000 -mno-fix-r10000 -mthumb -marm
> +		-mfix-r4000 -mno-fix-r4000 -mfix-r4400 -mno-fix-r4400
> +		-mfix-rm7000 -mno-fix-rm7000 -mfix-r10000 -mno-fix-r10000
> +		-mr10k-cache-barrier -mthumb -marm
>  
>  		# gcc 4.5
>  		-mno-fma4 -mno-movbe -mno-xop -mno-lwp

Looks good!

-- 

  Sergei


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-03-28 19:43 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-03-28 19:17 [gentoo-dev] [PATCH] flag-o-matic.eclass: add some missing MIPS CPU errata options to ALLOWED_FLAGS Joshua Kinard
2020-03-28 19:31 ` Matt Turner
2020-03-28 19:43 ` Sergei Trofimovich

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox