Skip to content

[QUESTION][struct_support] load struct #1893

Discussion options

You must be logged in to vote

Hi.

So - bad news - if you want it like this, it's not supported very well.

  1. The good option.

We recommend using SoA for simd.
If you can, use eve::algo::soa_vector
https://jfalcou.github.io/eve/structeve_1_1algo_1_1soa__vector.html#a1cfd01b1cec55dd3fab8e0c6809764f4
And then all the algorithms and everything will work.

  1. The bad option.

If you want to use std::vector<vec3> that's going to be quite slow.
We also don't have amazing support for it.

If you do the same operation for all of them - just cast to float*.
You can also do some masking, but since it's vec3 it won't be easy and you can't just use existing algorithm.

If you want to build wide<vec3> - you'd need to deinterleave the dat…

Replies: 1 comment 5 replies

Comment options

You must be logged in to vote
5 replies
@DenisYaroshevskiy
Comment options

@DramaDesu
Comment options

@jfalcou
Comment options

@DramaDesu
Comment options

@DramaDesu
Comment options

Answer selected by DramaDesu
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants