Commit Graph

472 Commits

Author SHA1 Message Date
Duncan Sands
47d9dcc584 Fix PR3117: not all nodes being legalized. The
essential problem was that the DAG can contain
random unused nodes which were never analyzed.
When remapping a value of a node being processed,
such a node may become used and need to be analyzed;
however due to operands being transformed during
analysis the node may morph into a different one.
Users of the morphing node need to be updated, and
this wasn't happening.  While there I added a bunch
of documentation and sanity checks, so I (or some
other poor soul) won't have to scratch their head
over this stuff so long trying to remember how it
was all supposed to work next time some obscure
problem pops up!  The extra sanity checking exposed
a few places where invariants weren't being preserved,
so those are fixed too.  Since some of the sanity
checking is expensive, I added a flag to turn it
on.  It is also turned on when building with
ENABLE_EXPENSIVE_CHECKS=1.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@60797 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-09 21:33:20 +00:00
Evan Cheng
027fdbe3ba Move target independent td files from lib/Target/ to include/llvm/Target so they can be distributed along with the header files.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@59953 91177308-0d34-0410-b5e6-96231b3b80d8
2008-11-24 07:34:46 +00:00
Anton Korobeynikov
569c45cab2 Proper way of doing llvm canadian-cross compilation.
Patch by Jim Grosbach!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@58981 91177308-0d34-0410-b5e6-96231b3b80d8
2008-11-10 07:33:13 +00:00
Daniel Dunbar
eb909ca524 Comment fix.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@58621 91177308-0d34-0410-b5e6-96231b3b80d8
2008-11-03 17:33:36 +00:00
Dan Gohman
63f97201dc Fun x86 encoding tricks: when adding an immediate value of 128,
use a SUB instruction instead of an ADD, because -128 can be
encoded in an 8-bit signed immediate field, while +128 can't be.
This avoids the need for a 32-bit immediate field in this case.

A similar optimization applies to 64-bit adds with 0x80000000,
with the 32-bit signed immediate field.

To support this, teach tablegen how to handle 64-bit constants.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@57663 91177308-0d34-0410-b5e6-96231b3b80d8
2008-10-17 01:33:43 +00:00
Daniel Dunbar
ebb9f9b76d Another dependency fix, prevent ObjDir from having trailing slash.
- It turns out this is enough to completely break dependency file
   (.d) usage (at least for my gmake).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@57030 91177308-0d34-0410-b5e6-96231b3b80d8
2008-10-03 21:24:52 +00:00
Daniel Dunbar
94e98af210 Add IS_CLEANING_TARGET Makefile variable.
- Fixes bug in dependency inclusions where make with unspecified
   target wouldn't include dependency files, eek!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@57026 91177308-0d34-0410-b5e6-96231b3b80d8
2008-10-03 19:11:19 +00:00
Jim Grosbach
673612ec72 Add support for Canadian Cross builds where the host executables are not
runnable on the build machine.

There are a few bits that need built for the build environment (TableGen).
This patch builds those bits, and the associated libraries, for the build
environment as well as the (usual) host environment.

