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: [testsuite] Check for 3dnow, sse3, sse2 in i386 target assembler


Uros Bizjak <ubizjak@gmail.com> writes:

[Hundreds of lines of ChangeLog entry deleted ;-)]

> Ugh...

Indeed :-)

>> +# Return 1 if 3dnow instructions can be compiled.
>> +proc check_effective_target_3dnow { } {
>> +    return [check_no_compiler_messages 3dnow object {
>> +       void _m_femms (void)
>> +       {
>> +           __builtin_ia32_femms();
>> +       }
>> +    } "-O2 -m3dnow" ]
>> +}
>
> Please use a more representative insn for 3dNOW test here, perhaps
> __builtin_ia32_pfadd.

Will do.

>>  /* { dg-do compile } */
>>  /* This test checks for absolute memory operands.  */
>>  /* { dg-require-effective-target nonpic } */
>> +/* { dg-require-effective-target sse2 } */
>
> Can these dg-require-effective-target directives be merged into one {
> nonpic && sse2 } condition?

Unfortunately not: while doc/sourcebuild.texi doesn't state this
explicitly, testsuite/lib/target-supports-dg.exp has this:

    set args [lreplace $args 0 0]
    if { [llength $args] != 1 } {
        error "syntax error, need a single effective-target keyword"
    }

>>  /* PR rtl-optimization/16104 */
>>  /* { dg-do run { target i?86-*-* x86_64-*-* } } */
>>  /* { dg-options "-msse2" } */
>> +/* { dg-require-effective-target sse2 } */
>
> also in above example, { { target .... } && sse2 }.
>
> (and all similar constructs through the patch).

I could do this, but perhaps it would be good to stick to the
dg-require-effective-target sse2 form throughout for consistency?

> Otherwise, the patch is OK.

Thanks.
	Rainer

-- 
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University


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