Commit Graph

15930 Commits

Author SHA1 Message Date
Chris Lattner
38f1455393 Add method
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18368 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-30 02:51:53 +00:00
Chris Lattner
8cca1a7cbc New testcase for simplifycfg
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18367 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-30 00:31:16 +00:00
Chris Lattner
37dc938bbe If we have something like this:
if (x) {
    code
    ...
  } else {
    code
    ...
  }

Turn it into:

  code
  if (x) {
    ...
  } else {
    ...
  }

This reduces code size and in some common cases allows us to completely
eliminate the conditional.  This turns several if/then/else blocks in loops
into straightline code in 179.art, turning the loops into single basic blocks
(good for modsched even!).

Maybe now brg will leave me alone ;-)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18366 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-30 00:29:14 +00:00
Chris Lattner
ee8c9ad8d2 Remove extraneous namespacification. In particular, don't define llvm::llvm::createInternalGlobalMapperPass
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18365 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-30 00:22:59 +00:00
John Criswell
6e35eda519 Fix a typo.
Corrected a potential grammary issue.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18364 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 21:46:29 +00:00
Chris Lattner
8a9193927a Allow hoisting loads of globals and alloca's in conditionals.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18363 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 21:26:12 +00:00
Chris Lattner
478b3b42e2 Make built bytecode libraries depend on gccas/gccld as appropriate. This
should fix the stale runtime libraries problem.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18361 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 19:47:58 +00:00
Reid Spencer
5507eabec5 Fix two bugs:
1. Nothing should happen on "make all". Doc generation is quick, but we
   don't want to do it unless we're installing.
2. Correct a dependency for the *.ps files .. didn't notice this before
   because of cruft in my directory. It failed on a clean build.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18359 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 14:46:29 +00:00
Reid Spencer
e934219e77 Functionality moved to portable lib/System/DynamicLibrary.cpp
implementation


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18358 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 14:11:41 +00:00
Reid Spencer
df5a37efc9 Use System/DynamicLibrary instead of Support/DynamicLinker
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18357 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 14:11:29 +00:00
Reid Spencer
737459df79 Use System/DynamicLibrary instead of Support/DynamicLinker to implement.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18356 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 14:07:46 +00:00
Reid Spencer
19cd4a9e6b Implement two new functions: LoadLibraryPermanently and
SearchForAddressOfSymbol.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18355 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 13:33:28 +00:00
Reid Spencer
b0b0ea07bb Add in some methods for use by the JIT. LoadLibraryPermanently brings the
library into the address space permanently. SearchForAddressOfSymbol looks
in all previously permanently loaded libraries and any currently open
libraries for a symbol, instead of just one library like GetAddressOfSymbol


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18354 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 13:27:56 +00:00
Reid Spencer
a564845f83 Shared library extension is now in LTDL_SHLIB_EXT
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18353 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 12:40:21 +00:00
Reid Spencer
29ae1777c1 We just use ltdl's implementation for this abstraction now. Its portable to
more platforms than LLVM supports.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18352 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 12:39:10 +00:00
Reid Spencer
7d277000af Allow reconfig from any directory, not just the top build directory, by
changing directory first. Also make sure that we don't attempt to run
config.status if the recheck didn't work.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18351 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 12:37:44 +00:00
Reid Spencer
8c8af327b8 Changes resulting from AC_LIB_LTDL usage.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18350 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 12:36:16 +00:00
Reid Spencer
2bc7bd5c88 * Implement embedding libltdl into LLVM which required some rearranging.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18349 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 12:29:58 +00:00
Reid Spencer
8baa775d00 * Update instructions about upgrading libtool
* Add instructions about upgrading autoconf


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18348 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 12:28:47 +00:00
Reid Spencer
6ab9b4cb1d Don't include ltdl.h any more. Its nested in lib/System now.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18347 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 12:12:11 +00:00
Reid Spencer
58c8ee1537 Mods for compilation with llvm.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18346 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 12:04:27 +00:00
Reid Spencer
9c16ed5aea Original version of ltdl.h from libtool 1.5.10
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18345 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 12:02:48 +00:00
Reid Spencer
535af2be27 Original version of ltdl.c from libtool 1.5.10
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18344 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 12:02:25 +00:00
Reid Spencer
5252d95695 Converted with autoupdate for autoconf 2.50 -> 2.59 differences.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18343 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 11:27:12 +00:00
Reid Spencer
2197262119 This file contains macros that allow us to incorporate the ltdl source into
our own library so that it is magically hidden and we don't have to depend
on linking with -lltdl option.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18342 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 10:56:45 +00:00
Reid Spencer
441cc2ab01 Implement the default constructor which causes the current program to be
opened as if it was a dynamic library so its symbols can be searched too.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18341 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 10:39:46 +00:00
Reid Spencer
7a9369065d Make the default constructor cause the program's symbols to be loaded as
if it was a dynamic library.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18340 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 10:38:54 +00:00
Reid Spencer
6f14a5b486 Make it HTML 4.01 Strict compliant.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18339 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 07:47:16 +00:00
Reid Spencer
31ce7fb6e1 * Document how to turn on doxygen documentation generation
* Document the new "LLVMLIBS=JIT" feature to make building JIT programs
  super easy.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18338 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 07:44:51 +00:00
