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

--- Comment #3 from vries at gcc dot gnu.org ---
Created attachment 35221
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=35221&action=edit
patch for autopar-1.exe

For autopar-1.c, the original loop has a loop phi:

  # s.5_20 = PHI <s.5_12(4), 0.0(20)>

After expand_omp_for_static_chunk, there's an inner and an outer loop. The
outer loop phi is:

  # s.5_11 = PHI <0.0(15), s.5_12(21)>

and the inner loop phi is:

  # s.5_20 = PHI <s.5_12(4), 0.0(20)>

The inner loop phi should not have 0.0 as argument, but the result of the outer
loop phi:

  # s.5_20 = PHI <s.5_12(4), s.5_11(20)>


This patch fixes the inner loop phi, and autopar-1.exe passes.

Reply via email to