This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug tree-optimization/67326] [5/6 Regression] -ftree-loop-if-convert-stores does not vectorize conditional assignment (anymore)


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67326

vekumar at gcc dot gnu.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |vekumar at gcc dot gnu.org

--- Comment #2 from vekumar at gcc dot gnu.org ---
Hi Richard,

As a first step I am trying to allow if conversion to happen under
-ftree-loop-if-convert-stores for cases where we know it is already accessed
(read) outside unconditionally once and also the memory access is read and
write. 

 __attribute__((aligned(32))) float a[LEN]; void 
 test() { for (int i = 0; i < LEN; i++) {
    if (a[i] > (float)0.) { //<== Already read here unconditionally 
                 a[i] =3 ;  //<== if we now it is read and write memory access
we can allow if conversion.
} 

As you said the cases in PR we need to enhance if-conversion pass to do bounds
checking the array "a" accessing using values of i.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]