Commit Graph

42886 Commits

Author SHA1 Message Date
Steve Naroff 08899ff85d Remove FileVarDecl and BlockVarDecl. They are replaced by VarDecl::isBlockVarDecl() and VarDecl::isFileVarDecl().
This is a fairly mechanical/large change. As a result, I avoided making any changes/simplifications that weren't directly related. I did break two Analysis tests. I also have a couple FIXME's in UninitializedValues.cpp. Ted, can you take a look? If the bug isn't obvious, I am happy to dig in and fix it (since I broke it).

llvm-svn: 49748
2008-04-15 22:42:06 +00:00
Dan Gohman 82b6673c44 Fix the new scheduler assertion checks to work when
the scheduler has inserted no-ops. This fixes
the 2006-07-03-schedulers.ll regression on ppc32.

llvm-svn: 49747
2008-04-15 22:40:14 +00:00
Bill Wendling 837b1dcf36 Apple GCC 4.2 builds things differently. It no longer spawns a bunch of
processes, but requires the project to use -j.

llvm-svn: 49744
2008-04-15 21:33:52 +00:00
Chuck Rose III c6a47e8a79 VisualStudio project files updated. #include <algorithm> added to make VisualStudio happy. Also had to undefine setjmp because of #include <csetjmp> turning setjmp into _setjmp in VisualStudio.
llvm-svn: 49743
2008-04-15 21:27:11 +00:00
Ted Kremenek 7d6219f501 For HTML diagnostics, output more information about a bug report.
llvm-svn: 49742
2008-04-15 21:25:08 +00:00
Ted Kremenek 43445b3081 Added "summary table" to generated index.html page that allows one to
toggle which bug reports are displayed in the report table.

llvm-svn: 49738
2008-04-15 20:47:02 +00:00
Dale Johannesen 7b96b2e7da Make 64-to-32 bit truncations explicit (prevent warnings).
All values here fit in 32 bits.

llvm-svn: 49736
2008-04-15 18:44:59 +00:00
Ted Kremenek 15d8f4cc27 Added test case illustrating the use of '&'.
llvm-svn: 49735
2008-04-15 18:37:29 +00:00
Ted Kremenek 82ff6d65bc Fix bug in terminator processing for uninitialized-values: simply ignore the terminator, don't reprocess it.
LiveVariables analysis now does a flow-insensitive analysis to determine what variables have their address taken; these variables are now always treated as being live.

The DataflowSolver now uses "SetTopValue()" when getting the initial value for the entry/exit block.

llvm-svn: 49734
2008-04-15 18:35:30 +00:00
Dale Johannesen 8fc8a272e0 Don't assume a tail call can't reference a byval
argument to the outer function, this isn't correct.

llvm-svn: 49731
2008-04-15 17:41:34 +00:00
Dan Gohman 53d3241b52 Use gv's --spartan option, which trades away an extra row of UI buttons
for more space for displaying the graph.

llvm-svn: 49730
2008-04-15 17:27:05 +00:00
Chris Lattner a5eb45bcfd A couple minor fixes suggested by Matthijs Kooijman
llvm-svn: 49729
2008-04-15 16:59:22 +00:00
Argyrios Kyrtzidis 45887902b6 Fix a compiler error on MSVC (variable name 'E' clash).
llvm-svn: 49727
2008-04-15 16:30:10 +00:00
Nicolas Geoffray 7000c8f1aa Change Divided flag to Split, as suggested by Evan
llvm-svn: 49715
2008-04-15 08:08:50 +00:00
Evan Cheng ba7126064a Sort sub-registers and super-registers lists according to super-sub register relations. e.g. X86::RAX sub-register list is EAX, AX, AL, AH (order of last two are not guaranteed).
llvm-svn: 49714
2008-04-15 07:56:03 +00:00
Bill Wendling 97632952c9 Install into the directory
llvm-svn: 49713
2008-04-15 07:02:59 +00:00
Chris Lattner 3e142b2585 finish commenting RewriteRope
llvm-svn: 49712
2008-04-15 06:37:11 +00:00
Ted Kremenek 6d41b82ea4 Improve dead store diagnostic.
llvm-svn: 49711
2008-04-15 05:31:00 +00:00
Ted Kremenek 2ecc9d42f7 Bug fix in VisitChildren: Only visit the last statement in a StmtExpr and the RHS of a comma expression, as the other Stmts will be visited elsewhere in a CFGBlock.
llvm-svn: 49710
2008-04-15 05:11:28 +00:00
Ted Kremenek 8adeebb274 Added initial support into the flow-sensitive dataflow solver to visit the Block-level expression
in a block's terminator.  This expression is visited within a block, but it is accessed by the
terminator.  This is important to observe because for live-variables analysis the block-level
expression is live between the terminator and where the expression occurs in the block.  So far
this hasn't been an issue to not observe this because the block-level expression used in the
terminator is always the last one in the block, and we have never queried the liveness information
about this point (but before the terminator).

llvm-svn: 49709
2008-04-15 04:39:08 +00:00
Ted Kremenek 66279073f7 Bug fix in dead stores: don't always check the liveness of the first decl
in a DeclStmt.

llvm-svn: 49708
2008-04-15 04:11:48 +00:00
Ted Kremenek cd76f95dd0 ++/-- makes a variable live since it is used; thus the liveness state is
"Alive" as opposed to staying the same.

llvm-svn: 49707
2008-04-15 04:08:54 +00:00
Ted Kremenek 044eb055af Handle "__private_extern__" storage class when printing FunctionDecls.
llvm-svn: 49706
2008-04-15 03:57:09 +00:00
Ted Kremenek f4212bdbc3 Bug fix in LiveVariables: Operators ++/-- may kill a value, but the variable
is still live.

