public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug ada/53590] New: new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function
@ 2012-06-06 13:14 bauhaus at futureapps dot de
  2012-06-06 13:29 ` [Bug ada/53590] " bauhaus at futureapps dot de
                   ` (14 more replies)
  0 siblings, 15 replies; 16+ messages in thread
From: bauhaus at futureapps dot de @ 2012-06-06 13:14 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53590

             Bug #: 53590
           Summary: new compiler generates both SISD and SIMD instructions
                    for parallel operations of a "pure" function
    Classification: Unclassified
           Product: gcc
           Version: 4.8.0
            Status: UNCONFIRMED
          Severity: enhancement
          Priority: P3
         Component: ada
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: bauhaus@futureapps.de


The Ada compiler of 4.8.0 on Intel will either
- produce 2 DIVSD and also 1 DIVPD (redundance), or
- produce 2 DIVSD (no measurable parallelism)
for the following function f that divides two pairs
of 64 bit FPT types and returns one pair.
The expectation is just 1 DIVPD.
Other versions of the Ada compiler, and the C compiler,
and the C++ compiler of the same version produce
1 DIVPD instruction, as expected.

The line marked --! below switches between the two cases
listed above.

package Autovect is

   pragma Pure (Autovect);

   type Fpt is new Long_Float;

   type Vec is array (0 .. 1) of Fpt;
   --pragma Machine_Attribute (Vec, "vector_type");  --!
   --pragma Machine_Attribute (Vec, "may_alias");  

   function F (X0, X1, Y0, Y1 : Fpt) return Vec;

