[Bug middle-end/41770] New: graphite miscompiles 434.zeusmp of the SPEC 2k6

spop at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Tue Oct 20 18:55:00 GMT 2009


On the "test" data set, (not the "ref" data set) of 434.zeusmp
there is a miscompare when using -fgraphite-identity.
This failure appeared with my patch to handle reductions:

Rewrite reductions out of SSA.

2009-07-28  Sebastian Pop  <sebastian.pop@amd.com>
        * graphite-sese-to-poly.c (loop_entry_phi_arg): New.
        (remove_simple_copy_phi): New.
        (remove_invariant_phi): New.
        (simple_copy_phi_p): New.
        (reduction_phi_p): New.
        (gsi_for_ssa_name_def): New.
        (insert_out_of_ssa_copy): New.
        (insert_out_of_ssa_copy_on_edge): New.
        (create_zero_dim_array): New.
        (scalar_close_phi_node_p): New.
        (rewrite_close_phi_out_of_ssa): New.
        (rewrite_phi_out_of_ssa): New.
        (rewrite_reductions_out_of_ssa): New.
        (build_poly_scop): Call rewrite_reductions_out_of_ssa.

The kernel that is miscompiled looks like this:


      subroutine diverg ( isum, div, sumd )

      integer in, jn, kn
      parameter(in =           128+5
     &        , jn =           128+5
     &        , kn =           128+5)

      integer is, ie, js, je, ks, ke
      common /gridcomi/
     &   is, ie, js, je, ks, ke

       integer       i       , j       , k
       real*8  div     (  in,  jn,  kn)

       sumd = 0.0
       if (isum .eq. 1) then
         do 60 k=ks,ke
           do 50 j=js,je
             do 40 i=is,ie
               sumd = sumd + div(i,j,k)
40           continue
50         continue
60       continue
       endif
       return
       end


-- 
           Summary: graphite miscompiles 434.zeusmp of the SPEC 2k6
           Product: gcc
           Version: 4.5.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: middle-end
        AssignedTo: spop at gcc dot gnu dot org
        ReportedBy: spop at gcc dot gnu dot org


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



More information about the Gcc-bugs mailing list