Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 353008 - flag-o-matic: add -mfloat-gprs to ALLOWED_FLAGS
Summary: flag-o-matic: add -mfloat-gprs to ALLOWED_FLAGS
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Eclasses (show other bugs)
Hardware: PPC Linux
: High enhancement
Assignee: Gentoo Toolchain Maintainers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-01-28 06:11 UTC by Alexander Dubov
Modified: 2011-02-01 05:41 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Dubov 2011-01-28 06:11:39 UTC
ALLOWED_FLAGS include, beside other things, switches which control the required floating point ABI. On PowerPC e200 and e500 platforms, there are two additional important flags, -mfloat-gprs (required for unified floating point values in GP registers support) and -m(no-)spe, which enables the use of SPE SIMD opcodes (Freescale's SSE like functionality).

Reproducible: Always

Steps to Reproduce:
The problem manifests itself when compiling any ebuild which relies on strip-flags().
Comment 1 Ryan Hill (RETIRED) gentoo-dev 2011-01-30 06:30:23 UTC
-mfloat-gprs sounds okay, but if SPE is like SSE then we would only add -mno-spe like we do for other SIMD instruction flags.
Comment 2 SpanKY gentoo-dev 2011-01-30 07:13:45 UTC
right.  if -mfloat-gprs actually changes the float ABI, then that is OK.
Comment 3 Alexander Dubov 2011-01-31 02:42:38 UTC
(In reply to comment #1)

That's probably good enough

(In reply to comment #2)

e200/e500 is an unified register architecture. It's only got a single register file (gpr0-31) and all operations are performed on the same bit values, be it integer instructions, FP ones or SPE. This is a rather different situation from what's normally happening with x86 architectural extensions. 

Of course, to be able to actually use this ABI one needs to rely on eglibc, but this is a different issue.
Comment 4 Alexander Dubov 2011-01-31 03:19:18 UTC
(In reply to comment #1)

Sorry, it's probably not good enough. :-)

I was just checking the e200 data sheet, and it says there that all the floating point calculations must be made with SPE instructions. "Normal" powerpc floating point opcodes will hit illegal instruction trap on this CPUs and will have to be emulated by the kernel.

So, for best results, -mspe must stay there as well.