private
   pragma Assert (Fpt'Size = 64);
   pragma Assert (Vec'Alignment = 16);
end Autovect;

package body Autovect is

   function F (X0, X1, Y0, Y1 : Fpt) return Vec is
   begin
      return (X0 / Y0, X1 / Y1);
   end F;

end Autovect;

Result:

0000000000000010 <autovect__f>:
  10:    66 0f 28 e8              movapd %xmm0,%xmm5
  14:    66 0f 28 f2              movapd %xmm2,%xmm6
  18:    66 0f 14 e9              unpcklpd %xmm1,%xmm5
  1c:    66 0f 14 f3              unpcklpd %xmm3,%xmm6
  20:    f2 0f 5e c2              divsd  %xmm2,%xmm0
  24:    66 0f 28 e5              movapd %xmm5,%xmm4
  28:    66 0f 5e e6              divpd  %xmm6,%xmm4
  2c:    f2 0f 5e cb              divsd  %xmm3,%xmm1
  30:    66 0f 29 64 24 e8        movapd %xmm4,-0x18(%rsp)
  36:    f2 0f 10 44 24 e8        movsd  -0x18(%rsp),%xmm0
  3c:    f2 0f 10 4c 24 f0        movsd  -0x10(%rsp),%xmm1
  42:    c3                       retq   
  43:    66 66 66 66 2e 0f 1f     data32 data32 data32 nopw
%cs:0x0(%rax,%rax,1)
  4a:    84 00 00 00 00 00 

With "vector_type" machine attribute:

0000000000000010 <autovect__f>:
  10:    f2 0f 5e c2              divsd  %xmm2,%xmm0
  14:    f2 0f 5e cb              divsd  %xmm3,%xmm1
  18:    66 0f 14 c1              unpcklpd %xmm1,%xmm0
  1c:    c3                       retq   
  1d:    0f 1f 00                 nopl   (%rax)


gnatchop -r -w autovect.ada && gnatmake -gnatwa -W -O3 -fno-inline
-fomit-frame-pointer -msse3 -march=core2 -gnatp -gnata -v autovect.adb
splitting autovect.ada into:
   autovect.ads
   autovect.adb

GNATMAKE 4.8.0 20120525 (experimental)
Copyright (C) 1995-2012, Free Software Foundation, Inc.
  "autovect.ali" being checked ...
  -> "autovect.ads" time stamp mismatch
gcc -c -gnatwa -W -O3 -fno-inline -fomit-frame-pointer -msse3 -march=core2
-gnatp -gnata autovect.adb
End of compilation

Linux newnews 3.2.0-24-generic #39-Ubuntu SMP Mon May 21 16:52:17 UTC 2012
x86_64 x86_64 x86_64 GNU/Linux

Intel E6750

$ gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/home/bauhaus/mine/libexec/gcc/x86_64-unknown-linux-gnu/4.8.0/lto-wrapper
Target: x86_64-unknown-linux-gnu
Configured with: /home/bauhaus/src/gcc/trunk/configure
--prefix=/home/bauhaus/mine --disable-nls --disable-libstdcxx-pch
--enable-languages=c,ada,c++
Thread model: posix
gcc version 4.8.0 20120525 (experimental) (GCC)


^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug ada/53590] new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function
  2012-06-06 13:14 [Bug ada/53590] New: new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function bauhaus at futureapps dot de
@ 2012-06-06 13:29 ` bauhaus at futureapps dot de
  2012-06-10  8:42 ` ebotcazou at gcc dot gnu.org
                   ` (13 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: bauhaus at futureapps dot de @ 2012-06-06 13:29 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53590

--- Comment #1 from Georg Bauhaus <bauhaus at futureapps dot de> 2012-06-06 13:29:36 UTC ---
For comparison, consider this, giving expected results (1 DIVPD).

-- 8< --

typedef double fpt;

typedef fpt Vec[2];
struct ArrayWrap {
  Vec _;
};


struct ArrayWrap f (fpt x0, fpt x1, fpt y0, fpt y1) {
    return (struct ArrayWrap) { ._ = { x0 / y0, x1 / y1 } };
}

-- >8 --

(The corresponding Ada is

   type ArrayWrap is record
      Data : Vec;
   end record;

(and

   function F (X0, X1, Y0, Y1 : Fpt) return ArrayWrap is
   begin
      return (Data => (X0 / Y0, X1 / Y1));
   end F;

giving the same results as originally reported, i.e. two DIVSD and
in addition one DIVPD.)

The C compiler (from the same build), when run with the same options,

$ gcc -c -W -O3 -fno-inline -fomit-frame-pointer -msse3 -mfpmath=sse
-march=core2 autovect.c

produces

0000000000000000 <f>:
   0:    66 0f 14 c1              unpcklpd %xmm1,%xmm0
   4:    66 0f 14 d3              unpcklpd %xmm3,%xmm2
   8:    66 0f 5e c2              divpd  %xmm2,%xmm0
   c:    66 0f 29 44 24 e8        movapd %xmm0,-0x18(%rsp)
  12:    f2 0f 10 4c 24 f0        movsd  -0x10(%rsp),%xmm1
  18:    f2 0f 10 44 24 e8        movsd  -0x18(%rsp),%xmm0
  1e:    c3                       retq 

Which has one DIVPD, as expected.


^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug ada/53590] new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function
  2012-06-06 13:14 [Bug ada/53590] New: new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function bauhaus at futureapps dot de
  2012-06-06 13:29 ` [Bug ada/53590] " bauhaus at futureapps dot de
@ 2012-06-10  8:42 ` ebotcazou at gcc dot gnu.org
  2012-06-11  9:53 ` rguenth at gcc dot gnu.org
                   ` (12 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: ebotcazou at gcc dot gnu.org @ 2012-06-10  8:42 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53590

Eric Botcazou <ebotcazou at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ebotcazou at gcc dot
                   |                            |gnu.org

--- Comment #2 from Eric Botcazou <ebotcazou at gcc dot gnu.org> 2012-06-10 08:42:01 UTC ---
> Other versions of the Ada compiler, and the C compiler,
> and the C++ compiler of the same version produce
> 1 DIVPD instruction, as expected.

Which other versions of the Ada compiler exactly?


^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug ada/53590] new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function
  2012-06-06 13:14 [Bug ada/53590] New: new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function bauhaus at futureapps dot de
  2012-06-06 13:29 ` [Bug ada/53590] " bauhaus at futureapps dot de
  2012-06-10  8:42 ` ebotcazou at gcc dot gnu.org
@ 2012-06-11  9:53 ` rguenth at gcc dot gnu.org
  2012-06-11 10:09 ` georggcc at googlemail dot com
                   ` (11 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: rguenth at gcc dot gnu.org @ 2012-06-11  9:53 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53590

Richard Guenther <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |WAITING
   Last reconfirmed|                            |2012-06-11
     Ever Confirmed|0                           |1


^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug ada/53590] new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function
  2012-06-06 13:14 [Bug ada/53590] New: new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function bauhaus at futureapps dot de
                   ` (2 preceding siblings ...)
  2012-06-11  9:53 ` rguenth at gcc dot gnu.org
@ 2012-06-11 10:09 ` georggcc at googlemail dot com
  2012-06-11 10:31 ` georggcc at googlemail dot com
                   ` (10 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: georggcc at googlemail dot com @ 2012-06-11 10:09 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53590

--- Comment #3 from Georg <georggcc at googlemail dot com> 2012-06-11 10:09:18 UTC ---
(In reply to comment #2)
> > Other versions of the Ada compiler, and the C compiler,
> > and the C++ compiler of the same version produce
> > 1 DIVPD instruction, as expected.
> 
> Which other versions of the Ada compiler exactly?

For example, GNAT GPL 2011 on Mac OS X 10.7.4; I get (that's
the version of the source text with none of the
pragmas in effect)

$ gnatchop -r -w ../autovect.ada && gnatmake -gnatwa -W -O3 -fno-inline
-fomit-frame-pointer -msse3 -march=core2 -gnatp -gnata -v -mfpmath=sse -f
autovect.adb
splitting ../autovect.ada into:
   autovect.ads
   autovect.adb

GNATMAKE GPL 2011 (20110419)
Copyright (C) 1995-2011, Free Software Foundatio machine_attribute n, Inc.
gcc -c -gnatwa -W -O3 -fno-inline -fomit-frame-pointer -msse3 -march=core2
-gnatp -gnata -mfpmath=sse autovect.adb
End of compilation
$ otool -tv autovect.o
autovect.o:
(__TEXT,__text) section
_autovect__TvecBIP:
0000000000000000    ret
0000000000000001    nop
0000000000000002    nopl    0x00000000(%rax)
0000000000000009    nopl    0x00000000(%rax)
_autovect__f:
0000000000000010    unpcklpd    %xmm1,%xmm0
0000000000000014    unpcklpd    %xmm3,%xmm2
0000000000000018    divpd    %xmm2,%xmm0
000000000000001c    movapd    %xmm0,0xe8(%rsp)
0000000000000022    movsd    0xe8(%rsp),%xmm0
0000000000000028    movsd    0xf0(%rsp),%xmm1
000000000000002e    ret
000000000000002f    nop
_autovect___elabs:
0000000000000030    subq    $0x18,%rsp
0000000000000034    leaq    0x00000015(%rip),%rdi
000000000000003b    leaq    0x0000001e(%rip),%rsi
0000000000000042    movq    %rdi,(%rsp)
0000000000000046    movq    %rsi,0x08(%rsp)
000000000000004b    callq    0x00000050


$ sysctl machdep.cpu
...
machdep.cpu.brand_string: Intel(R) Core(TM)2 Duo CPU     E8135  @ 2.40GHz
machdep.cpu.features: FPU VME DE PSE TSC MSR PAE MCE CX8 APIC SEP MTRR PGE MCA
CMOV PAT PSE36 CLFSH DS ACPI MMX FXSR SSE SSE2 SS HTT TM PBE SSE3 DTES64 MON
DSCPL VMX EST TM2 SSSE3 CX16 TPR PDCM SSE4.1
machdep.cpu.extfeatures: SYSCALL XD EM64T LAHF

I'll double check more running on an Intel Core i7 tonight.


^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug ada/53590] new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function
  2012-06-06 13:14 [Bug ada/53590] New: new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function bauhaus at futureapps dot de
                   ` (3 preceding siblings ...)
  2012-06-11 10:09 ` georggcc at googlemail dot com
@ 2012-06-11 10:31 ` georggcc at googlemail dot com
  2012-06-11 10:39 ` [Bug ada/53590] compiler fails to generate SIMD instruction for FP division ebotcazou at gcc dot gnu.org
                   ` (9 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: georggcc at googlemail dot com @ 2012-06-11 10:31 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53590

--- Comment #4 from Georg <georggcc at googlemail dot com> 2012-06-11 10:31:00 UTC ---
(In reply to comment #3)
> (In reply to comment #2)
> > > Other versions of the Ada compiler, and the C compiler,
> > > and the C++ compiler of the same version produce
> > > 1 DIVPD instruction, as expected.
> > 
> > Which other versions of the Ada compiler exactly?
> 
> For example, GNAT GPL 2011 on Mac OS X 10.7.4; 

Small note: Same sequence of instructions from GNAT GPL 2011
running on x86_64 Linux/GNU:

0000000000000010 <autovect__f>:
  10:    66 0f 14 c1              unpcklpd %xmm1,%xmm0
  14:    66 0f 14 d3              unpcklpd %xmm3,%xmm2
  18:    66 0f 5e c2              divpd  %xmm2,%xmm0
  1c:    66 0f 29 44 24 e8        movapd %xmm0,-0x18(%rsp)
  22:    f2 0f 10 44 24 e8        movsd  -0x18(%rsp),%xmm0
  28:    f2 0f 10 4c 24 f0        movsd  -0x10(%rsp),%xmm1
  2e:    c3                       retq   
  2f:    90                       nop

Intel(R) Xeon(R) CPU           E5645  @ 2.40GHz


^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug ada/53590] compiler fails to generate SIMD instruction for FP division
  2012-06-06 13:14 [Bug ada/53590] New: new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function bauhaus at futureapps dot de
                   ` (4 preceding siblings ...)
  2012-06-11 10:31 ` georggcc at googlemail dot com
@ 2012-06-11 10:39 ` ebotcazou at gcc dot gnu.org
  2012-06-11 10:59 ` georggcc at googlemail dot com
                   ` (8 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: ebotcazou at gcc dot gnu.org @ 2012-06-11 10:39 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53590

Eric Botcazou <ebotcazou at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|WAITING                     |UNCONFIRMED
            Summary|new compiler generates both |compiler fails to generate
                   |SISD and SIMD instructions  |SIMD instruction for FP
                   |for parallel operations of  |division
                   |a "pure" function           |
     Ever Confirmed|1                           |0

--- Comment #5 from Eric Botcazou <ebotcazou at gcc dot gnu.org> 2012-06-11 10:39:38 UTC ---
> Small note: Same sequence of instructions from GNAT GPL 2011
> running on x86_64 Linux/GNU:

You're comparing apples with oranges though, that isn't the same compiler.


^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug ada/53590] compiler fails to generate SIMD instruction for FP division
  2012-06-06 13:14 [Bug ada/53590] New: new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function bauhaus at futureapps dot de
                   ` (5 preceding siblings ...)
  2012-06-11 10:39 ` [Bug ada/53590] compiler fails to generate SIMD instruction for FP division ebotcazou at gcc dot gnu.org
@ 2012-06-11 10:59 ` georggcc at googlemail dot com
  2012-06-12 16:54 ` ebotcazou at gcc dot gnu.org
                   ` (7 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: georggcc at googlemail dot com @ 2012-06-11 10:59 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53590

--- Comment #6 from Georg <georggcc at googlemail dot com> 2012-06-11 10:59:41 UTC ---
(In reply to comment #5)
> > Small note: Same sequence of instructions from GNAT GPL 2011
> > running on x86_64 Linux/GNU:
> 
> You're comparing apples with oranges though, that isn't the same compiler.

OK. Although, this supports even more what I said,
"Other versions of the Ada compiler..." ;-)

That wasn't particularly clear; the C compiler and the C++ compiler
used for comparing things on the machine are form the very
same build (4.8.0 20120525), though.


^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug ada/53590] compiler fails to generate SIMD instruction for FP division
  2012-06-06 13:14 [Bug ada/53590] New: new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function bauhaus at futureapps dot de
                   ` (6 preceding siblings ...)
  2012-06-11 10:59 ` georggcc at googlemail dot com
@ 2012-06-12 16:54 ` ebotcazou at gcc dot gnu.org
  2012-06-13 17:12 ` [Bug middle-end/53590] " georggcc at googlemail dot com
                   ` (6 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: ebotcazou at gcc dot gnu.org @ 2012-06-12 16:54 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53590

Eric Botcazou <ebotcazou at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |ASSIGNED
   Last reconfirmed|2012-06-11 00:00:00         |2012-06-12
         AssignedTo|unassigned at gcc dot       |ebotcazou at gcc dot
                   |gnu.org                     |gnu.org
     Ever Confirmed|0                           |1

--- Comment #7 from Eric Botcazou <ebotcazou at gcc dot gnu.org> 2012-06-12 16:54:36 UTC ---
> That wasn't particularly clear; the C compiler and the C++ compiler
> used for comparing things on the machine are form the very
> same build (4.8.0 20120525), though.

Yes, it's a fallout of -fnon-call-exceptions that stems from the Java
semantics.  GNAT GPL doesn't care about Java so it implements more aggressive
dead code elimination passes.  We could add an internal flag enabling this
behavior.


^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug middle-end/53590] compiler fails to generate SIMD instruction for FP division
  2012-06-06 13:14 [Bug ada/53590] New: new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function bauhaus at futureapps dot de
                   ` (7 preceding siblings ...)
  2012-06-12 16:54 ` ebotcazou at gcc dot gnu.org
@ 2012-06-13 17:12 ` georggcc at googlemail dot com
  2012-06-15  9:22 ` ebotcazou at gcc dot gnu.org
                   ` (5 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: georggcc at googlemail dot com @ 2012-06-13 17:12 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53590

--- Comment #8 from Georg <georggcc at googlemail dot com> 2012-06-13 17:11:58 UTC ---
(In reply to comment #7)

> Yes, it's a fallout of -fnon-call-exceptions that stems from the Java
> semantics.  GNAT GPL doesn't care about Java so it implements more aggressive
> dead code elimination passes.  We could add an internal flag enabling this
> behavior.

FWIW, being able to toggle desirable effects of being more aggressive
should be most welcome in scientific computing where the competition
(or co-operation!) runs Fortran programs on scores of Intel (compatible)
processors.


^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug middle-end/53590] compiler fails to generate SIMD instruction for FP division
  2012-06-06 13:14 [Bug ada/53590] New: new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function bauhaus at futureapps dot de
                   ` (8 preceding siblings ...)
  2012-06-13 17:12 ` [Bug middle-end/53590] " georggcc at googlemail dot com
@ 2012-06-15  9:22 ` ebotcazou at gcc dot gnu.org
  2012-06-15 10:00 ` ebotcazou at gcc dot gnu.org
                   ` (4 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: ebotcazou at gcc dot gnu.org @ 2012-06-15  9:22 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53590

--- Comment #9 from Eric Botcazou <ebotcazou at gcc dot gnu.org> 2012-06-15 09:22:04 UTC ---
Author: ebotcazou
Date: Fri Jun 15 09:22:00 2012
New Revision: 188651

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=188651
Log:
    PR middle-end/53590
    * common.opt (-fdelete-dead-exceptions): New switch.
    * doc/invoke.texi (Code Gen Options): Document it.
    * cse.c (count_reg_usage) <CALL_INSN>: Use !insn_nothrow_p in lieu of
    insn_could_throw_p predicate.  Do not skip an insn that could throw
    if dead exceptions can be deleted.
    (insn_live_p): Likewise, do not return true in that case.
    * dce.c (can_alter_cfg): New flag.
    (deletable_insn_p): Do not return false for an insn that can throw if
    the CFG can be altered and dead exceptions can be deleted.
    (init_dce): Set can_alter_cfg to false for fast DCE, true otherwise.
    * dse.c (scan_insn): Use !insn_nothrow_p in lieu of insn_could_throw_
    predicate. Do not preserve an insn that could throw if dead exceptions
    can be deleted.
    * function.h (struct function): Add can_delete_dead_exceptions flag.
    * function.c (allocate_struct_function): Set it.
    * lto-streamer-in.c (input_struct_function_base): Stream it.
    * lto-streamer-out.c (input_struct_function_base): Likewise.
    * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Do not mark a
    statement that could throw as necessary if dead exceptions can be
    deleted.
ada/
    * gcc-interface/misc.c (gnat_init_options_struct): Set
    opts->x_flag_delete_dead_exceptions to 1.

Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/ada/ChangeLog
    trunk/gcc/ada/gcc-interface/misc.c
    trunk/gcc/common.opt
    trunk/gcc/cse.c
    trunk/gcc/dce.c
    trunk/gcc/doc/invoke.texi
    trunk/gcc/dse.c
    trunk/gcc/function.c
    trunk/gcc/function.h
    trunk/gcc/lto-streamer-in.c
    trunk/gcc/lto-streamer-out.c
    trunk/gcc/tree-ssa-dce.c


^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug middle-end/53590] compiler fails to generate SIMD instruction for FP division
  2012-06-06 13:14 [Bug ada/53590] New: new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function bauhaus at futureapps dot de
                   ` (9 preceding siblings ...)
  2012-06-15  9:22 ` ebotcazou at gcc dot gnu.org
@ 2012-06-15 10:00 ` ebotcazou at gcc dot gnu.org
  2012-06-15 14:54 ` georggcc at googlemail dot com
                   ` (3 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: ebotcazou at gcc dot gnu.org @ 2012-06-15 10:00 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53590

Eric Botcazou <ebotcazou at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED
   Target Milestone|---                         |4.8.0

--- Comment #10 from Eric Botcazou <ebotcazou at gcc dot gnu.org> 2012-06-15 10:00:25 UTC ---
Fixed on the mainline.


^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug middle-end/53590] compiler fails to generate SIMD instruction for FP division
  2012-06-06 13:14 [Bug ada/53590] New: new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function bauhaus at futureapps dot de
                   ` (10 preceding siblings ...)
  2012-06-15 10:00 ` ebotcazou at gcc dot gnu.org
@ 2012-06-15 14:54 ` georggcc at googlemail dot com
  2012-06-16 11:06 ` ebotcazou at gcc dot gnu.org
                   ` (2 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: georggcc at googlemail dot com @ 2012-06-15 14:54 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53590

--- Comment #11 from Georg <georggcc at googlemail dot com> 2012-06-15 14:54:21 UTC ---
(In reply to comment #10)
> Fixed on the mainline.

Perfect result when run with -fdelete-dead-exceptions, or when
run without the switch (i.e., switches as before).

Adding -fno-delete-dead-exceptions,  I see the old (expected?)
redundant ..., divsd, movapd, divpd, divsd, movapd,  ... sequence,
though. Just mentioning.


^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug middle-end/53590] compiler fails to generate SIMD instruction for FP division
  2012-06-06 13:14 [Bug ada/53590] New: new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function bauhaus at futureapps dot de
                   ` (11 preceding siblings ...)
  2012-06-15 14:54 ` georggcc at googlemail dot com
@ 2012-06-16 11:06 ` ebotcazou at gcc dot gnu.org
  2014-07-10 10:39 ` ebotcazou at gcc dot gnu.org
  2014-07-10 10:41 ` ebotcazou at gcc dot gnu.org
  14 siblings, 0 replies; 16+ messages in thread
From: ebotcazou at gcc dot gnu.org @ 2012-06-16 11:06 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53590

--- Comment #12 from Eric Botcazou <ebotcazou at gcc dot gnu.org> 2012-06-16 11:05:48 UTC ---
Author: ebotcazou
Date: Sat Jun 16 11:05:43 2012
New Revision: 188691

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=188691
Log:
    PR middle-end/53590
    * tree-inline.c (initialize_cfun): Copy can_delete_dead_exceptions.

Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/tree-inline.c


^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug middle-end/53590] compiler fails to generate SIMD instruction for FP division
  2012-06-06 13:14 [Bug ada/53590] New: new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function bauhaus at futureapps dot de
                   ` (12 preceding siblings ...)
  2012-06-16 11:06 ` ebotcazou at gcc dot gnu.org
@ 2014-07-10 10:39 ` ebotcazou at gcc dot gnu.org
  2014-07-10 10:41 ` ebotcazou at gcc dot gnu.org
  14 siblings, 0 replies; 16+ messages in thread
From: ebotcazou at gcc dot gnu.org @ 2014-07-10 10:39 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=53590

--- Comment #13 from Eric Botcazou <ebotcazou at gcc dot gnu.org> ---
Author: ebotcazou
Date: Thu Jul 10 10:38:30 2014
New Revision: 212424

URL: https://gcc.gnu.org/viewcvs?rev=212424&root=gcc&view=rev
Log:
    PR middle-end/53590
    * function.c (allocate_struct_function): Revert r188667 change.

    * gimple-low.c (lower_builtin_setjmp): Use properly-typed constant.

Added:
    trunk/gcc/testsuite/gnat.dg/opt39.adb
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/function.c
    trunk/gcc/gimple-low.c
    trunk/gcc/testsuite/ChangeLog


^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug middle-end/53590] compiler fails to generate SIMD instruction for FP division
  2012-06-06 13:14 [Bug ada/53590] New: new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function bauhaus at futureapps dot de
                   ` (13 preceding siblings ...)
  2014-07-10 10:39 ` ebotcazou at gcc dot gnu.org
@ 2014-07-10 10:41 ` ebotcazou at gcc dot gnu.org
  14 siblings, 0 replies; 16+ messages in thread
From: ebotcazou at gcc dot gnu.org @ 2014-07-10 10:41 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=53590

--- Comment #14 from Eric Botcazou <ebotcazou at gcc dot gnu.org> ---
Author: ebotcazou
Date: Thu Jul 10 10:41:15 2014
New Revision: 212425

URL: https://gcc.gnu.org/viewcvs?rev=212425&root=gcc&view=rev
Log:
    PR middle-end/53590
    * function.c (allocate_struct_function): Revert r188667 change.

    * gimple-low.c (lower_builtin_setjmp): Use properly-typed constant.

Added:
    branches/gcc-4_9-branch/gcc/testsuite/gnat.dg/opt39.adb
      - copied unchanged from r212424, trunk/gcc/testsuite/gnat.dg/opt39.adb
Modified:
    branches/gcc-4_9-branch/gcc/ChangeLog
    branches/gcc-4_9-branch/gcc/function.c
    branches/gcc-4_9-branch/gcc/gimple-low.c
    branches/gcc-4_9-branch/gcc/testsuite/ChangeLog


^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2014-07-10 10:41 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-06-06 13:14 [Bug ada/53590] New: new compiler generates both SISD and SIMD instructions for parallel operations of a "pure" function bauhaus at futureapps dot de
2012-06-06 13:29 ` [Bug ada/53590] " bauhaus at futureapps dot de
2012-06-10  8:42 ` ebotcazou at gcc dot gnu.org
2012-06-11  9:53 ` rguenth at gcc dot gnu.org
2012-06-11 10:09 ` georggcc at googlemail dot com
2012-06-11 10:31 ` georggcc at googlemail dot com
2012-06-11 10:39 ` [Bug ada/53590] compiler fails to generate SIMD instruction for FP division ebotcazou at gcc dot gnu.org
2012-06-11 10:59 ` georggcc at googlemail dot com
2012-06-12 16:54 ` ebotcazou at gcc dot gnu.org
2012-06-13 17:12 ` [Bug middle-end/53590] " georggcc at googlemail dot com
2012-06-15  9:22 ` ebotcazou at gcc dot gnu.org
2012-06-15 10:00 ` ebotcazou at gcc dot gnu.org
2012-06-15 14:54 ` georggcc at googlemail dot com
2012-06-16 11:06 ` ebotcazou at gcc dot gnu.org
2014-07-10 10:39 ` ebotcazou at gcc dot gnu.org
2014-07-10 10:41 ` ebotcazou at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).