This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Fix PR71132
- From: "H.J. Lu" <hjl dot tools at gmail dot com>
- To: Richard Biener <rguenther at suse dot de>
- Cc: GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Wed, 18 May 2016 04:35:44 -0700
- Subject: Re: [PATCH] Fix PR71132
- Authentication-results: sourceware.org; auth=none
- References: <alpine dot LSU dot 2 dot 11 dot 1605171450590 dot 18037 at t29 dot fhfr dot qr> <CAMe9rOoBG3U0tFauEGc5gQcbnSJARe--SAizWU9SP8LvtRnTPA at mail dot gmail dot com> <alpine dot LSU dot 2 dot 11 dot 1605180949230 dot 18037 at t29 dot fhfr dot qr>
On Wed, May 18, 2016 at 12:50 AM, Richard Biener <rguenther@suse.de> wrote:
> On Tue, 17 May 2016, H.J. Lu wrote:
>
>> On Tue, May 17, 2016 at 5:51 AM, Richard Biener <rguenther@suse.de> wrote:
>> >
>> > The following fixes a latent issue in loop distribution catched by
>> > the fake edge placement adjustment.
>> >
>> > Bootstrapped and tested on x86_64-unknown-linux-gnu, applied.
>> >
>> > Richard.
>> >
>> > 2016-05-17 Richard Biener <rguenther@suse.de>
>> >
>> > PR tree-optimization/71132
>> > * tree-loop-distribution.c (create_rdg_cd_edges): Pass in loop.
>> > Only add control dependences for blocks in the loop.
>> > (build_rdg): Adjust.
>> > (generate_code_for_partition): Return whether loop should
>> > be destroyed and delay that.
>> > (distribute_loop): Likewise.
>> > (pass_loop_distribution::execute): Record loops to be destroyed
>> > and perform delayed destroying of loops.
>> >
>> > * gcc.dg/torture/pr71132.c: New testcase.
>> >
>>
>> On x86, this caused:
>>
>> FAIL: c-c++-common/cilk-plus/AN/builtin_fn_custom.c -O3 -fcilkplus
>> (internal compiler error)
>> FAIL: c-c++-common/cilk-plus/AN/builtin_fn_custom.c -O3 -fcilkplus
>> (test for excess errors)
>> FAIL: c-c++-common/cilk-plus/AN/builtin_fn_mutating.c -fcilkplus -O3
>> -std=c99 (internal compiler error)
>> FAIL: c-c++-common/cilk-plus/AN/builtin_fn_mutating.c -fcilkplus -O3
>> -std=c99 (test for excess errors)
>> FAIL: c-c++-common/cilk-plus/AN/builtin_fn_mutating.c -O3 -fcilkplus
>> (internal compiler error)
>> FAIL: c-c++-common/cilk-plus/AN/builtin_fn_mutating.c -O3 -fcilkplus
>> (test for excess errors)
>> FAIL: c-c++-common/cilk-plus/AN/builtin_func_double.c -fcilkplus -O3
>> -std=c99 (internal compiler error)
>> FAIL: c-c++-common/cilk-plus/AN/builtin_func_double.c -fcilkplus -O3
>> -std=c99 (test for excess errors)
>> FAIL: c-c++-common/cilk-plus/AN/builtin_func_double.c -O3 -fcilkplus
>> (internal compiler error)
>> FAIL: c-c++-common/cilk-plus/AN/builtin_func_double.c -O3 -fcilkplus
>> (internal compiler error)
>> FAIL: c-c++-common/cilk-plus/AN/builtin_func_double.c -O3 -fcilkplus
>> (test for excess errors)
>> FAIL: c-c++-common/cilk-plus/AN/builtin_func_double.c -O3 -fcilkplus
>> (test for excess errors)
>> FAIL: c-c++-common/cilk-plus/AN/sec_reduce_ind_same_value.c
>> -fcilkplus -O3 -std=c99 (internal compiler error)
>> FAIL: c-c++-common/cilk-plus/AN/sec_reduce_ind_same_value.c
>> -fcilkplus -O3 -std=c99 (test for excess errors)
>> FAIL: c-c++-common/cilk-plus/AN/sec_reduce_ind_same_value.c -O3
>> -fcilkplus (internal compiler error)
>> FAIL: c-c++-common/cilk-plus/AN/sec_reduce_ind_same_value.c -O3
>> -fcilkplus (test for excess errors)
>> FAIL: gcc.c-torture/compile/pr32399.c -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (internal
>> compiler error)
>> FAIL: gcc.c-torture/compile/pr32399.c -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (test for
>> excess errors)
>> FAIL: gcc.c-torture/compile/pr32399.c -O3 -g (internal compiler error)
>> FAIL: gcc.c-torture/compile/pr32399.c -O3 -g (test for excess errors)
>> FAIL: gcc.c-torture/execute/20010221-1.c -O3 -g (internal compiler error)
>> FAIL: gcc.c-torture/execute/20010221-1.c -O3 -g (test for excess errors)
>> FAIL: gcc.c-torture/execute/20120919-1.c -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (internal
>> compiler error)
>> FAIL: gcc.c-torture/execute/20120919-1.c -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (test for
>> excess errors)
>> FAIL: gcc.c-torture/execute/20120919-1.c -O3 -g (internal compiler error)
>> FAIL: gcc.c-torture/execute/20120919-1.c -O3 -g (test for excess errors)
>> FAIL: gcc.dg/torture/pr61383-1.c -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (internal
>> compiler error)
>> FAIL: gcc.dg/torture/pr61383-1.c -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (test for
>> excess errors)
>> FAIL: gcc.dg/torture/pr69452.c -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (internal
>> compiler error)
>> FAIL: gcc.dg/torture/pr69452.c -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (test for
>> excess errors)
>> FAIL: gcc.dg/torture/pr69452.c -O3 -g (internal compiler error)
>> FAIL: gcc.dg/torture/pr69452.c -O3 -g (test for excess errors)
>> FAIL: g++.dg/cilk-plus/AN/builtin_fn_mutating_tplt.cc -g -O3
>> -fcilkplus (internal compiler error)
>> FAIL: g++.dg/cilk-plus/AN/builtin_fn_mutating_tplt.cc -g -O3
>> -fcilkplus (test for excess errors)
>> FAIL: g++.dg/cilk-plus/AN/builtin_fn_mutating_tplt.cc -O3 -fcilkplus
>> (internal compiler error)
>> FAIL: g++.dg/cilk-plus/AN/builtin_fn_mutating_tplt.cc -O3 -fcilkplus
>> (test for excess errors)
>> FAIL: g++.dg/cilk-plus/AN/builtin_fn_mutating_tplt.cc -O3
>> -ftree-vectorize -fcilkplus -g (internal compiler error)
>> FAIL: g++.dg/cilk-plus/AN/builtin_fn_mutating_tplt.cc -O3
>> -ftree-vectorize -fcilkplus -g (test for excess errors)
>> FAIL: gfortran.dg/do_concurrent_2.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (internal
>> compiler error)
>> FAIL: gfortran.dg/do_concurrent_2.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (test for
>> excess errors)
>> FAIL: gfortran.dg/forall_4.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions execution
>> test
>> FAIL: gfortran.dg/forall_4.f90 -O3 -g execution test
>> FAIL: gfortran.dg/intrinsic_modulo_1.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (internal
>> compiler error)
>> FAIL: gfortran.dg/intrinsic_modulo_1.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (test for
>> excess errors)
>> FAIL: gfortran.dg/maxloc_2.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (internal
>> compiler error)
>> FAIL: gfortran.dg/maxloc_2.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (test for
>> excess errors)
>> FAIL: gfortran.dg/maxloc_2.f90 -O3 -g (internal compiler error)
>> FAIL: gfortran.dg/maxloc_2.f90 -O3 -g (test for excess errors)
>> FAIL: gfortran.dg/maxlocval_2.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (internal
>> compiler error)
>> FAIL: gfortran.dg/maxlocval_2.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (test for
>> excess errors)
>> FAIL: gfortran.dg/maxlocval_2.f90 -O3 -g (internal compiler error)
>> FAIL: gfortran.dg/maxlocval_2.f90 -O3 -g (test for excess errors)
>> FAIL: gfortran.dg/minloc_1.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (internal
>> compiler error)
>> FAIL: gfortran.dg/minloc_1.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (test for
>> excess errors)
>> FAIL: gfortran.dg/minloc_1.f90 -O3 -g (internal compiler error)
>> FAIL: gfortran.dg/minloc_1.f90 -O3 -g (test for excess errors)
>> FAIL: gfortran.dg/minloc_3.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (internal
>> compiler error)
>> FAIL: gfortran.dg/minloc_3.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (test for
>> excess errors)
>> FAIL: gfortran.dg/minloc_3.f90 -O3 -g (internal compiler error)
>> FAIL: gfortran.dg/minloc_3.f90 -O3 -g (test for excess errors)
>> FAIL: gfortran.dg/minlocval_1.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (internal
>> compiler error)
>> FAIL: gfortran.dg/minlocval_1.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (test for
>> excess errors)
>> FAIL: gfortran.dg/minlocval_1.f90 -O3 -g (internal compiler error)
>> FAIL: gfortran.dg/minlocval_1.f90 -O3 -g (test for excess errors)
>> FAIL: gfortran.dg/minlocval_3.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (internal
>> compiler error)
>> FAIL: gfortran.dg/minlocval_3.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (test for
>> excess errors)
>> FAIL: gfortran.dg/minlocval_3.f90 -O3 -g (internal compiler error)
>> FAIL: gfortran.dg/minlocval_3.f90 -O3 -g (test for excess errors)
>> FAIL: gfortran.dg/minmaxloc_4.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (internal
>> compiler error)
>> FAIL: gfortran.dg/minmaxloc_4.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (test for
>> excess errors)
>> FAIL: gfortran.dg/minmaxloc_5.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (internal
>> compiler error)
>> FAIL: gfortran.dg/minmaxloc_5.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (test for
>> excess errors)
>> FAIL: gfortran.dg/minmaxloc_5.f90 -O3 -g (internal compiler error)
>> FAIL: gfortran.dg/minmaxloc_5.f90 -O3 -g (test for excess errors)
>> FAIL: gfortran.dg/minmaxloc_6.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (internal
>> compiler error)
>> FAIL: gfortran.dg/minmaxloc_6.f90 -O3 -fomit-frame-pointer
>> -funroll-loops -fpeel-loops -ftracer -finline-functions (test for
>> excess errors)
>> FAIL: gfortran.dg/minmaxloc_6.f90 -O3 -g (internal compiler error)
>> FAIL: gfortran.dg/minmaxloc_6.f90 -O3 -g (test for excess errors)
>> FAIL: gfortran.dg/PR19754_2.f90 -O3 -g (internal compiler error)
>> FAIL: gfortran.dg/PR19754_2.f90 -O3 -g (test for excess errors)
>> FAIL: gfortran.fortran-torture/compile/pr70960.f90, -O3 -g
>> (internal compiler error)
>> FAIL: gfortran.fortran-torture/execute/intrinsic_count.f90, -O3 -g
>> (internal compiler error)
>> FAIL: gfortran.fortran-torture/execute/intrinsic_product.f90, -O3 -g
>> (internal compiler error)
>> FAIL: gfortran.fortran-torture/execute/intrinsic_sum.f90, -O3 -g
>> (internal compiler error)
>> FAIL: gfortran.fortran-torture/execute/where20.f90, -O3 -g (internal
>> compiler error)
>
> I can't reproduce any of the above on x86_64 with -m32, nor with
> additional -march=i586 -march=i686 or -march=core-avx2. Can you
> be more specific on what is needed to reproduce it?
You MUST build it as an 32-bit GCC, not 64-bit GCC. I am using
CC="gcc -fno-lto -m32" CXX="g++ -fno-lto -m32" BOOT_CFLAGS="-g"
BOOT_CXXFLAGS="-g" CFLAGS="-g" CXXFLAGS="-g"
RUNTESTFLAGS="--target_board='unix'"
/export/gnu/import/git/sources/gcc/configure --enable-languages=c,c++
--disable-bootstrap i686-linux --prefix=/usr/gcc-7.0.0
--with-local-prefix=/usr/local --enable-gnu-indirect-function
--enable-libmpx --disable-libcc1 --disable-libcilkrts
--disable-libsanitizer --enable-clocale=gnu --with-system-zlib
--with-demangler-in-ld --with-fpmath=sse
on x86-64.
H.J.