This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug tree-optimization/58526] New: Inlining looses restrict qualifier and leads to loop versioned vectorization


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

            Bug ID: 58526
           Summary: Inlining looses restrict qualifier and leads to loop
                    versioned vectorization
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Keywords: missed-optimization
          Severity: normal
          Priority: P3
         Component: tree-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: burnus at gcc dot gnu.org

Created attachment 30892
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=30892&action=edit
C++ test case

The attached test case vectorizes without loop versioning when compiled with
-fno-inline.

Expected: Also with inlining, the restrict qualifier survives and is used in
alias analysis - such that no loop versioning is done. (That's also what one
gets with Intel's icpc 13.1.1.)

g++ -march=native -funroll-loops -fno-rtti -fno-exceptions -Ofast -std=c++11 -S
-fopt-info-optall-optimized  test3.cc

test3.cc:16:3: note: loop vectorized
test3.cc:16:3: note: loop versioned for vectorization because of possible
aliasing
test3.cc:16:3: note: loop with 3 iterations completely unrolled
test3.cc:16:3: note: loop unrolled 7 times
test3.cc:17:34: note: loop unrolled 7 times


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]