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

--- Comment #11 from Segher Boessenkool <segher at gcc dot gnu.org> ---
(In reply to Rich Felker from comment #9)
> And ok, to be more productive rather than just angry about the regression,
> if you really think the "ws" constraint should be removed, what is the
> proper preprocessor/configure-time check to determine the right constraint
> and asm form to use without special-casing specific compiler names and
> versions? Short of an answer to that, the only solution I can see to this on
> our side is just disabling the asm if a configure check determines that the
> current code doesn't compile, and that would be rather bleh.

Easy: always use "wa" whenever you want a VSX register.  Always
use "d" when you want an FP register, and use "v" if you want an
AltiVec register.  Use the "%x<N>" output modifier if you want
the VSX register numbering (so 0..63) in the assembler output
(instead of 0..31 for both halves of it: vs0..vs31 are f0..f31,
and vs32..vs63 are v0..v31).  Which of those register sets you
should use depends on what machine insns you use.

This is the same in any compiler version that supports VSX.  With
compiler versions that do not support VSX, you cannot use VSX, it
won't work.  There is the __VSX__ preprocessor predefine for
detecting this.

Reply via email to