llvm-6502/lib
Chris Lattner b48da39536 Remove the 3 HACK HACK HACKs I put in before, fixing them properly with
the new TLI that is available.

Implement support for handling out of range shifts.  This allows us to
compile this code (a 64-bit rotate):

unsigned long long f3(unsigned long long x) {
  return (x << 32) | (x >> (64-32));
}

into this:

f3:
        mov %EDX, DWORD PTR [%ESP + 4]
        mov %EAX, DWORD PTR [%ESP + 8]
        ret

GCC produces this:

$ gcc t.c -masm=intel -O3 -S -o - -fomit-frame-pointer
..
f3:
        push    %ebx
        mov     %ebx, DWORD PTR [%esp+12]
        mov     %ecx, DWORD PTR [%esp+8]
        mov     %eax, %ebx
        mov     %edx, %ecx
        pop     %ebx
        ret

The Simple ISEL produces (eww gross):

f3:
        sub %ESP, 4
        mov DWORD PTR [%ESP], %ESI
        mov %EDX, DWORD PTR [%ESP + 8]
        mov %ECX, DWORD PTR [%ESP + 12]
        mov %EAX, 0
        mov %ESI, 0
        or %EAX, %ECX
        or %EDX, %ESI
        mov %ESI, DWORD PTR [%ESP]
        add %ESP, 4
        ret


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@19780 91177308-0d34-0410-b5e6-96231b3b80d8
2005-01-23 04:39:44 +00:00
..
Analysis Silence VC++ warnings. 2005-01-12 04:51:37 +00:00
Archive Use binary mode for reading/writing bytecode files 2005-01-22 17:36:17 +00:00
AsmParser Silence VS warnings. 2005-01-08 20:07:03 +00:00
Bytecode Use binary mode for reading/writing bytecode files 2005-01-22 17:36:17 +00:00
CodeGen Remove the 3 HACK HACK HACKs I put in before, fixing them properly with 2005-01-23 04:39:44 +00:00
Debugger Correct the comments and file header. 2004-12-23 21:16:46 +00:00
ExecutionEngine If the interpreter tries to execute an external function, kill it. Of course 2005-01-21 19:59:37 +00:00
Linker Remove un-needed #includes. 2004-12-20 04:15:44 +00:00
Support Make DiffFilesWithTolerance take sys::Path's instead of std::strings 2005-01-23 03:31:02 +00:00
System Fix destroyDirectory bug 2005-01-22 16:28:33 +00:00
Target Build Alpha by default. 2005-01-23 04:34:46 +00:00
Transforms Handle comparisons of gep instructions that have different typed indices 2005-01-21 23:06:49 +00:00
VMCore Use binary mode for reading/writing bytecode files 2005-01-22 17:36:17 +00:00
Makefile Add the Linker library 2004-11-14 21:54:41 +00:00