Vectorization of get<>

If you do something like:

#pragma simd 
    for (int i = 0; i < num_particles; i++) 
    {   
        Cabana::Index idx(array_size, v, o); 
        // Initialize position. 
        particles.get<PositionX>( idx ) = 1.1; 
        ...

You get indirect memory writes, because of a private addressing. The opt reports gives:

remark #15329: vectorization support: indirect store was emulated for the variable <&base->_data[offset][d]>, 64-bi t indexed, part of address is private [ ../src/Cabana_AoSoA.hpp(233,16) ]

We discussed a solution to this, which would involve caching the &base pointer

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information