[LLVMdev] Vectorization of loops with conditional dereferencing

Nadav Rotem nrotem at apple.com
Thu Nov 14 11:10:12 PST 2013


Its a good point.  We will need to document the semantics of the vectorization pragma well. 

On Nov 14, 2013, at 10:58 AM, Ralf Karrenberg <Chareos at gmx.de> wrote:

> Hi Nadav,
> 
> On 14/11/13 17:38, Nadav Rotem wrote:
>> Sure.  Vectorization of stores is done by loading the current value from memory, blending the new value and saving it back to memory.
> 
> Just a side note: You may run into trouble with this approach when people start using the loop vectorizer in combination with multi threading. The load/blend/store scheme introduces a race condition in this scenario.
> I don't know if this is a valid use case for you, but it may be worth keeping in mind.
> 
> Cheers,
> Ralf




More information about the llvm-dev mailing list