Reid Spencer
aadc41860d No longer necessary, moved Makefile.rules
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18337 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 07:17:31 +00:00
Reid Spencer
8f631784f7 Use LLVMLIBS=JIT to get JIT libraries
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18333 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 07:17:18 +00:00
Reid Spencer
7c787c9355 Incorporate tools/Makefile.JIT
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18332 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 07:17:07 +00:00
Reid Spencer
f00b54058b Make sure the program's symbols can be dlsym'd as well.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18331 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 06:23:19 +00:00
Chris Lattner
928b47ae2e Revamp long/ulong comparisons to use a much more efficient sequence (thanks
to Brian and the Sun compiler for pointing out that the obvious works :)

This also enables folding all long comparisons into setcc and branch
instructions: before we could only do == and !=

For example, for:
void test(unsigned long long A, unsigned long long B) {
   if (A < B) foo();
 }

We now generate:

test:
        subl $4, %esp
        movl %esi, (%esp)
        movl 8(%esp), %eax
        movl 12(%esp), %ecx
        movl 16(%esp), %edx
        movl 20(%esp), %esi
        subl %edx, %eax
        sbbl %esi, %ecx
        jae .LBBtest_2  # UnifiedReturnBlock
.LBBtest_1:     # then
        call foo
        movl (%esp), %esi
        addl $4, %esp
        ret
.LBBtest_2:     # UnifiedReturnBlock
        movl (%esp), %esi
        addl $4, %esp
        ret

Instead of:

test:
        subl $12, %esp
        movl %esi, 8(%esp)
        movl %ebx, 4(%esp)
        movl 16(%esp), %eax
        movl 20(%esp), %ecx
        movl 24(%esp), %edx
        movl 28(%esp), %esi
        cmpl %edx, %eax
        setb %al
        cmpl %esi, %ecx
        setb %bl
        cmove %ax, %bx
        testb %bl, %bl
        je .LBBtest_2   # UnifiedReturnBlock
.LBBtest_1:     # then
        call foo
        movl 4(%esp), %ebx
        movl 8(%esp), %esi
        addl $12, %esp
        ret
.LBBtest_2:     # UnifiedReturnBlock
        movl 4(%esp), %ebx
        movl 8(%esp), %esi
        addl $12, %esp
        ret


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18330 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 05:55:24 +00:00
Reid Spencer
fbbf307b15 * Allow date command to be printed in verbose mode
* Get rid of appending -lbz2 and -lz to ExtraLibs now that we don't need
  them any more.
* Fix the dist-check target so that EXTRA_DIST can be defined AFTER the
  include of Makefile.common. This is needed because Makefile.common
  provides variable definitions that may need to be used in computing the
  value of EXTRA_DIST.
* Clean up some "distdir" target output.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18329 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 05:00:33 +00:00
Reid Spencer
513b9213fd Add "docs" as a descendable directory (at the end)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18328 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 04:57:55 +00:00
Reid Spencer
1f31942b12 * allow doxygen documentation to be enabled/disabled (default off)
* organize programs we test for properly
* add new programs needed for documentation generation
* Adjust install paths so llvm stuff doesn't muck up /usr/local or /usr if
  $prefix is set to those.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18327 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 04:56:35 +00:00
Reid Spencer
e1200219ec * Get additional configured values into the makefiles
* Provide support for ENABLE_DOXYGEN
* New tools that documentation generation requires


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18326 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 04:53:50 +00:00
Reid Spencer
1a3ba7f10e Make the check a little quieter.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18325 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 04:51:58 +00:00
Reid Spencer
ca5fc7bf63 * Make this makefile compliant with LLVM makefile standards
* Implement optional doxygen doc generation
* Implement HTML and doxygen installation


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18324 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 04:47:35 +00:00
Reid Spencer
ebafced04e Moved --> doxygen.cfg.in
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18323 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 04:46:12 +00:00
Tanya Lattner
58fe2f0734 Reworked branching so we don't handle BAs specially. It just updates the branchTO regardless of what type of branch it is.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18322 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 04:39:47 +00:00
Reid Spencer
3c54b6cc73 * Get rid of extraneous directories
* Ensure things installed to same place are all getting there by using a
  variable to name that place.
* Make sure missing index.html, images and *.css files get installed.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18321 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 04:34:05 +00:00
Reid Spencer
38f98b52a6 * add llvmc and llvm-ld
* fix the links to not be in an html subdir as that's not how this gets
  installed (anymore).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18320 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 04:32:37 +00:00
Reid Spencer
e53b5c10e3 Adjust this so that doxygen doesn't barf on it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18319 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 03:47:37 +00:00
Reid Spencer
52d7a75c16 * Adjust so this falls in line with LLVM Makefile standards.
* Implement installation of doxygen and html documentation
* Fix it so it works with objdir != srcdir.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18318 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 03:45:02 +00:00
Reid Spencer
f8d3e4a07a * Fix an item list.
* Add an ENVIRONMENT section to describe LLVM_LIB_SEARCH_PATH


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18317 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 03:43:29 +00:00
Reid Spencer
ede0ae0ed8 Add a link.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18316 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 03:37:54 +00:00
Reid Spencer
22e4cdedb6 For PR393:
This file was originally doxygen.cfg, but it needs to be configured to get
the right srcdir/objdir paths for things. This is needed because building
the doxygen will now be part of the install and dist-check targets.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18315 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-29 03:33:22 +00:00
Tanya Lattner
28e5eabf65 Fixed bug where instructions in the kernel were not ordered right to preserve dependencies in a cycle.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18314 91177308-0d34-0410-b5e6-96231b3b80d8
2004-11-28 23:36:15 +00:00