summaryrefslogtreecommitdiff
path: root/tools/gccld
Commit message (Collapse)AuthorAge
* Move IsArchive, IsBytecode to FileUtilities. Fix up some method comments.Brian Gaeke2003-11-11
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9902 91177308-0d34-0410-b5e6-96231b3b80d8
* This version of Linker.cpp works a lot better, but it's a little messy. Sorry.Brian Gaeke2003-11-11
| | | | | | | | | Use FileOpenable() instead of FileExists(). Create IsBytecode() predicate -- like IsArchive(), but for bytecode files. Use IsBytecode() before trying to load any file as a bytecode file. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9893 91177308-0d34-0410-b5e6-96231b3b80d8
* Give gccld more gutsChris Lattner2003-11-09
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9835 91177308-0d34-0410-b5e6-96231b3b80d8
* Give this header file an Emacs mode-line.Brian Gaeke2003-11-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9749 91177308-0d34-0410-b5e6-96231b3b80d8
* Do not assume the first file is a bytecode file. Instead, construct a dummyBrian Gaeke2003-11-05
| | | | | | | | | Module and link things into that. Also, fix a typo in an error message. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9748 91177308-0d34-0410-b5e6-96231b3b80d8
* Shorten and correct some function-header comments.Brian Gaeke2003-11-05
| | | | | | | | | | | | | | | Make "verbose" output MUCH nicer. Now it tells you when you are linking a bytecode file, or an archive, and whether it's because you called it by name, or because you gave it a -l option, and it says "Trying" before it takes action and prints a message in the past tense afterwards. Make LinkFiles not skip the first file in Files. Make LinkFiles warn you if it can't find a file and LLVM_LIB_SEARCH_PATH is unset. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9747 91177308-0d34-0410-b5e6-96231b3b80d8
* Make -r work, fixing PR 91Chris Lattner2003-11-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9724 91177308-0d34-0410-b5e6-96231b3b80d8
* If linking a library, do not link other libraries, like libc, into it!Chris Lattner2003-11-03
| | | | | | | This fixes lots of annoying warnings and error messages git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9677 91177308-0d34-0410-b5e6-96231b3b80d8
* lli -q is history. Rebuild your gccld shell scripts, folks!Brian Gaeke2003-10-24
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9494 91177308-0d34-0410-b5e6-96231b3b80d8
* Turn on the inliner by default at link-timeChris Lattner2003-10-24
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9477 91177308-0d34-0410-b5e6-96231b3b80d8
* Turn on the IPCP pass by default. It has passed all of the testsChris Lattner2003-10-23
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9435 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix off-by-one error in processing of libraries named on command line.Brian Gaeke2003-10-21
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9351 91177308-0d34-0410-b5e6-96231b3b80d8
* Added LLVM copyright to Makefiles.John Criswell2003-10-20
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9314 91177308-0d34-0410-b5e6-96231b3b80d8
* fix file headerChris Lattner2003-10-20
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9294 91177308-0d34-0410-b5e6-96231b3b80d8
* Added copyright header to all C++ source files.John Criswell2003-10-20
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9291 91177308-0d34-0410-b5e6-96231b3b80d8
* Don't include "Config/stdlib.h".Brian Gaeke2003-10-10
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9037 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix spelling.Misha Brukman2003-10-10
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9027 91177308-0d34-0410-b5e6-96231b3b80d8
* Make more error messages have gccld's name in them.Brian Gaeke2003-10-08
| | | | | | | Add a newline after "Cannot find <library>". git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8968 91177308-0d34-0410-b5e6-96231b3b80d8
* Doxygen-ified comments.Misha Brukman2003-09-30
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8778 91177308-0d34-0410-b5e6-96231b3b80d8
* * Ordered includes according to LLVM styleMisha Brukman2003-09-30
| | | | | | | | | | * Put function signatures on one line if possible * Deleted empty comment lines (^//$) * Deleted braces around single statements * Deleted space between function call and argument list git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8775 91177308-0d34-0410-b5e6-96231b3b80d8
* Made code more terse:Misha Brukman2003-09-30
| | | | | | | | * Deleted empty comment lines * No single begin-braces '{' on a line by themselves git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8773 91177308-0d34-0410-b5e6-96231b3b80d8
* Doxygen-ified function comments.Misha Brukman2003-09-30
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8771 91177308-0d34-0410-b5e6-96231b3b80d8
* Removed extra space in comments.Misha Brukman2003-09-30
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8770 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove initials from source fileChris Lattner2003-09-30
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8769 91177308-0d34-0410-b5e6-96231b3b80d8
* Make code more terse:Misha Brukman2003-09-30
| | | | | | | | | * Remove extra blank lines * Delete space between function call and arg list * Delete non-content comment lines ("//") git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8768 91177308-0d34-0410-b5e6-96231b3b80d8
* 1. Use better error messages in LinkFiles().Brian Gaeke2003-09-30
| | | | | | | | | 2. I think the caller of LinkFiles() should not ignore a true return value. (If you have a good reason why it ought to, feel free to revert this. It's just something that's been bugging me for a while.) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8760 91177308-0d34-0410-b5e6-96231b3b80d8
* Update file headers for renamed files.Chris Lattner2003-09-30
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8758 91177308-0d34-0410-b5e6-96231b3b80d8
* Tersified code:Misha Brukman2003-09-29
| | | | | | | | | * Removed space between function name and its argument list * Removed space between '&' and variable name * Removed empty comment lines: `//' git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8750 91177308-0d34-0410-b5e6-96231b3b80d8
* * Ordered includes according to LLVM programmers' guideMisha Brukman2003-09-29
| | | | | | | | * Made code layout more verbose: no more '{' on a line by itself * Pruned extra whitespace git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8748 91177308-0d34-0410-b5e6-96231b3b80d8
* Minor cleanups:Chris Lattner2003-09-22
| | | | | | | | | | | | * Local header file goes at top * Remove unneeded #includes * Wrap code at 80 columns * Declare variables where they are used * 'register' is not needed * Use 'unsigned' instead of 'int' variables where possible git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8657 91177308-0d34-0410-b5e6-96231b3b80d8
* New header file for gccld.John Criswell2003-09-19
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8610 91177308-0d34-0410-b5e6-96231b3b80d8
* Removed linking functionality from gccld.cpp and moved it to linker.cpp.John Criswell2003-09-19
| | | | | | | | | | | | | | Renamed functions that were all lower-case. Moved functions from util.cpp into linker.cpp or gccld.cpp. Removed util.h and created gccld.h. Refactored the linker functionality in linker.cpp so that it is easier to follow, easier to modify, and it's library/object file search behavior is easier to understand and document. Added code to include library paths when doing native linking, but this causes problems and is currently #ifdef'd out. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8609 91177308-0d34-0410-b5e6-96231b3b80d8
* Refactored gccld into three C++ source files.John Criswell2003-09-18
| | | | | | | | Added code ignore bytecode link failures when generating native code. Moved native code and bytecode generation out of the main() function. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8595 91177308-0d34-0410-b5e6-96231b3b80d8
* Replaced the call to strdup() with a new operator followed by a strcpy().John Criswell2003-09-17
| | | | | | | This should prevent calls to the new oerator and malloc. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8587 91177308-0d34-0410-b5e6-96231b3b80d8
* Added the use of the const keyword.John Criswell2003-09-17
| | | | | | | Have gccld find the path to llc and gcc instead of having the library do it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8586 91177308-0d34-0410-b5e6-96231b3b80d8
* Removed the use of the environ variable and instead use the environment arrayJohn Criswell2003-09-17
| | | | | | | | | | | | | | passed into main(). This may (or may not) be more portable, but it looks nicer. Added functions to copy the environment array and modify the copy, thus preserving the environment. Switched from using system() to using ExecWait(). The code now removes the assembly file generated when using the -native option. Fixed the remove_env() function: The previous revision truncated the environment variable list. This version just zaps the variable as intended. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8579 91177308-0d34-0410-b5e6-96231b3b80d8
* Added the -native option.John Criswell2003-09-16
| | | | | | | | | With this option, gccld links the program into LLVM bytecode and a native code binary. This allows llvmgcc to correctly tell GNU configure scripts when things aren't defined properly (because the native link will fail). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8570 91177308-0d34-0410-b5e6-96231b3b80d8
* -abort-on-exception is gone. Rebuild your gccld shell scripts, folks! :-)Brian Gaeke2003-09-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8368 91177308-0d34-0410-b5e6-96231b3b80d8
* Added code that makes the bytecode file readable (needed by the generated shellJohn Criswell2003-09-02
| | | | | | | | | | | script). Removed the use of sys/types.h and sys/stat.h. Modified FileExists() so that it uses the access() system call to check for file existance. This requires less header files and might even be a tad bit faster. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8328 91177308-0d34-0410-b5e6-96231b3b80d8
* Modified the code so that it uses the MakeFileExecutable() method. The newJohn Criswell2003-09-02
| | | | | | | | library code now adds all execute bits that are allowed by the umask value to the file's current permission bits. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8325 91177308-0d34-0410-b5e6-96231b3b80d8
* "Help keep our secrets secret."John Criswell2003-08-29
| | | | | | | | Added code to respect the umask value. Before, files were generated world readable, which may not be desirable for all installations. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8215 91177308-0d34-0410-b5e6-96231b3b80d8
* add preliminary support for -export-dynamicChris Lattner2003-08-22
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8058 91177308-0d34-0410-b5e6-96231b3b80d8
* Make the bytecode file executable as well for LLEE purposes.Misha Brukman2003-08-20
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7992 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert my last (accidental) checkin, but keep the typeo fixChris Lattner2003-08-15
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7879 91177308-0d34-0410-b5e6-96231b3b80d8
* rename selection library to selectiondagChris Lattner2003-08-15
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7878 91177308-0d34-0410-b5e6-96231b3b80d8
* Run the simplify CFG pass after instcombine which has the effect of deletingChris Lattner2003-06-26
| | | | | | | ALL of the global ctor/dtor stuff if it is not used! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6916 91177308-0d34-0410-b5e6-96231b3b80d8
* Move the instcombine pass before globaldce, so that if globals are made dead ↵Chris Lattner2003-06-26
| | | | | | by instcombine, that they can be deleted. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6910 91177308-0d34-0410-b5e6-96231b3b80d8
* Funcresolve no longer performs nicification of resolved functionsChris Lattner2003-06-19
| | | | | | | instcombine does this git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6787 91177308-0d34-0410-b5e6-96231b3b80d8
* Add new DAE pass to gccld. It does not add cause any regressions in the ↵Chris Lattner2003-06-18
| | | | | | test-suite git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6770 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix formatting in fileChris Lattner2003-05-29
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6398 91177308-0d34-0410-b5e6-96231b3b80d8