Thanks to Eric C. and Devang P. for pre-commit review.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56975 91177308-0d34-0410-b5e6-96231b3b80d8
2008-10-02 22:56:44 +00:00
Daniel Dunbar
ecfe67c217 Reapply majority of r55557 but with the changes to compilation flags
disabled until issues with gcc 4.1 on linux 32-bit are resolved.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@55636 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-02 17:35:16 +00:00
Matthijs Kooijman
0783f0d0a3 Revert r55557, it is causing linking failures on 32bit linux.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@55628 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-02 09:51:00 +00:00
Daniel Dunbar
dcf114e861 Enable -fvisibility-inlines-hidden by default for compilers which
support it.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@55557 91177308-0d34-0410-b5e6-96231b3b80d8
2008-08-30 01:16:19 +00:00
Gabor Greif
5039a6f4f5 fix the output dumbness I have introduced some time ago
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@55506 91177308-0d34-0410-b5e6-96231b3b80d8
2008-08-28 22:32:39 +00:00
Dan Gohman
b0cf29c5cf Initial checkin of the new "fast" instruction selection support. See
the comments in FastISelEmitter.cpp for details on what this is.
This is currently experimental and unusable.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54751 91177308-0d34-0410-b5e6-96231b3b80d8
2008-08-13 20:19:35 +00:00
Chris Lattner
58a4c5e8e3 Add support for building on solaris, working around namespace
polution problems from system headers.  Patch by Nathan Keynes!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52682 91177308-0d34-0410-b5e6-96231b3b80d8
2008-06-24 17:44:42 +00:00
Evan Cheng
6fc5b48f64 Warn of potential violations of strict aliasing rules.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52027 91177308-0d34-0410-b5e6-96231b3b80d8
2008-06-05 23:00:08 +00:00
Evan Cheng
652f7ea955 Revert 51775.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@51795 91177308-0d34-0410-b5e6-96231b3b80d8
2008-05-30 22:47:19 +00:00
Evan Cheng
babf11f249 Patches for building llvm on Solaris x86. Contributed by Nathan Keynes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@51775 91177308-0d34-0410-b5e6-96231b3b80d8
2008-05-30 17:16:20 +00:00
Gabor Greif
b1dbcd886a Fix a bunch of 80col violations that arose from the Create API change. Tweak makefile targets to find these better.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@51143 91177308-0d34-0410-b5e6-96231b3b80d8
2008-05-15 10:04:30 +00:00
Gordon Henriksen
7252dc0efc Refresh Makefile.ocaml in objdir if it is modified in srcdir.
Patch by Erick Tryzelaar!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48149 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-10 15:58:40 +00:00
Gabor Greif
0a4c3782c8 Remove inappropriate whitespace, change CVS to SVN where it makes sense.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47671 91177308-0d34-0410-b5e6-96231b3b80d8
2008-02-27 13:34:15 +00:00
Andrew Lenharth
a7b33db5e9 when making bytecode modules, link as library
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47574 91177308-0d34-0410-b5e6-96231b3b80d8
2008-02-25 22:41:55 +00:00
Chris Lattner
f5c9467471 Make the check for GCC version more robust, fix shared library
dependencies in makefile, and fix llvm_cv_no_link_all_option
on darwin.

Patch by Shantonu Sen, more info here:
http://lists.cs.uiuc.edu/pipermail/llvmdev/2008-February/012410.html


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46760 91177308-0d34-0410-b5e6-96231b3b80d8
2008-02-05 19:43:40 +00:00
Duncan Sands
095765e26d Unbreak builds with differing object and source
directories.  Patch by Sam Bishop.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46453 91177308-0d34-0410-b5e6-96231b3b80d8
2008-01-28 17:38:30 +00:00
Chris Lattner
2671fc390c reduce duplicate -I flags passed to the compiler, cleaning up the VERBOSE
output.  Patch contributed by Sam Bishop!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46432 91177308-0d34-0410-b5e6-96231b3b80d8
2008-01-28 04:18:41 +00:00
Chris Lattner
05a3e8aa4d One too many )'s breaks 'make clean' with certain versions of make.
This fixes PR1927

This should be pulled into llvm 2.2.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46245 91177308-0d34-0410-b5e6-96231b3b80d8
2008-01-22 05:19:26 +00:00
Chris Lattner
6e0a529218 Commit a piece that I missed before, patch by Alain Frisch
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46032 91177308-0d34-0410-b5e6-96231b3b80d8
2008-01-15 23:27:40 +00:00
Gordon Henriksen
9e7aba2739 Modify Makefile.rules to allow makefiles to prepend to C.Flags and
fiends. Change Makefile.ocaml to not touch CFLAGS.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@45663 91177308-0d34-0410-b5e6-96231b3b80d8
2008-01-06 21:54:35 +00:00
Chris Lattner
e43ba3dce7 Factor out makefile dependency generation better.
Don't include system headers in the .d files.
Don't use $@ in the makefile rules, as there are two possible targets it could resolve to: use the one that we need explicitly.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@45473 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-31 23:58:31 +00:00
Chris Lattner
57360d1f1c remove attributions from the rest of the llvm makefiles.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@45416 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-29 20:11:13 +00:00
Chris Lattner
72e463369d noone uses etags. Connected to PR1601
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42344 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-26 06:10:47 +00:00
Reid Spencer
491a6cd8b4 Restore ability to build archives (oops)
Fix -include line so it doesn't reference /dev/null


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40429 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-23 08:20:46 +00:00
Reid Spencer
87b891911b Remove bizarre use of /dev/null in a makefile include line that
produces warning from make about bad timestamp on /dev/null

