[llvm-commits] PATCH: remove VICmp and VFCmp.
David Greene
dag at cray.com
Thu Jul 9 11:54:38 PDT 2009
On Thursday 09 July 2009 13:20, Chris Lattner wrote:
> > Storing an <8 x i1> to memory with the same layout as [8 x i1] -- as
> > 8 bytes -- has the nice property of being friendly to various LLVM
> > assumptions. Unfortunately, it's also highly artificial; existing
> > vector hardware I'm familiar with doesn't work that way, and it
> > seems unlikely that anyone ever would want it to. However, it might
> > be ok for LLVM to define <8 x i1> stores this way for consistency
> > and then tell everyone to avoid using them.
So what's the alternative? Bitcast to i8 and then store?
> If a specific piece of hardware has support for "vectors of bools" in
> some way, they will probably have intrinsics to load/store them in
> their own specific format.
But what would be the result type of these memory operations? Intrinsics
for load/store of vector masks is ok. In a previous message I thought you
had suggested that all masked vector operations be intrinsics. That's a
non-starter in the long run (it's fine for an initial working implementation).
If <N x i1> is defined to be bitpacked except when storing to memory, that
should be ok. Then we can use intrinsics to load/store vector masks and
have the resulting type of the load by <N x i1> which is natural.
Either that or we define a new bitvector type.
-Dave
More information about the llvm-commits
mailing list