https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61338
--- Comment #9 from Andrew Pinski ---
One way to solve this would be push the perm that covers the whole vector (that
is an 1-1/onto PERM) forward through binary ops.
That is PERM + PERM -> PERM (where c matches all elements of
the vector as th
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61338
Andrew Pinski changed:
What|Removed |Added
CC||bill.schmidt at fastmail dot
com
--- Co
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61338
Andrew Pinski changed:
What|Removed |Added
CC||kugan at gcc dot gnu.org
--- Comment #7
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61338
--- Comment #6 from Andrew Pinski ---
Just the simple:
```
void foo (int *__restrict A, int n) {
for (int i = n; i > 0; --i) {
A[i] += 1;
}
}
```
Produces the double PERM here.
>From PR 115819 .
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61338
Andrew Pinski changed:
What|Removed |Added
CC||juzhe.zhong at rivai dot ai
--- Comment
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61338
Andrew Pinski changed:
What|Removed |Added
CC||pinskia at gcc dot gnu.org
--- Comment #
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61338
--- Comment #3 from Marc Glisse ---
Possibly easier is the case of a reduction, where permutations are clearly
irrelevant.
int f(int*arr,int size){
int sum=0;
for(int i = 0; i < size; i++){
sum += arr[size-1-i];
}
return sum;
}
We s
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61338
Richard Biener changed:
What|Removed |Added
Keywords||missed-optimization
Status|
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61338
--- Comment #1 from vincenzo Innocente ---
if I write it "reverse"
void foo2() {
for (int i=511; i>=0; --i)
x[1023-i] += y[1023-i]*z[512-i];
}
its ok
__Z4foo2v:
LFB1:
leaq2048+_x(%rip), %rdx
xorl%eax, %eax
leaq4+_z(