Mirror of official llvm git repository located at http://llvm.org/git/llvm. Updated every five minutes.
Go to file
Chris Lattner fe9d82a71b Constant fold: getelementptr (i8* inttoptr (i64 1 to i8*), i32 -1)
Into: inttoptr (i64 0 to i8*)  -> null

This occurs in the example in PR1602.  With this fixed, we now compile
the example in PR1602 into fully "devirtualized" code:

define void @_Z1g1S(%struct.S* noalias  %s) {
entry:        %tmp131415 = getelementptr %struct.S* %s, i32 0, i32 0          ; <i32 (...)***> [#uses=1]        %tmp16 = load i32 (...)*** %tmp131415, align 4          ; <i32 (...)**> [#uses=1]
        %tmp26277 = load i32 (...)** %tmp16             ; <i32 (...)*> [#uses=1]
        %tmp2829 = bitcast i32 (...)* %tmp26277 to void (%struct.S*)*           ; <void (%struct.S*)*> [#uses=1]
        tail call void %tmp2829( %struct.S* %s )
        ret void
}

This still has the vtable dispatch (as required) but does not have any pointer
to method cruft left.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41046 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-13 17:09:08 +00:00
autoconf
docs Who thought up this crazy formatting scheme? 2007-08-07 17:57:36 +00:00
examples
include Change casts from old style to new style. This helps document the details 2007-08-12 08:12:35 +00:00
lib Constant fold: getelementptr (i8* inttoptr (i64 1 to i8*), i32 -1) 2007-08-13 17:09:08 +00:00
projects
runtime
test oops, forgot to commit this. 2007-08-12 16:55:14 +00:00
tools Don't build llvm-stub twice. 2007-08-13 00:25:47 +00:00
utils Make use of the llvm-ld tool's new ability to read input from stdin to extract 2007-08-13 06:19:51 +00:00
website
win32
Xcode
build-for-llvm-top.sh
configure
CREDITS.TXT Use subregs to improve any_extend code generation when feasible. 2007-08-10 22:22:41 +00:00
LICENSE.TXT
llvm.spec.in
Makefile
Makefile.common
Makefile.config.in
Makefile.rules
ModuleInfo.txt
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.