Fix a minor bug in previous checking
authorChris Lattner <sabre@nondot.org>
Tue, 6 Apr 2004 17:34:50 +0000 (17:34 +0000)
committerChris Lattner <sabre@nondot.org>
Tue, 6 Apr 2004 17:34:50 +0000 (17:34 +0000)
commit48c937e5c9808cc63d2cd04d823642d875c6bf0a
treebf8daa41d5ec17f148e59969c0f2d8e467566ee0
parentb04da8a3c6488fe396c6d61eec9980598b8c84ae
Fix a minor bug in previous checking
Enable folding of long seteq/setne comparisons into branches and select instructions
Implement unfolded long relational comparisons against a constants a bit more efficiently

Folding comparisons changes code that looks like this:
        mov %EAX, DWORD PTR [%ESP + 4]
        mov %EDX, DWORD PTR [%ESP + 8]
        mov %ECX, %EAX
        or %ECX, %EDX
        sete %CL
        test %CL, %CL
        je .LBB2 # PC rel: F

into code that looks like this:
        mov %EAX, DWORD PTR [%ESP + 4]
        mov %EDX, DWORD PTR [%ESP + 8]
        mov %ECX, %EAX
        or %ECX, %EDX
        jne .LBB2 # PC rel: F

This speeds up 186.crafty by 6% with llc-ls.

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