https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79047
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |missed-optimization
Status|UNCONFIRMED |NEW
Last reconfirmed| |2017-01-10
Ever confirmed|0 |1
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
The difference is where the cleanup_point in the IR is located.
Working non template case:
if (ANNOTATE_EXPR <<<cleanup_point (size_t) x < Vector::count ((const
struct Vector *) r)>>, ivdep>) (void) 0; else goto <D.17225>;
vs
Non-Working template case:
if (<<cleanup_point ANNOTATE_EXPR <(size_t) x < VectorT<float>::count
((const struct VectorT *) r), ivdep>>>) (void) 0; else goto <D.17488>;
Confirmed.