the clang 3.5 loop optimizer seems to jump in unintentional for simple loops

the clang 3.5 loop optimizer seems to jump in unintentional for simple loops

the very simple example

Hi Dennis,

Can you please file a bug for this at http://llvm.org/bugs/ -- we should not be vectorizing this loop of length 3.

-Hal

It looks like it has vectorized the code which is usually good? I'm
actually surprised it failed to vectorize when using the integer indices.

Did you benchmark the performance?

Ahh, we lose track of the constant trip count. Yea, that's pretty terrible.

filed http://llvm.org/bugs/show_bug.cgi?id=20409