Displaying 1 result from an estimated 1 matches for "fb128e6d".
2017 Aug 16
2
unable to emit vectorized code in LLVM IR
Hello,
I have written the following code. when i try to vectorize it through opt.
i am not getting vectorized instructions.
#include <stdio.h>
#include<stdlib.h>
int main(int argc, char** argv) {
int sum=0; int a=atoi(argv[1]); int b=atoi(argv[2]);
for (int i=0;i<1000;i++)
{
sum+=a+b;
}
printf("sum: %d\n", sum);
return 0;
}
i use following commands:
clang -S -emit-llvm