Commit Graph

78766 Commits

Author SHA1 Message Date
Ted Kremenek 514ff70d04 Fix another crash on invalid code. In this case, handle ObjC categories (with no names)
that refer to an undefined class.

llvm-svn: 96976
2010-02-23 19:39:46 +00:00
Devang Patel d09b921b7d new test case for r96974.
llvm-svn: 96975
2010-02-23 19:37:40 +00:00
Chris Lattner 8d7b4393d2 no need to override IsLegalToFold, the base implementation
disables load folding at -O0.

llvm-svn: 96973
2010-02-23 19:33:11 +00:00
Chris Lattner 8585850e94 fix a bug in findNonImmUse (used by IsLegalToFold) where nodes with
no id's would cause early exit allowing IsLegalToFold to return true
instead of false, producing a cyclic dag.

This was striking the new isel because it isn't using SelectNodeTo yet,
which theoretically is just an optimization.

llvm-svn: 96972
2010-02-23 19:32:27 +00:00
Chris Lattner 1738d49b74 Print node ID's in dumps and views if set.
llvm-svn: 96971
2010-02-23 19:31:18 +00:00
John McCall ff96ccd337 Don't assert on compound assignment operators that operate in FP types when
the result is integral.  Fixes <rdar://problem/7676608>.

llvm-svn: 96970
2010-02-23 19:22:29 +00:00
Wesley Peck e4801e49c9 Adding the MicroBlaze backend.
The MicroBlaze is a highly configurable 32-bit soft-microprocessor for
use on Xilinx FPGAs. For more information see:
http://www.xilinx.com/tools/microblaze.htm
http://en.wikipedia.org/wiki/MicroBlaze

The current LLVM MicroBlaze backend generates assembly which can be
compiled using the an appropriate binutils assembler.

llvm-svn: 96969
2010-02-23 19:15:24 +00:00
Fariborz Jahanian 404dc425bc A test case for property synthesis using ivar in class extensions.
llvm-svn: 96968
2010-02-23 18:50:01 +00:00
Chris Lattner e4f249bc06 use OutStreamer.EmitCodeAlignment for alignment in the text
segment.

llvm-svn: 96967
2010-02-23 18:46:22 +00:00
Chris Lattner eebaf6a76f genericize MCAsmStreamer::EmitCodeAlignment to support other targets
so that it doesn't break them when the code generator starts using it.

llvm-svn: 96966
2010-02-23 18:44:31 +00:00
Jeffrey Yasskin d097117121 Oops. Pass -lgcc _only_ on ARM, not on everything except ARM.
llvm-svn: 96965
2010-02-23 18:40:48 +00:00
Richard Osborne 3a53f4e240 ECALLF, ECALLT shouldn't be marked as barriers.
llvm-svn: 96964
2010-02-23 18:29:49 +00:00
Kevin Enderby e83d74f626 This is the first patch to put the needed bits in place to eventually allow code
to be aligned with optimal nops.  This patch does not change any functionality
and when the compiler is changed to use EmitCodeAlignment() it should also not
change the resulting output.  Once the compiler change is made and everything
looks good the next patch with the table of optimal X86 nops will be added to
WriteNopData() changing the output.  There are many FIXMEs in this patch which
will be removed when we have better target hooks (coming soon I hear).

llvm-svn: 96963
2010-02-23 18:26:34 +00:00
Eli Friedman 1e6bc133ce Make previous fix handle a few more edge cases.
llvm-svn: 96962
2010-02-23 18:25:09 +00:00
Eli Friedman ad5f0789f6 PR6400: Handle an extreme edge case in mangling correctly.
llvm-svn: 96961
2010-02-23 18:20:18 +00:00
Richard Osborne f81db146b4 Mark unconditional branches as barriers. Found using -verify-machineinstrs
llvm-svn: 96960
2010-02-23 18:13:38 +00:00
Jeffrey Yasskin 3ac46ccdff Roll r96559 forward again, adding libLLVM-2.7svn.so to LLVM. This links 3 of
the examples shared to make sure the shared library keeps working.