Patch by Holger Schurig.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40426 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-23 08:09:15 +00:00
Reid Spencer
eff155349a Make sure to keep symbols for profile build.
Patch by Benoit Boissinot. Thanks, Benoit!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@38490 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-10 14:52:01 +00:00
Reid Spencer
0a522b19e8 Make sure that preprocessor symbols like _DEBUG, NDEBUG, and _GLIBC_DEBUG are
put into the CPP.Defines variable. Seems the convention was corrupted with
various changes made. It is important to get command line parameters into the
right variable because things like llvm-config and sub-makefiles depend on it.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@38486 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-10 07:19:53 +00:00
Reid Spencer
1abd46d022 Add a missing .
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37800 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-29 14:02:07 +00:00
David Greene
cba291821d Clean up comments to be consistent with code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37798 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-29 03:36:21 +00:00
David Greene
a696d24ad2 Add support for building with _GLIBCXX_DEBUG. New configure option
--enable-expensive-checks allows the developer to enable runtime
checking that can greatly increase compile time.  Currently it only
turns on _GLIBCXX_DEBUG.  Other expensive debugging checks added later
should be controlled by this configure option.

This patch also updates llvm-config with a --cppflags option to inform
llvm-gcc how to build itself so that it is compatible with an llvm that
was built with _GLIBCXX_DEBUG.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37777 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-28 19:36:08 +00:00
Reid Spencer
413f2f961a Fix a problem with building .y files when BISON is not present.
Merged from the release_20 branch.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37188 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-17 22:51:35 +00:00
Reid Spencer
749a89bd53 Disable RTTI handling until we're ready.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36651 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-02 21:31:09 +00:00
Reid Spencer
6548bf1ced Add a rule to get the footprint of binaries and libraries.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36650 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-02 21:29:39 +00:00
Anton Korobeynikov
bed2946a96 Removed tabs everywhere except autogenerated & external files. Add make
target for tabs checking.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36146 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 18:10:23 +00:00
Chris Lattner
03840ac2e2 add a target to print out 80-column violations.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36032 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-14 23:35:45 +00:00
Reid Spencer
0522d8b124 Speed up installation a bit by ignoring .svn directories.
Patch by Scott Michel.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35826 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-09 19:08:58 +00:00
Reid Spencer
8475ec068c For PR789:
Make the sys::Path::getFileStatus function more efficient by having it
return a pointer to the FileStatus structure rather than copy it. Adjust
uses of the function accordingly. Also, fix some memory issues in sys::Path.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35476 91177308-0d34-0410-b5e6-96231b3b80d8
2007-03-29 19:05:44 +00:00
Chris Lattner
fd3542f84d correct dependency
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34723 91177308-0d34-0410-b5e6-96231b3b80d8
2007-02-28 05:10:40 +00:00
Chris Lattner
bcc3c194a5 target for generating CC info
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34683 91177308-0d34-0410-b5e6-96231b3b80d8
2007-02-27 20:44:12 +00:00
Reid Spencer
18464127a4 Fix some bugs in module building that broke llvm-stacker project.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34099 91177308-0d34-0410-b5e6-96231b3b80d8
2007-02-09 17:09:14 +00:00
Reid Spencer
43eb96c3ef Don't use gccld or gccas
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34093 91177308-0d34-0410-b5e6-96231b3b80d8
2007-02-09 15:52:07 +00:00
Reid Spencer
9bb399cf08 Make the cleaning of BUILT_SOURCES be a "clean-all" target item, not a
"clean" target item. This gets around having the built sources disappear
when only one build mode wants to be cleaned. With the "clean-all" target,
all build modes are cleaned so it also makes sense to clean out the built
sources at that point.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34003 91177308-0d34-0410-b5e6-96231b3b80d8
2007-02-07 19:13:19 +00:00
Reid Spencer
91140e9633 Remove a spurious ;
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33976 91177308-0d34-0410-b5e6-96231b3b80d8
2007-02-07 03:29:29 +00:00