On Nov 20, 2018, at 5:00 PM, Jeff Law <l...@redhat.com> wrote:
> 
> On 11/16/18 9:29 AM, Andrew Stubbs wrote:
>> This collection of miscellaneous patches configures the testsuite to run on 
>> AMD
>> GCN in a standalone (i.e. not offloading) configuration.  It assumes you have
>> your Dejagnu set up to run binaries via the gcn-run tool.
>> 
>> 2018-11-16  Andrew Stubbs  <a...@codesourcery.com>
>>          Kwok Cheung Yeung  <k...@codesourcery.com>
>>          Julian Brown  <jul...@codesourcery.com>
>>          Tom de Vries  <t...@codesourcery.com>
>> 
>>      gcc/testsuite/
>>      * gcc.dg/20020312-2.c: Add amdgcn support.
>>      * gcc.dg/Wno-frame-address.c: Disable on amdgcn.
>>      * gcc.dg/builtin-apply2.c: Likewise.
>>      * gcc.dg/torture/stackalign/builtin-apply-2.c: Likewise.
>>      * gcc.dg/gimplefe-28.c: Force -ffast-math.
>>      * gcc.dg/intermod-1.c: Add -mlocal-symbol-id on amdgcn.
>>      * gcc.dg/memcmp-1.c: Increase timeout factor.
>>      * gcc.dg/pr59605-2.c: Addd -DMAX_COPY=1025 on amdgcn.
>>      * gcc.dg/sibcall-10.c: xfail on amdgcn.
>>      * gcc.dg/sibcall-9.c: Likewise.
>>      * gcc.dg/tree-ssa/gen-vect-11c.c: Likewise.
>>      * gcc.dg/tree-ssa/pr84512.c: Likewise.
>>      * gcc.dg/tree-ssa/loop-1.c: Adjust expectations for amdgcn.
>>      * gfortran.dg/bind_c_array_params_2.f90: Likewise.
>>      * gcc.dg/vect/tree-vect.h: Avoid signal on amdgcn.
>>      * lib/target-supports.exp (check_effective_target_trampolines):
>>      Configure amdgcn.
>>      (check_profiling_available): Likewise.
>>      (check_effective_target_global_constructor): Likewise.
>>      (check_effective_target_return_address): Likewise.
>>      (check_effective_target_fopenacc): Likewise.
>>      (check_effective_target_fopenmp): Likewise.
>>      (check_effective_target_vect_int): Likewise.
>>      (check_effective_target_vect_intfloat_cvt): Likewise.
>>      (check_effective_target_vect_uintfloat_cvt): Likewise.
>>      (check_effective_target_vect_floatint_cvt): Likewise.
>>      (check_effective_target_vect_floatuint_cvt): Likewise.
>>      (check_effective_target_vect_simd_clones): Likewise.
>>      (check_effective_target_vect_shift): Likewise.
>>      (check_effective_target_whole_vector_shift): Likewise.
>>      (check_effective_target_vect_bswap): Likewise.
>>      (check_effective_target_vect_shift_char): Likewise.
>>      (check_effective_target_vect_long): Likewise.
>>      (check_effective_target_vect_float): Likewise.
>>      (check_effective_target_vect_double): Likewise.
>>      (check_effective_target_vect_perm): Likewise.
>>      (check_effective_target_vect_perm_byte): Likewise.
>>      (check_effective_target_vect_perm_short): Likewise.
>>      (check_effective_target_vect_widen_mult_qi_to_hi): Likewise.
>>      (check_effective_target_vect_widen_mult_hi_to_si): Likewise.
>>      (check_effective_target_vect_widen_mult_qi_to_hi_pattern): Likewise.
>>      (check_effective_target_vect_widen_mult_hi_to_si_pattern): Likewise.
>>      (check_effective_target_vect_natural_alignment): Likewise.
>>      (check_effective_target_vect_fully_masked): Likewise.
>>      (check_effective_target_vect_element_align): Likewise.
>>      (check_effective_target_vect_masked_store): Likewise.
>>      (check_effective_target_vect_scatter_store): Likewise.
>>      (check_effective_target_vect_condition): Likewise.
>>      (check_effective_target_vect_cond_mixed): Likewise.
>>      (check_effective_target_vect_char_mult): Likewise.
>>      (check_effective_target_vect_short_mult): Likewise.
>>      (check_effective_target_vect_int_mult): Likewise.
>>      (check_effective_target_sqrt_insn): Likewise.
>>      (check_effective_target_vect_call_sqrtf): Likewise.
>>      (check_effective_target_vect_call_btrunc): Likewise.
>>      (check_effective_target_vect_call_btruncf): Likewise.
>>      (check_effective_target_vect_call_ceil): Likewise.
>>      (check_effective_target_vect_call_floorf): Likewise.
>>      (check_effective_target_lto): Likewise.
>>      (check_vect_support_and_set_flags): Likewise.
>>      (check_effective_target_vect_stridedN): Enable when fully masked is
>>      available.
>> ---
> 
> 
>> 
>> diff --git a/gcc/testsuite/gcc.dg/gimplefe-28.c 
>> b/gcc/testsuite/gcc.dg/gimplefe-28.c
>> index 467172d..57b6e1f 100644
>> --- a/gcc/testsuite/gcc.dg/gimplefe-28.c
>> +++ b/gcc/testsuite/gcc.dg/gimplefe-28.c
>> @@ -1,5 +1,5 @@
>> /* { dg-do compile { target sqrt_insn } } */
>> -/* { dg-options "-fgimple -O2" } */
>> +/* { dg-options "-fgimple -O2 -ffast-math" } */
> So why does the GCN need fast-math here?  I'm not aware of any other
> target  that needs that kind of handling to make this test work.
> 
> 
>> diff --git a/gcc/testsuite/gcc.dg/vect/tree-vect.h 
>> b/gcc/testsuite/gcc.dg/vect/tree-vect.h
>> index 69c93ac..2ddfa5e 100644
>> --- a/gcc/testsuite/gcc.dg/vect/tree-vect.h
>> +++ b/gcc/testsuite/gcc.dg/vect/tree-vect.h
>> @@ -1,5 +1,9 @@
>> /* Check if system supports SIMD */
>> +#ifdef __AMDGCN__
>> +#define signal(A,B)
>> +#else
>> #include <signal.h>
>> +#endif
> Presumably you don't have signals.  Though one could make an argument
> that this really shouldn't be exposed in the testsuite.  It kindof sets
> up a need to have this kind of ifdef in any test that wants to include
> signal.h.  Is there no way to create a dummy signal.h with the magic
> #define in whatever fake library you're using?
> 
> 
> The rest seems pretty reasonable.

Since Jeff didn't explicitly say Ok to the rest, let me, Ok for the rest.

I'll Ok the signal one, if you prefer it over a dummy signal routine.  Though, 
would be nice for you to add signal if possible/reasonable.

Reply via email to