llvm-svn: 96959
2010-02-23 18:10:07 +00:00
Eli Friedman d2c0de6b44 PR6386: Fix a recent regression in IRGen of cast-to-union constructs.
llvm-svn: 96958
2010-02-23 17:58:35 +00:00
David Greene d8ecd5e902 Speed up cycle checking significantly by caching results.
llvm-svn: 96956
2010-02-23 17:37:50 +00:00
Dan Gohman cd4c03e886 Don't do (X != Y) ? X : Y -> X for floating-point values; it doesn't
handle NaN properly.

Do (X une Y) ? X : Y  -> X if one of X and Y is not zero.

llvm-svn: 96955
2010-02-23 17:17:57 +00:00
Jim Grosbach 2f840382e2 Spelling. s/suppor /support /
llvm-svn: 96954
2010-02-23 17:16:27 +00:00
Dan Gohman 8a0eb36d23 Remove the code which constant-folded ptrtoint(inttoptr(x)+c) to
getelementptr. Despite only doing so in the case where x is a known
array object and c can be converted to an index within range, this
could still be invalid if c is actually the address of an object
allocated outside of LLVM. Also, SCEVExpander, the original motivation
for this code, has since been improved to avoid inttoptr+ptroint in
more cases.

llvm-svn: 96950
2010-02-23 16:35:41 +00:00
Garrison Venn 26a18ca97f Modified examples Makefile to only build the ExceptionDemo example for
x86 and x86_64 on UNIX systems. Only OS X 10.6.2 (x86_64) and 32bit CentOS 5.2
with gcc 4.1.2 were tested. ARM UNIX build triggered failure motivating this
modification, as it seems that the ARM ABI does not support _Unwind_GetIP(...),
_Unwind_SetGR(...), and _Unwind_SetIP(...). From doing a quick browse of:
http://infocenter.arm.com/help/topic/com.arm.doc.ihi0038a/IHI0038A_ehabi.pdf,
it seems as if all other exception related apis are supported. Looks like
the port can be done to ARM. Thanks to Xerxes Rånby <xerxes@zafena.se> for
pointing out this error.

llvm-svn: 96949
2010-02-23 16:27:59 +00:00
Wesley Peck b0da6135bd Testing subversion commit access
llvm-svn: 96948
2010-02-23 15:11:17 +00:00
Mikhail Glushenkov 98d0298a0e Fix -mtune forwarding.
llvm-svn: 96944
2010-02-23 14:29:42 +00:00
Richard Osborne e3eb3105d9 Remove unused lowering function LowerJumpTable
llvm-svn: 96943
2010-02-23 14:17:20 +00:00
Richard Osborne f578196968 Lower BR_JT on the XCore to a jump into a series of jump instructions.
llvm-svn: 96942
2010-02-23 13:25:07 +00:00
Richard Pennington 14cc983d86 Retain attributes for K&R style parameter declarations.
llvm-svn: 96941
2010-02-23 12:22:13 +00:00
Daniel Dunbar 7e4acbdf53 tests: Don't make a missing llvm-gcc dir a fatal error.
llvm-svn: 96938
2010-02-23 11:34:12 +00:00
Daniel Dunbar e615b5fe4d Switch .bc/.ll Makefile rules to use LLVM{CC,CXX} instead of LLVMG{CC,XX}
llvm-svn: 96936
2010-02-23 10:28:06 +00:00
Daniel Dunbar 16a1353031 Add LLVM{CC,CXX} make variables, which specify the configured path the LLVM
capable compilers (which could be llvm-gcc or clang).

