https://llvm.org/bugs/show_bug.cgi?id=27013

            Bug ID: 27013
           Summary: Delinearization fails and produces invariant access
                    function for variant access
           Product: Polly
           Version: unspecified
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: Other
          Assignee: polly-...@googlegroups.com
          Reporter: doerf...@cs.uni-saarland.de
                CC: llvm-bugs@lists.llvm.org
    Classification: Unclassified

Created attachment 16064
  --> https://llvm.org/bugs/attachment.cgi?id=16064&action=edit
IR testcase

For the C code:

for (MCUindex = 0; MCUindex < MCUs_across; MCUindex++) { 
  lastDC = lastblockrow[h_samp_factor - 1][0]; 
  for (bi = 0; bi < h_samp_factor; bi++) { 
    thisblockrow[bi][0] = lastDC;
  } 
  thisblockrow += h_samp_factor; /* advance to next MCU in row */ 
  lastblockrow += h_samp_factor; 
} 

in

  MultiSource/Benchmarks/mediabench/jpeg/jpeg-6a/jccoefct.c

we generate variant multidimensional accesses even though there are none.
This causes us to hoist "lastblockrow[h_samp_factor - 1][0]", thus
mis-compiling the code. The problem seems to be the PHI nodes that change the
pointers for "thisblockrow" and "lastblockrow" break some delinarization
process.

NOTE: You need to allow unsigned comparisons (or change the unsigned comparison
in the code)!

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to