[X86][AVX] 256-bit vector stack unaligned load/stores identification
authorSimon Pilgrim <llvm-dev@redking.me.uk>
Tue, 18 Nov 2014 23:38:19 +0000 (23:38 +0000)
committerSimon Pilgrim <llvm-dev@redking.me.uk>
Tue, 18 Nov 2014 23:38:19 +0000 (23:38 +0000)
commit9c1e4123f8ecb5747448b8311ed66d8d7a207e0b
tree60a426d284d8bde6be593ab8a6e82902bd0577f8
parent49bfafb5108a463f3c46c11d91d92c5528770928
[X86][AVX] 256-bit vector stack unaligned load/stores identification

Under many circumstances the stack is not 32-byte aligned, resulting in the use of the vmovups/vmovupd/vmovdqu instructions when inserting ymm reloads/spills.

This minor patch adds these instructions to the isFrameLoadOpcode/isFrameStoreOpcode helpers so that they can be correctly identified and not be treated as folded reloads/spills.

This has also been noticed by http://llvm.org/bugs/show_bug.cgi?id=18846 where it was causing redundant spills - I've added a reduced test case at test/CodeGen/X86/pr18846.ll

Differential Revision: http://reviews.llvm.org/D6252

llvm-svn: 222281
llvm/lib/Target/X86/X86InstrInfo.cpp
llvm/test/CodeGen/X86/avx-intel-ocl.ll
llvm/test/CodeGen/X86/pr18846.ll [new file with mode: 0644]