Displaying 2 results from an estimated 2 matches for "187072".
Did you mean:
137072
2013 Sep 07
0
[LLVMdev] Aliasing of volatile and non-volatile
Are you sure this is an alias problem?
What is happening is LLVM is leaving the code looking like this:
int foo(int *p, volatile int *q, int n) {
int i, s = 0;
for (i = 0; i < n; ++i)
s += *p + *q;
return s;
}
but GCC is changing to code to look like this:
int foo(int *p, volatile int *q, int n) {
int i, s = 0;
int t;
t = *p;
for (i = 0; i < n; ++i)
s += t + *q;
2013 Sep 04
6
[LLVMdev] Aliasing of volatile and non-volatile
A customer has reported a performance problem, which I have eventually
tracked down to the following situation:
Consider this program:
int foo(int *p, volatile int *q, int n) {
int i, s = 0;
for (i = 0; i < n; ++i)
s += *p + *q;
return s;
}
LLVM's analysis indicates that *p and *q can alias, even though *p is
non-volatile whereas *q is volatile. I don't have the