Commit Graph

42400 Commits

Author SHA1 Message Date
Chris Lattner e799eb5daa Fix PR2081 (problems codegen'ing some recursive structures) patch
by Lauro Venancio!

llvm-svn: 49144
2008-04-03 05:50:42 +00:00
Sam Bishop 2289459bf6 Created a destructor so that the top-level decls can be deleted.
llvm-svn: 49142
2008-04-03 05:35:20 +00:00
Sam Bishop 5981404289 Temporarily make the Decl virtual destructor public, so that calls to "delete"
can be tested on derived classes.

llvm-svn: 49141
2008-04-03 05:29:20 +00:00
Ted Kremenek e4c029e7aa Add back bug name to PathDiagnostic.
llvm-svn: 49139
2008-04-03 05:23:19 +00:00
Chris Lattner 3a0702e631 Fix a bug where we didn't check the RHS for null, we checked
the LHS for null twice.

llvm-svn: 49138
2008-04-03 05:07:25 +00:00
Chris Lattner efdc7685d4 qualifier comparisons should be done on canonical types.
llvm-svn: 49137
2008-04-03 05:07:04 +00:00
Sam Bishop 03e662d5be Call delete on the deserialized TranslationUnit object.
llvm-svn: 49136
2008-04-03 05:03:34 +00:00
Sam Bishop ca6226628e Call "delete" on the body of FunctionDecls.
llvm-svn: 49135
2008-04-03 05:01:04 +00:00
Ted Kremenek 4e9cc3f272 When creating PathDiagnostics, created a trimmed graph first and report the
BFS path to the root.  This also avoids problems with loops in the ExplodedGraph.

llvm-svn: 49133
2008-04-03 04:59:14 +00:00
Ted Kremenek 588dcdd58b Added node_iterator to ExplodedGraph to allow iteration over all nodes in
the graph.

llvm-svn: 49132
2008-04-03 04:58:29 +00:00
Evan Cheng 3063c5546e Temporarily disabling SSE4 until we fix the encoding issues.
llvm-svn: 49129
2008-04-03 04:49:54 +00:00
Ted Kremenek 572875c43f Updated Xcode project to include BugReporter.[cpp,h].
llvm-svn: 49128
2008-04-03 04:43:40 +00:00
Ted Kremenek 505a36afc6 Created new path-sensitive bug-reporting scheme based on the classes
"BugReporter" and "BugDescription".  BugDescription is used to describe
a bug and provide pieces of the PathDiagnostic, and BugReporter creates
the actual PathDiagnostic by crawling through the ExplodedGraph.

Migrated checks done by GRSimpleVals to be reported using the new BugReporter
mechanism.

llvm-svn: 49127
2008-04-03 04:42:52 +00:00
Ted Kremenek 7c7616cf29 Added missing #ifndef...#define...#endif directives to protect against
double includes.

llvm-svn: 49126
2008-04-03 04:38:39 +00:00
Evan Cheng 025cea1126 Backing out 48222 temporarily.
llvm-svn: 49124
2008-04-03 03:13:16 +00:00
Dan Gohman fc4ad7de66 Move instruction flag inference out of InstrInfoEmitter and into
CodeGenDAGPatterns, where it can be used in other tablegen backends.
This allows the inference to be done for DAGISelEmitter so that it
gets accurate mayLoad/mayStore/isSimpleLoad flags. 

This brings MemOperand functionality back to where it was before
48329. However, it doesn't solve the problem of anonymous patterns
which expand to code that does loads or stores.

llvm-svn: 49123
2008-04-03 00:02:49 +00:00
Dan Gohman bd72cea737 Suppress the 128-bit integer typedef on 32-bit targets, because
it causes compile errors.

llvm-svn: 49122
2008-04-02 23:52:49 +00:00
Ted Kremenek 84041843af CSS tweaking on blue boxes.
llvm-svn: 49121
2008-04-02 22:50:50 +00:00
Ted Kremenek 33d03a52f0 80 col violation
llvm-svn: 49120
2008-04-02 22:08:09 +00:00
Ted Kremenek 744fb6d9e7 Added more PathDiagnostic rendering for terminators: switch, goto, loops.
llvm-svn: 49119
2008-04-02 22:03:53 +00:00
Ted Kremenek ab2a52c4bf Blue diagnostic boxes.
llvm-svn: 49117
2008-04-02 21:14:04 +00:00
Ted Kremenek 258493c188 Added path sequence numbers in HTML output of PathDiagnostics.
llvm-svn: 49116
2008-04-02 21:04:20 +00:00
Ted Kremenek 3e38d6ad3c Fix initialization bug.
llvm-svn: 49115
2008-04-02 20:44:27 +00:00
Ted Kremenek 3276af4c1a Embed BUGLINE, BUGFILE, BUGPATHLENGTH in the emitted HTML file.
llvm-svn: 49114
2008-04-02 20:44:16 +00:00
Ted Kremenek 00ab318cf2 Made bug index tables sortable.
Added line number, file information, path length, for each bug report.

llvm-svn: 49113
2008-04-02 20:43:36 +00:00
Ted Kremenek 260fc46000 Added "back()" method to PathDiagnostic to access the last piece in a path.
llvm-svn: 49112
2008-04-02 20:35:01 +00:00
Dale Johannesen 5316aebeb6 Testcase for EH with functions whose names are stripped.
llvm-svn: 49111
2008-04-02 20:16:41 +00:00
Dale Johannesen 491557712a Make EH work with unnamed functions. Reenable running
StripSymbols when EH is on.

llvm-svn: 49110
2008-04-02 20:10:52 +00:00
Dan Gohman 39d8b26322 Partial CBackend support for 128-bit integers. This is needed
now that llvm-gcc is lowering appropriately-sized struct returns
to i128 on x86-64.

llvm-svn: 49109
2008-04-02 19:40:14 +00:00
Ted Kremenek c57139e104 Initial work on CSS in generated index.html.
Added "-V/--view" option to view index.html after it has been generated.

llvm-svn: 49108
2008-04-02 18:42:49 +00:00
Steve Naroff 778927532d Change ObjCInterfaceDecl to inherit from NamedDecl (not TypeDecl). While ObjCInterfaceDecl is arguably a TypeDecl, it isn't a ScopedDecl. Since TypeDecl's are scoped, it makes sense to simply treat them as NamedDecl's. I could have fiddled a bit more with the hierarchy (in terms of creating a non-scoped TypeDecl), however this probably isn't worth the effort.
I also finished unifying access to scope decl change by converting Sema::getObjCInterfaceDecl() to use Sema::LookupDecl(). This is much cleaner now:-)

