LLVM backend for 6502
Go to file
Chris Lattner 5a6bace3ab If a target zero or sign extends the result of its setcc, allow folding of
this into sign/zero extension instructions later.

On PPC, for example, this testcase:

%G = external global sbyte
implementation
void %test(int %X, int %Y) {
  %C = setlt int %X, %Y
  %D = cast bool %C to sbyte
  store sbyte %D, sbyte* %G
  ret void
}

Now codegens to:

        cmpw cr0, r3, r4
        li r3, 1
        li r4, 0
        blt .LBB_test_2 ;
.LBB_test_1:    ;
        or r3, r4, r4
.LBB_test_2:    ;
        addis r2, r2, ha16(L_G$non_lazy_ptr-"L00000$pb")
        lwz r2, lo16(L_G$non_lazy_ptr-"L00000$pb")(r2)
        stb r3, 0(r2)

instead of:

        cmpw cr0, r3, r4
        li r3, 1
        li r4, 0
        blt .LBB_test_2 ;
.LBB_test_1:    ;
        or r3, r4, r4
.LBB_test_2:    ;
***     rlwinm r3, r3, 0, 31, 31
        addis r2, r2, ha16(L_G$non_lazy_ptr-"L00000$pb")
        lwz r2, lo16(L_G$non_lazy_ptr-"L00000$pb")(r2)
        stb r3, 0(r2)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21148 91177308-0d34-0410-b5e6-96231b3b80d8
2005-04-07 19:43:53 +00:00
autoconf Recognize an IA64 when we see one 2005-03-17 20:56:22 +00:00
docs * Put command-line switches and function names in <tt> 2005-03-30 19:14:24 +00:00
examples add missing copyright header 2005-03-15 15:46:23 +00:00
include/llvm Allow targets which produce setcc results in non-MVT::i1 registers to describe 2005-04-07 19:41:18 +00:00
lib If a target zero or sign extends the result of its setcc, allow folding of 2005-04-07 19:43:53 +00:00
projects Rename createPromoteMemoryToRegister() to 2005-03-28 02:01:12 +00:00
runtime Fix grammar 2005-03-23 21:14:33 +00:00
test match case change in codegen 2005-04-07 17:47:00 +00:00
tools there is no reason to run -instcombine -instcombine! 2005-03-29 06:25:11 +00:00
utils spiff up the nightly tester output one more notch 2005-03-17 16:07:45 +00:00
win32 Do #include HashExtras.h with VC++ 2005-03-16 05:49:58 +00:00
.cvsignore Ignore the autom4te.cache directoy. 2004-12-24 15:11:23 +00:00
configure Recognize an IA64 when we see one 2005-03-17 20:56:22 +00:00
CREDITS.TXT Updating my entry. 2005-03-22 21:33:19 +00:00
LICENSE.TXT Another year, another copyright update. 2005-01-08 19:10:44 +00:00
llvm.spec
llvm.spec.in
Makefile Remove the check target. Its now in Makefile.rules 2004-12-06 05:35:00 +00:00
Makefile.common Update comments to reflect new variable names. Patch contributed by 2005-02-14 16:02:19 +00:00
Makefile.config.in For PR528: 2005-02-24 03:56:32 +00:00
Makefile.rules * Remove extraneous spaces 2005-03-11 04:15:18 +00:00
README.txt

Low Level Virtual Machine (LLVM)
================================

This directory and its subdirectories contain source code for the Low Level 
Virtual Machine, a toolkit for the construction of highly optimized compilers,
optimizers, and runtime environments. 

LLVM is open source software. You may freely distribute it under the terms of
the license agreement found in LICENSE.txt.

Please see the HTML documentation provided in docs/index.html for further
assistance with LLVM.