search for: vreinterpret

Displaying 8 results from an estimated 8 matches for "vreinterpret".

Did you mean: reinterpret
2010 Sep 21
2
[LLVMdev] Vectors in structures
...ou want portable NEON code, you have to assume that your intrinsic arguments are compatible based on struct type compatibility, i.e., they have to match exactly, even down to signed vs. unsigned element types. This is a huge hassle. If you take code written for GCC, you typically end up inserting vreinterpret calls all over the place. This was such a problem for llvm-gcc that we had to implement an optional GCC-compatibility mode, and we're planning to do something similar for clang using overloaded intrinsics.
2010 Sep 22
0
[LLVMdev] Vectors in structures
Bob Wilson writes: > Right. The contents of the struct don't matter -- the spec is pretty > clear about that -- so llvm uses vector types instead of doubles, but > your spec definitely shows them being defined as structs. It _says_ they are defined as structs - but it doesn't show them in use, i.e. it doesn't show how a user of the NEON intrinsics is supposed to be able to
2010 Sep 28
0
[LLVMdev] Vectors in structures
...vector types and can be implicitly converted. It is not valid if those types are defined as structs, because C/C++ do not allow distinct struct types to be implicitly converted just because they happen to have the same size. To get this to compile when the NEON types are structs, you need to add vreinterpret intrinsics: #include <arm_neon.h> uint32x2_t test(int32x2_t x) { uint32x2_t ux = vreinterpret_u32_s32(x); return vadd_u32(ux, ux); } I do not have access to ARM's compiler(s) but I'm assuming that the first example will not compile because vadd_u32 expects arguments of type uint32x2...
2015 Jan 05
2
[LLVMdev] NEON intrinsics preventing redundant load optimization?
On 4 Jan 2015, at 21:06, Tim Northover <t.p.northover at gmail.com> wrote: >>> I’ve managed to replace the load/store intrinsics with pointer dereferences (along with a typedef to get the alignment correct). This generates 100% the same IR + asm as the auto-vectorized C version (both using -O3), and works with the toolchain in the latest XCode. Are there any concerns around doing
2010 Sep 28
2
[LLVMdev] Vectors in structures
On 27 September 2010 23:45, Bob Wilson <bob.wilson at apple.com> wrote: > An implementation, such as in GCC, that does not use structures is compatible with ARM's specification in only one direction.  GCC will accept any code written for RVCT, but not the other way around.  And, as Al pointed out, there are also compatibility issues with how you can initialize vectors.  (In fact, if
2010 Sep 21
0
[LLVMdev] Vectors in structures
On Tue, Sep 21, 2010 at 11:07 PM, Alasdair Grant <Alasdair.Grant at arm.com> wrote: > Bob Wilson writes: >> On Sep 21, 2010, at 9:33 AM, Renato Golin wrote: >> > I was checking NEON instructions this week and the vector types seem >> > to be inside structures. If vector types are considered proper types >> > in LLVM, why pack them inside structures?
2015 Jan 05
4
[LLVMdev] NEON intrinsics preventing redundant load optimization?
...r dereferences byteswaps the entire 128-bit number). While pointer dereference does work just as well (and better, given this defect) as VLD1 it is explicitly *not supported*. The ACLE mandates that there are only certain ways to legitimately "create" a vector object - vcreate, vcombine, vreinterpret and vload. NEON intrinsic types don't exist in memory (memory is modelled as a sequence of scalars, as in the C model). For this reason Renato I don't think we should advise people to work around the API, as who knows what problems that will cause later. The reason above is why we map a vl...
2010 Sep 21
3
[LLVMdev] Vectors in structures
Bob Wilson writes: > On Sep 21, 2010, at 9:33 AM, Renato Golin wrote: > > I was checking NEON instructions this week and the vector types seem > > to be inside structures. If vector types are considered proper types > > in LLVM, why pack them inside structures? > > Because that is what ARM has specified? They define the vector types > that are used with their NEON