HomePhabricator

GlobalISel: Change representation of shuffle masks

Authored by arsenm on Aug 13 2019, 8:34 AM.

Description

GlobalISel: Change representation of shuffle masks

Currently shufflemasks get emitted as any other constant, and you end
up with a bunch of virtual registers of G_CONSTANT with a
G_BUILD_VECTOR. The AArch64 selector then asserts on anything that
doesn't fit this pattern. This isn't an ideal representation, and
should avoid legalization and have fewer opportunities for a
representational error.

Rather than invent a new shuffle mask operand type, similar to what
ShuffleVectorSDNode does, just track the original IR Constant mask
operand. I don't completely like the idea of adding another link to
the IR, but MIR is already quite dependent on IR constants already,
and this will allow sharing the shuffle mask utility functions with
the IR.

llvm-svn: 368704

Details

Committed
arsenmAug 13 2019, 8:34 AM
Parents
rG8a033a9e3fb9: [libc++] Always build with -fvisibility=hidden
Branches
Unknown
Tags
Unknown