Mon P Wang
c86715631c
Avoid doing the transformation c ? 1.0 : 2.0 as load { 2.0, 1.0 } + c*4
...
if FPConstant is legal because if the FPConstant doesn't need to be stored
in a constant pool, the transformation is unlikely to be profitable.
llvm-svn: 66994
2009-03-14 00:25:19 +00:00
Douglas Gregor
52aba87df7
Check for overflow and signedness problems with template
...
arguments. Eliminates a FIXME.
llvm-svn: 66993
2009-03-14 00:20:21 +00:00
Ted Kremenek
9a46804ca8
Make Selector::getIdentifierInfo() private. I took a first attempt at this last
...
week in:
http://lists.cs.uiuc.edu/pipermail/cfe-commits/Week-of-Mon-20090302/013580.html
That patch caused the output of the diagnostics to change. Since
'DeclarationName' can already reason about Selectors and the Diagnostics logic
reasons about DeclarationName, there is no additional code needed to get the
diagnostics working by making Selector::getIdentifierInfo() private.
llvm-svn: 66992
2009-03-14 00:20:08 +00:00
Daniel Dunbar
29de588ac2
Don't run simplify lib calls with -ffreestanding (fix for already
...
failing test case).
llvm-svn: 66991
2009-03-14 00:15:04 +00:00
Douglas Gregor
69bd16d814
Make sure that the canonical representation of integral template arguments uses the bitwidth and signedness of the template parameter
...
llvm-svn: 66990
2009-03-14 00:03:48 +00:00
Dan Gohman
638e530509
Add a few more ptrtoint/inttoptr cast tests.
...
llvm-svn: 66989
2009-03-13 23:54:51 +00:00
Dan Gohman
a62e4ab690
Improve FastISel's handling of truncates to i1, and implement
...
ptrtoint and inttoptr in X86FastISel. These casts aren't always
handled in the generic FastISel code because X86 sometimes needs
custom code to do truncation and zero-extension.
llvm-svn: 66988
2009-03-13 23:53:06 +00:00
Douglas Gregor
084d855a17
Implement template instantiation for the prefix unary operators. As
...
always, refactored the existing logic to tease apart the parser action
and the semantic analysis shared by the parser and template
instantiation.
llvm-svn: 66987
2009-03-13 23:49:33 +00:00
Daniel Dunbar
1bb3b2ccf3
Driver: Add types::{isAcceptedByClang,isCXX} predicates.
...
llvm-svn: 66986
2009-03-13 23:46:19 +00:00
Daniel Dunbar
313c291269
Driver: Add simple Job classes, simple wrappers for information about
...
what processes to execute during a compilation.
llvm-svn: 66985
2009-03-13 23:36:33 +00:00
Mike Stump
5469f29aa9
Do up codegen for function static data and externs in functions in block
...
literals.
llvm-svn: 66984
2009-03-13 23:34:28 +00:00
Anders Carlsson
b4cf3ad61b
Pass more sane arguments to ActOnStaticAssertDeclaration
...
llvm-svn: 66983
2009-03-13 23:29:20 +00:00
Daniel Dunbar
438ff8dbe7
Driver: Action vtables were still hungry.
...
llvm-svn: 66980
2009-03-13 23:17:57 +00:00
Ted Kremenek
6483bc2f19
BlockDecl::Destroy now deallocates BlockDecl's array of ParmVarDecl*.
...
llvm-svn: 66979
2009-03-13 23:17:24 +00:00
Daniel Dunbar
3f261ff66b
Driver: Provide food and shelter for Action vtables.
...
llvm-svn: 66978
2009-03-13 23:08:03 +00:00
Dale Johannesen
a4ac735531
Fix -strip-debug-declare to work when there are
...
llvm.global.variable's but no llvm.declare's.
llvm-svn: 66977
2009-03-13 22:59:47 +00:00
Evan Cheng
94419d6fdd
Fix PR3784: If the source of a phi comes from a bb ended with an invoke, make sure the copy is inserted before the try range (unless it's used as an input to the invoke, then insert it after the last use), not at the end of the bb.
...
Also re-apply r66140 which was disabled as a workaround.
llvm-svn: 66976
2009-03-13 22:59:14 +00:00
Ted Kremenek
9750429e61
Add (hidden) TableGen command option '-clang-component' which specifies the
...
component's warnings to process for '-gen-clang-diags-defs'.
Also, when the component is specified, generate a '#if' prologue at the top of
the generated .def file (to match the current files).
llvm-svn: 66975
2009-03-13 22:53:41 +00:00
Daniel Dunbar
94d48e0bd0
Force triple for a couple test cases.
...
llvm-svn: 66974
2009-03-13 22:48:51 +00:00
Chris Lattner
c890aa2802
wire up a new -fno-builtin option, make it control things like simplifylibcalls,
...
etc and make freestanding imply it.
llvm-svn: 66972
2009-03-13 22:38:49 +00:00
Ted Kremenek
dee115697b
Add initial implementation of a TableGen backend for converting Clang-warnings
...
tablegen files to the original .def preprocessor include files. This is my first
TableGen backend; I don't claim that it is awesome.
llvm-svn: 66971
2009-03-13 22:21:17 +00:00
Ted Kremenek
58e32877f1
Further constify Record::isSubClassOf.
...
llvm-svn: 66970
2009-03-13 22:20:10 +00:00
Ted Kremenek
85d00b14fa
Include component warning TableGen files in Diagnostic.td.
...
llvm-svn: 66969
2009-03-13 22:19:07 +00:00
Daniel Dunbar
95e6b191cb
Driver: Sprinkle some consts in, stub out BuildJobs method.
...
llvm-svn: 66968
2009-03-13 22:12:33 +00:00
Daniel Dunbar
a493ff47bd
Update test.
...
llvm-svn: 66967
2009-03-13 22:11:42 +00:00
Chris Lattner
622b1041ca
add a testcase for recursion through blocks pointers, rdar://6676764.
...
llvm-svn: 66965
2009-03-13 22:00:25 +00:00
Devang Patel
4482c0518b
Fix test case. Now, llvm-gcc emits debug info for artificiaal variable _comp_ctor.
...
llvm-svn: 66963
2009-03-13 21:57:16 +00:00
Stuart Hastings
7440952c01
Fix a hashing bug in APInt. A certain pathological testcase (too
...
large for the testsuite) took over six minutes to compile on my Mac.
The patched LLVM-GCC compiles that testcase in three seconds (GCC
takes less than one second). This hash function is more complex
(about 35 instructions on x86) than what Chris wanted, but I expect it
will be well-behaved with arbitrary inputs.
Thank you to everyone who responded to my previous request for advice.
llvm-svn: 66962
2009-03-13 21:51:13 +00:00
Chris Lattner
e07ea35817
fix PR3798 by ignoring all diagnostics generated while repreprocessing a file in rewrite macros.
...
llvm-svn: 66961
2009-03-13 21:44:46 +00:00
Chris Lattner
8bd06d8e1b
Fix escaping in asm string literals correctly by having tblgen unescape
...
them, then the asmprinter emitter reescape them.
llvm-svn: 66958
2009-03-13 21:33:17 +00:00
Chris Lattner
a614ef2000
add a horrible hack to fix the build.
...
llvm-svn: 66957
2009-03-13 21:23:43 +00:00
Chris Lattner
83aba00ee8
make Preprocessor::Diags be a pointer instead of a reference.
...
llvm-svn: 66955
2009-03-13 21:17:43 +00:00
Chris Lattner
80c21df8ea
use accessor instead of poking ivar directly
...
llvm-svn: 66954
2009-03-13 21:17:23 +00:00
Bill Wendling
4bb96e9a50
Revert r66920. It was causing failures in the self-hosting buildbot (in release
...
mode).
Running /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/dg.exp ...
FAIL: /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/crash-narrowfunctiontest.ll
Failed with signal(SIGBUS) at line 1
while running: bugpoint /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/crash-narrowfunctiontest.ll -bugpoint-crashcalls -silence-passes > /dev/null
0 bugpoint 0x0035dd25 llvm::sys::SetInterruptFunction(void (*)()) + 85
1 bugpoint 0x0035e382 llvm::sys::RemoveFileOnSignal(llvm::sys::Path const&, std::string*) + 706
2 libSystem.B.dylib 0x92f112bb _sigtramp + 43
3 libSystem.B.dylib 0xffffffff _sigtramp + 1829694831
4 bugpoint 0x00021d1c main + 92
5 bugpoint 0x00002106 start + 54
6 bugpoint 0x00000004 start + 18446744073709543220
Stack dump:
0. Program arguments: bugpoint /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/crash-narrowfunctiontest.ll -bugpoint-crashcalls -silence-passes
FAIL: /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/misopt-basictest.ll
Failed with signal(SIGBUS) at line 1
while running: bugpoint /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/misopt-basictest.ll -dce -bugpoint-deletecalls -simplifycfg -silence-passes
0 bugpoint 0x0035dd25 llvm::sys::SetInterruptFunction(void (*)()) + 85
1 bugpoint 0x0035e382 llvm::sys::RemoveFileOnSignal(llvm::sys::Path const&, std::string*) + 706
2 libSystem.B.dylib 0x92f112bb _sigtramp + 43
3 libSystem.B.dylib 0xffffffff _sigtramp + 1829694831
4 bugpoint 0x00021d1c main + 92
5 bugpoint 0x00002106 start + 54
6 bugpoint 0x00000006 start + 18446744073709543222
Stack dump:
0. Program arguments: bugpoint /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/misopt-basictest.ll -dce -bugpoint-deletecalls -simplifycfg -silence-passes
FAIL: /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/remove_arguments_test.ll
Failed with signal(SIGBUS) at line 1
while running: bugpoint /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/remove_arguments_test.ll -bugpoint-crashcalls -silence-passes
0 bugpoint 0x0035dd25 llvm::sys::SetInterruptFunction(void (*)()) + 85
1 bugpoint 0x0035e382 llvm::sys::RemoveFileOnSignal(llvm::sys::Path const&, std::string*) + 706
2 libSystem.B.dylib 0x92f112bb _sigtramp + 43
3 libSystem.B.dylib 0xffffffff _sigtramp + 1829694831
4 bugpoint 0x00021d1c main + 92
5 bugpoint 0x00002106 start + 54
Stack dump:
0. Program arguments: bugpoint /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/remove_arguments_test.ll -bugpoint-crashcalls -silence-passes
--- Reverse-merging (from foreign repository) r66920 into '.':
U include/llvm/Support/CallSite.h
U include/llvm/Instructions.h
U lib/Analysis/IPA/GlobalsModRef.cpp
U lib/Analysis/IPA/Andersens.cpp
U lib/Bitcode/Writer/BitcodeWriter.cpp
U lib/VMCore/Instructions.cpp
U lib/VMCore/Verifier.cpp
U lib/VMCore/AsmWriter.cpp
U lib/Transforms/Utils/LowerInvoke.cpp
U lib/Transforms/Scalar/SimplifyCFGPass.cpp
U lib/Transforms/IPO/PruneEH.cpp
U lib/Transforms/IPO/DeadArgumentElimination.cpp
llvm-svn: 66953
2009-03-13 21:15:59 +00:00
Douglas Gregor
4b7f3d7344
Devious test-case involved overload resolution and ADL during template instantiation.
...
llvm-svn: 66951
2009-03-13 21:04:12 +00:00
Daniel Dunbar
c178c5f126
Driver: Desensitize test to location of input.
...
llvm-svn: 66950
2009-03-13 21:03:35 +00:00
Chris Lattner
1bd3674306
add support for a few simple escape characters in tblgen strings.
...
llvm-svn: 66949
2009-03-13 21:03:27 +00:00
Douglas Gregor
0950e41b73
Implement template instantiation for several more kinds of expressions:
...
- C++ function casts, e.g., T(foo)
- sizeof(), alignof()
More importantly, this allows us to verify that we're performing
overload resolution during template instantiation, with
argument-dependent lookup and the "cached" results of name lookup from
the template definition.
llvm-svn: 66947
2009-03-13 21:01:28 +00:00
Daniel Dunbar
5b86bf527e
Add ENABLE_COVERAGE, for building a +Coverage (gcov) configuration.
...
- Required some extra makefile tweaks to introduce a new flag var
which only goes to compile/link tools but not the relink step,
otherwise we get a copy of libgcov in the relinked .o files.
- No configure magic for this.
llvm-svn: 66945
2009-03-13 20:59:41 +00:00
Ted Kremenek
decee183ee
Fix typo.
...
llvm-svn: 66944
2009-03-13 20:47:27 +00:00
Ted Kremenek
b83ab59e07
Add missing ';'.
...
llvm-svn: 66943
2009-03-13 20:45:13 +00:00
Daniel Dunbar
192f4facac
Driver: Test pipelining for universal builds.
...
llvm-svn: 66942
2009-03-13 20:45:03 +00:00
Dan Gohman
c0bb959591
Fix FastISel's assumption that i1 values are always zero-extended
...
by inserting explicit zero extensions where necessary. Included
is a testcase where SelectionDAG produces a virtual register
holding an i1 value which FastISel previously mistakenly assumed
to be zero-extended.
llvm-svn: 66941
2009-03-13 20:42:20 +00:00
Fariborz Jahanian
b03d5a6b36
Fix a bug in building function pointer type
...
corresponding to block pointer.
llvm-svn: 66940
2009-03-13 20:36:41 +00:00
Daniel Dunbar
e5dc48233f
Driver: For universal builds, handle archs in the order they were seen.
...
llvm-svn: 66939
2009-03-13 20:33:35 +00:00
Daniel Dunbar
427d6f1a95
ccc: Handle limited forms of -ccc-host-triple for testing
...
compatibility with C++ rewrite.
llvm-svn: 66938
2009-03-13 20:33:09 +00:00
Chris Lattner
2150eb9f6f
remove a test that depends on -debug.
...
llvm-svn: 66937
2009-03-13 20:31:48 +00:00
Chris Lattner
033a654dee
remove a testcase that depends on -debug existing.
...
llvm-svn: 66936
2009-03-13 20:31:25 +00:00
Ted Kremenek
340fd2dd6e
Fix PR 3677 [retain checker]: custom 'allocWithZone' methods should be allowed
...
to return an owning pointer.
llvm-svn: 66934
2009-03-13 20:27:06 +00:00
Rafael Espindola
997b74ac61
add 8 and 16 bit TLS moves.
...
add a fixme note on how to remove code duplication.
llvm-svn: 66932
2009-03-13 19:39:55 +00:00