On Thu, Jun 12, 2014 at 12:00 AM, Tyler Nowicki <[email protected]> wrote:
>> So this pragma does not communicate extra information about safety of
>> the trasformation, compiler should still prove it as if the pragma was
>> absent?  (IOW, the user can apply this pragma to every loop, and it
>> will not result in incorrect code being produced; suboptimal --
>> certainly, but still correct.)
>
> Yes that is correct. Safety, specified with #pragma clang loop vectorize_safe 
> or similar, is still on the drawing board.

Please explcitly state in the docs that it is always safe to apply
this pragma and the compiler will ignore it if can not prove the
transformation to be safe.  This is critical for understanding how to
use the pragma.  LGTM with that.

Dmitri

-- 
main(i,j){for(i=2;;i++){for(j=2;j<i;j++){if(!(i%j)){j=0;break;}}if
(j){printf("%d\n",i);}}} /*Dmitri Gribenko <[email protected]>*/
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to