-
Question as in title: I have two options to implement a piece of code. Initially, I started by writing a version of my code with a single replicate, with a However, I'm wondering if it would be a better idea to apply What's the code generation look like for these two variants? Is one always better than the other? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
If I understand your question correctly, I think you'll find that the two approaches will be effectively equivalent. A |
Beta Was this translation helpful? Give feedback.
If I understand your question correctly, I think you'll find that the two approaches will be effectively equivalent. A
vmap
of awhile_loop
essentially creates awhile_loop
that doesn't terminate until all mapped loops terminate. So whether you do that automatically viavmap
ofwhile_loop
or manually viawhile_loop
ofvmap
you'll probably see broadly the same performance.