Hi Jakub, > This patch fixes a bunch of recent regressions: > FAIL: gcc.target/i386/avx-1.c (internal compiler error) > FAIL: gcc.target/i386/avx-1.c (test for excess errors) > FAIL: gcc.target/i386/avx-2.c (internal compiler error) > FAIL: gcc.target/i386/avx-2.c (test for excess errors) > FAIL: gcc.target/i386/avx512f-vec-init.c (internal compiler error) > FAIL: gcc.target/i386/avx512f-vec-init.c (test for excess errors) > UNRESOLVED: gcc.target/i386/avx512f-vec-init.c scan-assembler-times > vbroadcastsd 1 > UNRESOLVED: gcc.target/i386/avx512f-vec-init.c scan-assembler-times > vbroadcastss 1 > UNRESOLVED: gcc.target/i386/avx512f-vec-init.c scan-assembler-times > vmovdqa64[ \\\\t]+%zmm 2 > UNRESOLVED: gcc.target/i386/avx512f-vec-init.c scan-assembler-times > vpbroadcastb 2 > UNRESOLVED: gcc.target/i386/avx512f-vec-init.c scan-assembler-times > vpbroadcastd 1 > UNRESOLVED: gcc.target/i386/avx512f-vec-init.c scan-assembler-times > vpbroadcastq 1 > UNRESOLVED: gcc.target/i386/avx512f-vec-init.c scan-assembler-times > vpbroadcastw 2 > FAIL: gcc.target/i386/sse-14.c (internal compiler error) > FAIL: gcc.target/i386/sse-14.c (test for excess errors) > FAIL: gcc.target/i386/sse-22.c (internal compiler error) > FAIL: gcc.target/i386/sse-22.c (test for excess errors) > FAIL: gcc.target/i386/sse-22a.c (internal compiler error) > FAIL: gcc.target/i386/sse-22a.c (test for excess errors) > FAIL: gcc.target/i386/sse-23.c (internal compiler error) > FAIL: gcc.target/i386/sse-23.c (test for excess errors) > FAIL: gcc.target/i386/sse-24.c (internal compiler error) > FAIL: gcc.target/i386/sse-24.c (test for excess errors) > and improves quality of code generated for AVX2 and AVX512F broadcasts; > as AVX2 broadcast instructions can have source in memory or vector register > (but only AVX512F can have it in GPRs), the patch adds splitter for the > GPR case and adds ! for that, so that RA can choose what is best and if > broadcast from GPR is desirable, it first performs vmovd from GPR into > the dest register and then vpbroadcast{b,w,d} it. > > The AVX512* patterns should be IMHO merged, so that whether GPR or MEM is used > are just alternatives of the same define_insn rather than different > define_insns, > but am not changing that right now, will leave that to Kirill as a follow-up. > > Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk? [...] > * gcc.dg/pr63594-1.c: New test. > * gcc.dg/pr63594-2.c: New test.
Unfortunately, I see some problems with those tests on Solaris: * On Solaris/x86, I get FAIL: gcc.dg/pr63594-2.c execution test for 32-bit. Any particular reason to restrict -mno-mmx to Linux/x86? Manually building the testcase with -mno-mmx on Solaris/x86 seems to cure the failure. * On 64-bit Solaris/SPARC, I get FAIL: gcc.dg/pr63594-1.c (internal compiler error) FAIL: gcc.dg/pr63594-1.c (test for excess errors) /vol/gcc/src/hg/trunk/local/gcc/testsuite/gcc.dg/pr63594-1.c: In function 'test1float1': /vol/gcc/src/hg/trunk/local/gcc/testsuite/gcc.dg/pr63594-1.c:19:1: internal compiler error: Bus Error /vol/gcc/src/hg/trunk/local/gcc/testsuite/gcc.dg/pr63594-1.c:57:1: note: in expansion of macro 'T' 0x751c03 crash_signal /vol/gcc/src/hg/trunk/local/gcc/toplev.c:349 0x44ffb4 gen_group_rtx(rtx_def*) /vol/gcc/src/hg/trunk/local/gcc/expr.c:1624 0x4f8167 expand_function_start(tree_node*) /vol/gcc/src/hg/trunk/local/gcc/function.c:4803 0x36278f execute /vol/gcc/src/hg/trunk/local/gcc/cfgexpand.c:5709 In gdb, I see a SEGV instead: Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 1 (LWP 1)] gen_group_rtx (orig=0xfb5a3690) at /vol/gcc/src/hg/trunk/local/gcc/expr.c:1624 1624 if (i) (gdb) where #0 gen_group_rtx (orig=0xfb5a3690) at /vol/gcc/src/hg/trunk/local/gcc/expr.c:1624 #1 0x004f8168 in expand_function_start (subr=0xfb497680) at /vol/gcc/src/hg/trunk/local/gcc/function.c:4803 #2 0x00362790 in (anonymous namespace)::pass_expand::execute ( this=<optimized out>, fun=0xfb4a11e0) at /vol/gcc/src/hg/trunk/local/gcc/cfgexpand.c:5709 #3 0x006819b8 in execute_one_pass (pass=pass@entry=0x112aab0) at /vol/gcc/src/hg/trunk/local/gcc/passes.c:2156 #4 0x00682020 in execute_pass_list_1 (pass=0x112aab0, pass@entry=0x1128610) at /vol/gcc/src/hg/trunk/local/gcc/passes.c:2208 #5 0x00682088 in execute_pass_list (fn=0xfb4a11e0, pass=0x1128610) at /vol/gcc/src/hg/trunk/local/gcc/passes.c:2219 #6 0x0038fda4 in cgraph_node::expand (this=this@entry=0xfb4b2700) at /vol/gcc/src/hg/trunk/local/gcc/cgraphunit.c:1742 #7 0x003918c4 in expand_all_functions () at /vol/gcc/src/hg/trunk/local/gcc/cgraphunit.c:1878 #8 symbol_table::compile (this=0xfb410000) at /vol/gcc/src/hg/trunk/local/gcc/cgraphunit.c:2213 #9 0x003935f0 in symbol_table::finalize_compilation_unit (this=0xfb410000) at /vol/gcc/src/hg/trunk/local/gcc/cgraphunit.c:2290 #10 0x002205dc in c_write_global_declarations () at /vol/gcc/src/hg/trunk/local/gcc/c/c-decl.c:10640 #11 0x00751cc4 in compile_file () at /vol/gcc/src/hg/trunk/local/gcc/toplev.c:574 #12 0x00e20b10 in toplev::main(int, char**) () #13 0x00e21344 in main (argc=20, argv=0xffbff43c) at /vol/gcc/src/hg/trunk/local/gcc/main.c:38 FAIL: gcc.dg/pr63594-2.c (internal compiler error) FAIL: gcc.dg/pr63594-2.c (test for excess errors) WARNING: gcc.dg/pr63594-2.c compilation failed to produce executable Rainer -- ----------------------------------------------------------------------------- Rainer Orth, Center for Biotechnology, Bielefeld University