Commit Graph

72646 Commits

Author SHA1 Message Date
Mike Stump 58ef18b38c Checkpoint current work. WIP.
llvm-svn: 89513
2009-11-20 23:44:51 +00:00
Douglas Gregor ade9bcd72e Cope with extraneous "template" keyword when providing an out-of-line
definition of a member template (or a member thereof). Fixes PR5566.

llvm-svn: 89512
2009-11-20 23:39:24 +00:00
David Goodwin 5305dc0be1 Restructure code to allow renaming of multiple-register groups for anti-dep breaking.
llvm-svn: 89511
2009-11-20 23:33:54 +00:00
Evan Cheng 73f9a9e2c8 Enable hoisting load from constant memories.
llvm-svn: 89510
2009-11-20 23:31:34 +00:00
Dan Gohman 312971513f Fix a thinko that caused spurious @GOTOFFs.
llvm-svn: 89509
2009-11-20 23:30:32 +00:00
Daniel Dunbar a764eef0e9 Driver: Add clang -cc1 dependency output options parsing.
llvm-svn: 89508
2009-11-20 23:28:07 +00:00
Dan Gohman e14b347176 Update for new getBlockAddress signature.
llvm-svn: 89507
2009-11-20 23:21:00 +00:00
Dan Gohman 7a6611793f Target-independent support for TargetFlags on BlockAddress operands,
and support for blockaddresses in x86-32 PIC mode.

llvm-svn: 89506
2009-11-20 23:18:13 +00:00
Daniel Dunbar a604639635 Switch CompilerInvocation::CreateFromArgs to take const char** arguments until Driver itself switches to StringRef.
llvm-svn: 89503
2009-11-20 22:47:55 +00:00
Daniel Dunbar 2eaef18e76 Fix refactoro, clang-cc wasn't properly reporting errors when opening an output file failed.
llvm-svn: 89502
2009-11-20 22:32:38 +00:00
Daniel Dunbar 32164f4bdb Driver: Use '-target-abi' 'FOO' instead of '-target-abi=FOO'.
llvm-svn: 89501
2009-11-20 22:32:30 +00:00
Sean Callanan c1f532e930 Recommitting PALIGNR shift width fixes.
Thanks to Daniel Dunbar for fixing clang intrinsics:
  http://llvm.org/viewvc/llvm-project?view=rev&revision=89499

llvm-svn: 89500
2009-11-20 22:28:42 +00:00
Daniel Dunbar b17d34906a Update for palign intrinsic fix.
llvm-svn: 89499
2009-11-20 22:21:59 +00:00
Daniel Dunbar 4274685b63 Pass '-mcpu' 'FOO' instead of '-mcpu=FOO'.
llvm-svn: 89498
2009-11-20 22:21:52 +00:00
Daniel Dunbar 8bed86c43e Standardize Driver translation to call clang-cc using '-foo' form instead of '--foo'.
llvm-svn: 89497
2009-11-20 22:21:36 +00:00
Dale Johannesen 8495a506eb Remove an incorrect overaggressive optimization
(PPC specific).

llvm-svn: 89496
2009-11-20 22:16:40 +00:00
Sean Callanan 19d92728d0 Reverting PALIGNR fix until I figure out how this
broke the Clang testsuite.

llvm-svn: 89495
2009-11-20 22:09:28 +00:00
Douglas Gregor 2094c5e80f A previous commit fixed PR5519; here's the test case.
llvm-svn: 89494
2009-11-20 22:05:53 +00:00
Douglas Gregor a25d65d1b6 Implement C++ [basic.lookup.classref]p3, which states how the type
name 'T' is looked up in the expression

  t.~T()

Previously, we weren't looking into the type of "t", and therefore
would fail when T actually referred to an injected-class-name. Fixes
PR5530.

llvm-svn: 89493
2009-11-20 22:03:38 +00:00
Douglas Gregor 09177b2b7f Update C++ status
llvm-svn: 89492
2009-11-20 22:00:06 +00:00
Sean Callanan fbed130173 Fixed PALIGNR to take 8-bit rotations in all cases.
Also fixed the corresponding testcase, and the PALIGNR
  intrinsic (tested for correctness with llvm-gcc).

llvm-svn: 89491
2009-11-20 21:40:28 +00:00
Devang Patel e064ad4741 Do not hold on to a map slot while new entries may be inserted into the map.
Use ValueMap, instead of std::map.

llvm-svn: 89490
2009-11-20 21:37:22 +00:00
David Greene f46c37c0de Cleanups.
Make things a little more efficient as suggested by Evan.

llvm-svn: 89489
2009-11-20 21:13:27 +00:00
Devang Patel 85121a3bda There is no need to emit source location info for DW_TAG_pointer_type.
llvm-svn: 89487
2009-11-20 21:05:37 +00:00
Dan Gohman fbffe63528 Make Loop::getLoopLatch() work on loops which don't have preheaders, as
it may be used in contexts where preheader insertion may have failed due
to an indirectbr.

Make LoopSimplify's LoopSimplify::SeparateNestedLoop properly fail in
the case that it would require splitting an indirectbr edge.

These fix PR5502.

llvm-svn: 89484
2009-11-20 20:51:18 +00:00
Dan Gohman d15302afa0 Fix IPSCCP's code for deleting dead blocks to tolerate outstanding
blockaddress users. This fixes PR5569.

llvm-svn: 89483
2009-11-20 20:19:14 +00:00
Daniel Dunbar f87c75706f Revert "Add some rough optimizations for checking routines.", it buildeth not.
llvm-svn: 89482
2009-11-20 20:17:30 +00:00
Douglas Gregor e4f764f013 When checking the base object of a member access expression (b.foo,
b->foo), don't look through pointers unless we have an -> operator.

