This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH][rs6000] Support for PowerPC 750CL paired-single instructions


Hello,

gcc-patches-owner@gcc.gnu.org wrote on 27/08/2007 16:16:29:

>    This looks much better, thanks.
>
>    I am curious why you are enabling the support on any powerpc-linux
> configuration instead of creating a separate configuration.

Actually I am now convinced that a separate configuration is needed :-)

Trying to enable auto-vectorization for 750CL I realized I can not
automatically decide whether to add -mpaired or -maltivec for the tests
under the vect testsuite when 750CL is configure under powerpc*-*-*.
This is because in vect.exp; a test is done to figure whether is it
OK to compile for altivec.  the test is done by simply compiling with
-maltivec and check for no errors.

  return [check_no_compiler_messages powerpc_altivec_ok object {
            int dummy;
        } "-maltivec"]

The problem is that this same configuration (powerpc-*-*) is also
suitable for compiling with -mpaired; so we can not know automatically
whether to add -mpaired or -maltivec to those tests just by compiling
with those flags as they are both ok...

I hope I'm not missing something in the above explanation...

Other than that I think that enabling a separate configuration requires
also compatible binutils so I hope Ben is also OK with the above
explanation.

Another problem I encountered while enabling auto-vectorization; which I
should fix; is the name of the instructions - I should remove the paired
prefix; for example - instead of paired_addv2sf3 I'll change it to -
addv2sf3 in order to recognize them internally:

(define_insn "addv2sf3"
  [(set (match_operand:V2SF 0 "gpc_reg_operand" "=f")
        (plus:V2SF (match_operand:V2SF 1 "gpc_reg_operand" "%f")
                   (match_operand:V2SF 2 "gpc_reg_operand" "f")))]
  "TARGET_PAIRED_FLOAT"
  "ps_add %0,%1,%2"
  [(set_attr "type" "vecfloat")])

I'll re-send a patch with those changes.

Thanks again,
Revital


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]