llvm-svn: 49705
2008-04-15 03:47:30 +00:00
Chris Lattner 52bc4ac84f Fix a corner case that ted hit in -emit-html, rdar://5863212
llvm-svn: 49703
2008-04-15 02:26:21 +00:00
Dan Gohman 4370f26750 Treat EntryToken nodes as "passive" so that they aren't added to the
ScheduleDAG; they don't correspond to any actual instructions so they
don't need to be scheduled.

This fixes a bug where the EntryToken was being scheduled multiple
times in some cases, though it ended up not causing any trouble because 
EntryToken doesn't expand into anything. With this fixed the schedulers
reliably schedule the expected number of units, so we can check this
with an assertion.

This requires a tweak to test/CodeGen/X86/loop-hoist.ll because it
ends up getting scheduled differently in a trivial way, though it was
enough to fool the prcontext+grep that the test does.

llvm-svn: 49701
2008-04-15 01:22:18 +00:00
Fariborz Jahanian 0152a1a5db New AST representation for each objc2's property declaration.
llvm-svn: 49699
2008-04-14 23:36:35 +00:00
Dan Gohman e5f21cea3e In -view-sunit-dags, display "special" chain dependencies as cyan
instead of blue to distinguish them from regular dependencies.

llvm-svn: 49696
2008-04-14 23:15:07 +00:00
Steve Naroff c5e5b38a8f Remove bogus token...
llvm-svn: 49695
2008-04-14 22:53:48 +00:00
Chris Lattner 492530d2df simplify the implementation of the insert/split operation to return
the new RHS directly instead of indirecting through the 'InsertResult'
struct.  This eliminates InsertResult.

llvm-svn: 49694
2008-04-14 22:10:58 +00:00
Steve Naroff a8f0d12e81 Rename a file and update the Xcode project.
llvm-svn: 49693
2008-04-14 22:05:54 +00:00
Steve Naroff 1dc53ef494 Rename RewriteTest->RewriteObjC.
llvm-svn: 49692
2008-04-14 22:03:09 +00:00
Chris Lattner e58408d8db Add a bunch of comments, move RewriteRope::MakeRopeString out of line.
llvm-svn: 49689
2008-04-14 21:41:00 +00:00
Steve Naroff 4fff2a08aa Fix comment.
llvm-svn: 49688
2008-04-14 21:39:16 +00:00
Ted Kremenek d61ed3b6cb Use isFromMainFile instead of comparing FileIDs directly.
llvm-svn: 49687
2008-04-14 21:24:13 +00:00
Ted Kremenek f6aad13242 Fix regression in Diagnostic that caused it to not register the number
of errors.

llvm-svn: 49686
2008-04-14 21:21:38 +00:00
Ted Kremenek 9569e57a50 Use SourceManager::isFromMainFile()
llvm-svn: 49685
2008-04-14 21:14:41 +00:00
Ted Kremenek 13ad6e1234 Convert over to new SourceManager::isFromMainFile() instead of doing direct
FileID comparison (fixes insidious corner case with chunks).

llvm-svn: 49684
2008-04-14 21:14:03 +00:00
Ted Kremenek bb2b224159 HTMLDiagnostics now uses the new "getCanonicalID()", "isFromMainFileID()" methods from
SourceManager when doing HTML pretty-printing.  This resolves an insidious bug when
presenting error reports that only occurred in large source files.

llvm-svn: 49683
2008-04-14 21:06:04 +00:00
Ted Kremenek 17acadebb4 Added "getCanonicalID()", "isFromSameFile", and "isFromMainFile" to compare
the files of different SourceLocations.  These methods correctly handle the
case where a file may have multiple FileIDs due to it being large enough
to be spread across several chunks.

llvm-svn: 49682
2008-04-14 21:04:18 +00:00
Dan Gohman 4fff979a43 Remove unnecessary <sstream> includes.
llvm-svn: 49681
2008-04-14 20:40:47 +00:00
Chris Lattner dc217191d1 fix more uninit ivars, who wrote this junk? :)
llvm-svn: 49679
2008-04-14 20:07:03 +00:00
Chris Lattner ca94e4263b Fix an assertion ted was hitting, due to an uninitialized variable.
llvm-svn: 49678
2008-04-14 20:05:32 +00:00
Ted Kremenek 193f185902 Only increment the number of diagnostics when the DiagnosticClient used
is the one attached to the Diagnostic object.

llvm-svn: 49677
2008-04-14 19:56:12 +00:00
Dan Gohman 5b61a288a7 Avoid creating MERGE_VALUES nodes for single values.
llvm-svn: 49676
2008-04-14 18:43:25 +00:00
Ted Kremenek 751d4d2d60 Added driver option "-checker-opt-analyze-headers" to force the static
analyzer to analyze functions declared in header files.

llvm-svn: 49675
2008-04-14 18:40:58 +00:00
Dan Gohman 2cd8e38ab9 Teach AliasSetTracker about VAArgInst.
llvm-svn: 49674
2008-04-14 18:34:50 +00:00
Ted Kremenek 87bfc03f4a Don't flag dead stores that occur in macros.
llvm-svn: 49672
2008-04-14 18:28:25 +00:00
Dan Gohman e36714c0b4 Minor whitespace and comment cleanups.
llvm-svn: 49671
2008-04-14 18:26:16 +00:00
Dan Gohman 5e6ce7bb33 In the special case, call the comparison function instead of
manually performing the comparison. This allows the special
case to work correctly even in the case where someone is
experimenting with a different comparison function :-).

llvm-svn: 49670
2008-04-14 18:23:56 +00:00