llvm-svn: 96935
2010-02-23 10:00:53 +00:00
Daniel Dunbar 49b962cc26 Initial configure support for using Clang as the LLVM capable compiler.
Comes in two parts:
 1. Use --with-clang=path/to/clang/compiler to select an installed clang, or
    --with-built-clang to have the makefiles use the clang which will be built
    as the LLVM capable compiler. If neither is given, --with-built-clang will
    be used if the Clang sources are checked out into the standard location
    (tools/clang).

 2. Use --with-llvmcc={llvm-gcc,clang,none} to specify which LLVM capable
    compiler to use. If not given, then llvm-gcc will be used if available,
    otherwise Clang.

Makefile support still to come.

Eric, Doug, Chris, seem reasonable?

llvm-svn: 96934
2010-02-23 10:00:49 +00:00
Mikhail Glushenkov 527bfeeda7 Update mcc16 and the ancient Clang plugin for the 'cmd_line' -> 'command' change.
llvm-svn: 96933
2010-02-23 09:59:30 +00:00
Daniel Dunbar 8657a02e3e Eliminate CFERuntimeLibDir make variable, this shouldn't be needed.
llvm-svn: 96932
2010-02-23 09:28:50 +00:00
Daniel Dunbar 5c8f47863c Fix a thinko in the lit.cfg.
llvm-svn: 96931
2010-02-23 09:28:48 +00:00
Mikhail Glushenkov cf68f26beb Input files with empty suffixes must be passed to linker.
llvm-svn: 96927
2010-02-23 09:05:21 +00:00
Mikhail Glushenkov 3f8f81e39a Support -Xlinker et al.
llvm-svn: 96926
2010-02-23 09:05:15 +00:00
Mikhail Glushenkov 1824fa40d9 Temporary disable response files.
They are giving us problems on Mac.

llvm-svn: 96925
2010-02-23 09:05:10 +00:00
Mikhail Glushenkov 6e3c5dd8a3 Typo.
llvm-svn: 96924
2010-02-23 09:05:06 +00:00
Mikhail Glushenkov f4c5cfac0d Trailing whitespace.
llvm-svn: 96923
2010-02-23 09:05:01 +00:00
Mikhail Glushenkov 3222d94a28 Implement order-preserving option forwarding.
Needed to correctly handle things like 'llvmc -framework Foo foo.o -framework
Bar bar.o' - before this commit all '-framework' options would've been grouped
together in the beginning.

Due to our dependence on CommandLine this turned out to be a giant hack; we will
migrate away from CommandLine eventually.

llvm-svn: 96922
2010-02-23 09:04:57 +00:00
Mikhail Glushenkov d76f096a53 Update the test suite.
llvm-svn: 96921
2010-02-23 09:04:51 +00:00
Mikhail Glushenkov a44e838bcb Correct option forwarding: initial implementation.
Does not work, but the infrastructure changes are in place.

llvm-svn: 96920
2010-02-23 09:04:44 +00:00
Mikhail Glushenkov 04ae7a6e01 Precompiled headers: initial support.
llvm-svn: 96919
2010-02-23 09:04:33 +00:00
Mikhail Glushenkov ebf8fbbb8f New experimental/undocumented feature: 'works_on_empty'.
For now, just enough support to make -filelist work.

llvm-svn: 96918
2010-02-23 09:04:28 +00:00
Mikhail Glushenkov 23cce8188b Support '-install_name'.
llvm-svn: 96917
2010-02-23 09:04:18 +00:00
Mikhail Glushenkov e499d576a9 Add a way to enable '-opt=foo' forwarding.
llvm-svn: 96916
2010-02-23 09:04:13 +00:00
Daniel Dunbar 40886109ce Inline and eliminate LLVMG{CC,XX}WITHPATH.
llvm-svn: 96913
2010-02-23 07:56:41 +00:00
Daniel Dunbar d6800f5ee9 Remove ancient Xcode project, replaced by CMake project.
llvm-svn: 96912
2010-02-23 07:56:38 +00:00
Daniel Dunbar e63080d6cc Remove dead LUPGRADE make variable.
llvm-svn: 96911
2010-02-23 07:56:36 +00:00