fix a subtle bug I introduced in my refactoring, where we stopped preferring
authorChris Lattner <sabre@nondot.org>
Fri, 8 Oct 2010 05:12:14 +0000 (05:12 +0000)
committerChris Lattner <sabre@nondot.org>
Fri, 8 Oct 2010 05:12:14 +0000 (05:12 +0000)
commitd043529b348c48e63a80eead6e4e042a5d5a29a3
tree7391c3d68a9e8fd47fc427c7d7592552fc5aaa36
parent77c70084699d20001538d0d32c8e55e62977105b
fix a subtle bug I introduced in my refactoring, where we stopped preferring
the i8 versions of instructions in some cases.  In test6, we started
generating:

cmpq $0, -8(%rsp)            ## encoding: [0x48,0x81,0x7c,0x24,0xf8,0x00,0x00,0x00,0x00]
                                        ## <MCInst #478 CMP64mi32
                                        ##  <MCOperand Reg:114>
                                        ##  <MCOperand Imm:1>
                                        ##  <MCOperand Reg:0>
                                        ##  <MCOperand Imm:-8>
                                        ##  <MCOperand Reg:0>
                                        ##  <MCOperand Imm:0>>

instead of:

cmpq $0, -8(%rsp)            ## encoding: [0x48,0x83,0x7c,0x24,0xf8,0x00]
                                        ## <MCInst #479 CMP64mi8
                                        ##  <MCOperand Reg:114>
                                        ##  <MCOperand Imm:1>
                                        ##  <MCOperand Reg:0>
                                        ##  <MCOperand Imm:-8>
                                        ##  <MCOperand Reg:0>
                                        ##  <MCOperand Imm:0>>

Fix this and add some comments.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@116053 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/X86/X86InstrArithmetic.td