Displaying 1 result from an estimated 1 matches for "n_numbers".
2014 Jul 03
5
[LLVMdev] Global constructors "get lost" when transforming bitcode files
...here this could come from would be much appreciated!
Jonas
testcase:
cat >sum.c <<EOF
#include <stdio.h>
#include <assert.h>
int main() {
const int MAX_SIZE = 100;
int a[MAX_SIZE];
for (int i = 0; i < MAX_SIZE; ++i) {
a[i] = i * i + 4;
}
int n_numbers;
printf("How many numbers should I sum up? ");
scanf("%d", &n_numbers);
int sum = 0;
for (int i = 0; i < n_numbers; ++i) {
sum += a[i];
}
assert(sum >= 0);
printf("The sum is: %d\n", sum);
return 0;
}
EOF
set -ex
rm...