[x86] Rearrange the code for v16i16 lowering a bit for clarity and to
authorChandler Carruth <chandlerc@gmail.com>
Thu, 25 Sep 2014 04:03:22 +0000 (04:03 +0000)
committerChandler Carruth <chandlerc@gmail.com>
Thu, 25 Sep 2014 04:03:22 +0000 (04:03 +0000)
commite5fb4ad1428bfaf6a8be09fad43c76c02719ebba
tree59a125e93f8680f441adab296d81dc43f4b07902
parente3bb4bb2d553003df7d069ee2504c7e9403aac57
[x86] Rearrange the code for v16i16 lowering a bit for clarity and to
reduce the amount of checking we do here.

The first realization is that only non-crossing cases between 128-bit
lanes are handled by almost the entire function. It makes more sense to
handle the crossing cases first.

THe second is that until we actually are going to generate fancy shared
lowering strategies that use the repeated semantics of the v8i16
lowering, we should waste time checking for repeated masks. It is
simplest to directly test for the entire unpck masks anyways, so we
gained nothing from this.

This also matches the structure of v32i8 more closely.

No functionality changed here.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@218441 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/X86/X86ISelLowering.cpp