llvm-svn: 89480
2009-11-20 19:58:21 +00:00
Eric Christopher cf97d01dff Add some rough optimizations for checking routines.
llvm-svn: 89479
2009-11-20 19:57:37 +00:00
Evan Cheng bdb43a9d99 Remat VLDRD from constpool. Clean up some instruction property specifications.
llvm-svn: 89478
2009-11-20 19:57:15 +00:00
Evan Cheng b39a9fd3ed Add option -licm-const-load to hoist all loads from constant memory.
llvm-svn: 89477
2009-11-20 19:55:37 +00:00
Douglas Gregor 51c538bee4 Teach FixOverloadedFunctionReference to build new expression ASTs rather
than tweaking existing ASTs, since we were (*gasp*) stomping on ASTs
within templates. I'm glad we found this little stick of TNT early...

llvm-svn: 89475
2009-11-20 19:42:02 +00:00
Jim Grosbach 6c3b71195a The verify() call of CPEIsInRange() isn't right for the assertion check of
constant pool ranges, as CPEIsInRange() makes conservative assumptions about
the potential alignment changes from branch adjustments. The verification,
on the other hand, runs after those branch adjustments are made, so the
effects on alignment are known and already taken into account. The sanity
check in verify should check the range directly instead.

llvm-svn: 89473
2009-11-20 19:37:38 +00:00
Dan Gohman ff20377740 Use stripPointerCasts(). Thanks Duncan!
llvm-svn: 89472
2009-11-20 19:33:16 +00:00
David Goodwin 80a03cc0b1 Remove some old experimental code that is no longer needed. Remove additional, speculative scheduling pass as its cost did not translate into significant performance improvement. Minor tweaks.
llvm-svn: 89471
2009-11-20 19:32:48 +00:00
Jakob Stoklund Olesen b4c14ebfbb More consistent labelling of basic blocks in debug output
llvm-svn: 89470
2009-11-20 18:54:59 +00:00
Mike Stump 4d119e49f9 Add testcases for recent checkins.
llvm-svn: 89469
2009-11-20 18:51:28 +00:00
Dan Gohman a8c144d534 Revert the rule that considers comparisons between two pointers in the
same object to be a non-capture; Duncan pointed out a way that such
a comparison could be a capture.

Make the rule that considers a comparison against null more specific,
and only consider noalias return values compared against null. This
still supports test/Transforms/GVN/nonescaping-malloc.ll, and is not
susceptible to the problem Duncan pointed out with noalias arguments.

llvm-svn: 89468
2009-11-20 17:50:21 +00:00
Anders Carlsson 0a66c26191 Fix lifetime of conditional temporaries. Patch by Victor Zverovich!
llvm-svn: 89467
2009-11-20 17:27:56 +00:00
Daniel Dunbar 9c7efbb996 Fix some codegen tests to include positive checks.
llvm-svn: 89465
2009-11-20 17:23:39 +00:00
Daniel Dunbar 69fd86dd44 Add clang -cc1 parsing of CodeGenOptions.
llvm-svn: 89464
2009-11-20 17:23:30 +00:00
Mikhail Glushenkov 5551c207cd Move the handling of CommaSeparated options into ProvideOption.
Makes '--comma-separated val1,val2' mean the same thing as
'--comma-separated=val1,val2' (that is, 'val1' and 'val2' are not lumped
together as 'val1,val2'). Also declutters the main loop a bit.

llvm-svn: 89463
2009-11-20 17:23:17 +00:00
Daniel Dunbar 8cde1d978f clang-cc: Lift setForcedLangOptions out of options initialization.
llvm-svn: 89462
2009-11-20 16:55:31 +00:00
Ken Dyck 33211d9658 Avoid unwanted expansion in macros that paste together INT<n>_C(v) and
UINT<n>_C(v) macros. 

llvm-svn: 89461
2009-11-20 16:49:10 +00:00
Ken Dyck 8dcc21420b Avoid unwanted expansion in macros that paste together INT<n>_MIN, INT<n>_MAX,
and UINT<n>_MAX defintions.

llvm-svn: 89460
2009-11-20 16:44:38 +00:00
Ken Dyck 764a5f3881 Avoid unwanted macro expansion in macros that paste together int<n>_t and
uint<n>_t definitions.

llvm-svn: 89459
2009-11-20 16:37:35 +00:00
David Chisnall bc8bdea183 Fixed crash when using undefined protocols (GNU runtime).
llvm-svn: 89457
2009-11-20 14:50:59 +00:00
Duncan Sands 9e26aac773 Fix PR5563, an expensive checks failure when running on
tests/Transforms/InstCombine/shufflemask-undef.ll.  If
anyone cares, the use of 2*e here (and the equivalent
all over the place in instcombine) seems wrong, though
harmless: it should really be twice the length of the
input vector.  I think shufflevector used to require
that the mask have the same length as the input, but I
don't think that's true any more.  I don't care enough
about vectors to do anything about this...

llvm-svn: 89456
2009-11-20 13:19:51 +00:00
Benjamin Kramer df5280df05 Add a workaround to silence a bogus g++-4.4 -pedantic warning.
driver.cpp:211: warning: ISO C++ forbids zero-size array 'argv'

llvm-svn: 89455
2009-11-20 11:49:06 +00:00
Duncan Sands cc0a0cb4b7 Fix PR5558, which was caused by a wrong fix for PR3393 (see commit 63048),
which was an expensive checks failure due to a bug in the checking.  This
patch in essence reverts the original fix for PR3393, and refixes it by a
tweak to the way expensive checking is done.

llvm-svn: 89454
2009-11-20 10:45:10 +00:00