[X86] Fix a bug in getMemOpBaseRegImmOfs
authorSanjoy Das <sanjoy@playingwithpointers.com>
Tue, 2 Feb 2016 02:32:43 +0000 (02:32 +0000)
committerSanjoy Das <sanjoy@playingwithpointers.com>
Tue, 2 Feb 2016 02:32:43 +0000 (02:32 +0000)
commit881de4d12acc3afc3973adb2701c4f5a213e8fb9
tree253ba5eb509164bf7f6a2f480122360857b38e7b
parent5cbf5d207a93db4ba492d0999c2d2b1278669c57
[X86] Fix a bug in getMemOpBaseRegImmOfs

Fix a crash in `getMemOpBaseRegImmOfs` that happens if the base of
`MemOp` is a frame index memory operand.  The fix is to have
`getMemOpBaseRegImmOfs` bail out in such cases.  We can possibly be more
clever here, if needed.

llvm-svn: 259456
llvm/lib/Target/X86/X86InstrInfo.cpp
llvm/test/CodeGen/X86/machine-sink-and-implicit-null-checks.ll