llvm-svn: 49107
2008-04-02 18:30:49 +00:00
David Greene 586740f401 Iterators folloring a SmallVector erased element are invalidated so
don't access cached iterators from after the erased element.

Re-apply 49056 with SmallVector support.

llvm-svn: 49106
2008-04-02 18:24:46 +00:00
Evan Cheng d8616064d8 Now that I am told MachineRegisterInfo also tracks physical register uses / defs, I can do away with the horribleness I introduced a while back. It's impossible to detect if there is any use of a physical register below an instruction (and before any def of the register) with some cheap book keeping.
llvm-svn: 49105
2008-04-02 18:04:08 +00:00
Ted Kremenek 2cd0d63d30 Initial support for generating index.html file.
llvm-svn: 49104
2008-04-02 18:03:36 +00:00
Ted Kremenek 13c0885a8d Put "BUGDESC" comment tag on its own line.
llvm-svn: 49103
2008-04-02 18:03:20 +00:00
Ted Kremenek 383bfd27d0 Shorted bug-description.
llvm-svn: 49102
2008-04-02 18:02:54 +00:00
Chris Lattner 182f660d8d simplify some code by using PointerLikeType.
llvm-svn: 49101
2008-04-02 17:45:06 +00:00
Chris Lattner db5f1fa3d8 add a common base class "PointerLikeType" for PointerType and ReferenceType,
allowing them to be treated the same in some contexts.  A suggestion for a
better name is welcome :)

llvm-svn: 49100
2008-04-02 17:35:06 +00:00
Evan Cheng be3d44c3cb Remove #include<map> from LiveVariables.h. Not referenced.
llvm-svn: 49099
2008-04-02 17:23:50 +00:00
Chris Lattner b1f7398b1c properly handle array decay in objc message exprs.
llvm-svn: 49098
2008-04-02 17:17:33 +00:00
Chris Lattner 6f6d226f63 improve error to be something end users will actually understand :)
llvm-svn: 49097
2008-04-02 17:15:17 +00:00
Dale Johannesen 8780ecbbac Cosmetic changes per EH patch review feedback.
llvm-svn: 49096
2008-04-02 17:04:45 +00:00
Ted Kremenek 018ba60f8e Added path-sensitive null dereference test case.
llvm-svn: 49095
2008-04-02 16:54:39 +00:00
Ted Kremenek 3016cdd569 More wording cleanups in --help text.
llvm-svn: 49094
2008-04-02 16:47:27 +00:00
Ted Kremenek dfd204e133 More wording fixes.
llvm-svn: 49093
2008-04-02 16:41:25 +00:00
Ted Kremenek 1cf35de3cb Added error message for unrecognized options.
llvm-svn: 49092
2008-04-02 16:35:01 +00:00
Ted Kremenek c5f113f52e Wording cleanups.
llvm-svn: 49091
2008-04-02 16:31:58 +00:00
Ted Kremenek 977b644427 Implemented "-k" support.
llvm-svn: 49090
2008-04-02 16:04:51 +00:00
Ted Kremenek 37e908a6f0 Do equality testing, not regex, when the build command is gcc. This matches
better with what compiler invocations that ccc-analyzer actually intercepts.

Fixes suggested by Sam Bishop!

llvm-svn: 49089
2008-04-02 15:34:12 +00:00
Torok Edwin 21b8bed571 Add new file Support/DataFlow.h.
It allows Use-Def and Def-Use relations to be treated as graphs.

llvm-svn: 49088
2008-04-02 14:57:52 +00:00