[LLVMdev] [llvm-commits] [llvm] r65296 - in /llvm/trunk: include/llvm/CodeGen/ lib/CodeGen/SelectionDAG/ lib/Target/CellSPU/ lib/Target/PowerPC/ lib/Target/X86/ test/CodeGen/X86/

Scott Michel scooter.phd at gmail.com
Mon Feb 23 18:42:51 PST 2009


On Mon, Feb 23, 2009 at 4:03 PM, Nate Begeman <natebegeman at me.com> wrote:

> I like the idea of a ShuffleVectorSDNode (moves things in the direction of
> a bijective ISD to SDNode mapping), but eliminating BuildVectorSDNode in its
> entirety doesn't deal with constant and variable vectors.
>
>
> LLVM has no variable shuffle instruction, so there's no variable vectors to
> deal with; moving the constants into the shuffle sdnode does address
> constant shuffles (which are all of them).  Variable shuffles would need to
> be represented as target nodes at present, and my work will not change that.
>

I think what you meant to say here is that LLVM doesn't deal with
variable-length vectors and it does not deal with non-constant masks. That's
not the same what I was proposing, which is (now) an argument for O-O
hygiene and creating constant vectors.

Somehow I managed to get the impression that Chris was proposing moving
constant vector formation, e.g., v4i32 <0, 1, 2, 3, 4>, into the
ShuffleVectorSDNode class. That seems really odd, but that's how I read his
four steps. Happy to be proven that this was a misperception.

It's really in constant vector formation that isConstantSplat() is actually
useful. I'm not sure how useful isContantSplat() will be when moved to a
shuffle vector SDNode class.


-scooter
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20090223/c7513557/attachment.html>


More information about the llvm-dev mailing list