Chris Lattner
a66222366e
add some comments.
...
llvm-svn: 48053
2008-03-08 09:00:55 +00:00
Chris Lattner
1df278669d
make float format handling more regular.
...
llvm-svn: 48052
2008-03-08 08:59:43 +00:00
Chris Lattner
7570e9c518
simplify all the type info accessors in TargeTInfo to return scalars,
...
which is simpler to use and provide.
llvm-svn: 48051
2008-03-08 08:52:55 +00:00
Chris Lattner
2dca6ff505
Fix a fixme by allowing pointers in different address spaces to have
...
different widths. Start simplifying TargetInfo accessor methods.
llvm-svn: 48050
2008-03-08 08:34:58 +00:00
Chris Lattner
c3a669ba63
eliminate the TargetInfoImpl stuff, simplifying the target implementations.
...
llvm-svn: 48049
2008-03-08 08:24:01 +00:00
Chris Lattner
a0c0c35190
eliminate ComputeWCharInfo.
...
llvm-svn: 48048
2008-03-08 08:07:34 +00:00
Ted Kremenek
0440494b66
Increased worklist limit for GRSimpleVals.
...
llvm-svn: 48037
2008-03-07 22:59:32 +00:00
Ted Kremenek
2bdd77696e
Added --trim-path-graph to the driver to trim paths from the ExplodedGraph
...
that are not related to error nodes.
Fixed bug where we did not detect some NULL dereferences.
Added "ExplodedGraph::Trim" to trim all nodes that cannot transitively reach
a set of provided nodes.
Fixed subtle bug in ExplodedNodeImpl where we could create predecessor
iterators that included the mangled "sink" bit. The better fix is to integrate
this bit into the void* for the wrapped State, not the NodeGroups representing
a node's predecessors and successors.
llvm-svn: 48036
2008-03-07 22:58:01 +00:00
Ted Kremenek
6947a79d6b
Improved graph visualization of ExplodedGraphs to include source line and column
...
information.
llvm-svn: 48031
2008-03-07 20:57:30 +00:00
Ted Kremenek
910e9de131
Renamed ValueManager to BasicValueFactory.
...
llvm-svn: 48025
2008-03-07 20:13:31 +00:00
Nate Begeman
be6bb8efac
Add new test
...
llvm-svn: 48018
2008-03-07 20:04:49 +00:00
Nate Begeman
0a6192cfb8
Add fastcall/stdcall attribute support
...
Generate CallingConv::Fast when fastcall attribute is present
llvm-svn: 48017
2008-03-07 20:04:22 +00:00
Ted Kremenek
40bc74fde7
Refined divide-by-zero checking to distinguish between must and may
...
divide-by-zero errors.
llvm-svn: 48013
2008-03-07 19:04:53 +00:00
Ted Kremenek
7bdd630334
Patch by Nuno Lopes:
...
Added more comments for code processing attribute "format".
Added more checks for corner cases, test cases, and warnings.
llvm-svn: 48011
2008-03-07 18:43:49 +00:00
Gabor Greif
3a8edd8536
fix typos
...
llvm-svn: 47995
2008-03-06 10:40:09 +00:00
Ted Kremenek
f458289484
Fixed mismatched deallocation in GRBlockCounter::Factory::~Factory.
...
Reported by Zhongxing Xu!
llvm-svn: 47991
2008-03-06 08:09:22 +00:00
Chris Lattner
54ee63886e
remove two obsolete tests, not sure why my previous commit didn't commit the removal.
...
llvm-svn: 47986
2008-03-06 05:47:17 +00:00
Ted Kremenek
ea6507fe04
Added boilerplate to execute the CF reference count checker (which isn't yet implemented).
...
llvm-svn: 47982
2008-03-06 00:08:09 +00:00
Ted Kremenek
82d506de29
Added "CheckerState" field to ValueState.
...
llvm-svn: 47979
2008-03-05 23:32:23 +00:00
Ted Kremenek
4c38955dab
Added transfer function support for __builtin_expect.
...
llvm-svn: 47971
2008-03-05 22:59:42 +00:00
Ted Kremenek
9743b3913f
Small bug fix when handling CallExprs that generate sink nodes.
...
llvm-svn: 47970
2008-03-05 22:49:16 +00:00
Steve Naroff
93bcc7a6d2
Update vcproj files.
...
llvm-svn: 47967
2008-03-05 22:16:33 +00:00
Ted Kremenek
7034236366
Fixed bug that could case unwanted bifurcation of states when evaluating calls.
...
llvm-svn: 47964
2008-03-05 21:15:02 +00:00
Ted Kremenek
0c04606d1f
Fixed bogus assumption mistakenly introduced in r47955.
...
llvm-svn: 47958
2008-03-05 19:26:46 +00:00
Ted Kremenek
c156f1ffc6
Fixed a horribly insidious bit-masking bug in the implementation of
...
ExplodedNode that would occasionally result in heap corruption.
llvm-svn: 47956
2008-03-05 19:08:55 +00:00
Ted Kremenek
df4a5b9047
Minor cleanups (mainly indentation).
...
llvm-svn: 47955
2008-03-05 19:08:15 +00:00
Chris Lattner
37e0587839
remove the source location arguments to various target query methods.
...
llvm-svn: 47954
2008-03-05 18:54:05 +00:00
Chris Lattner
ae3429f5f1
add analysis source files to project.
...
llvm-svn: 47953
2008-03-05 18:22:36 +00:00
Chris Lattner
0e26639bb4
Add the various pathsensitive headers to the project.
...
llvm-svn: 47952
2008-03-05 18:20:02 +00:00
Chris Lattner
4cb0b08be7
ProgramEdge.h doesn't exist anymore.
...
llvm-svn: 47951
2008-03-05 18:18:31 +00:00
Ted Kremenek
7ae17203f8
Reverted patch 47926 for ProgramPoint.h because it is currently buggy. May add back (fixed) later.
...
Updated CFGStmtVisitor to be in accord with rr47913: CallExprs are no longer (automatically) block-level expressions in the CFG.
llvm-svn: 47935
2008-03-05 05:05:04 +00:00
Chris Lattner
855d024a83
Remove the first layer of support for "portability" warnings. This is
...
theoretically useful, but not useful in practice. It adds a bunch of
complexity, and not much value. It's best to nuke it. One big advantage
is that it means the target interfaces will soon lose their SLoc arguments
and target queries can never emit diagnostics anymore (yay). Removing this
also simplifies some of the core preprocessor which should make it slightly
faster.
Ted, I didn't simplify TripleProcessor, which can now have at most one
triple, and can probably just be removed. Please poke at it when you have
time.
llvm-svn: 47930
2008-03-05 01:18:20 +00:00
Ted Kremenek
f9c67f6056
Added support for ProgramPoints to represent ExplodedNodes in another
...
ExplodedGraph. This allows us to build "layered" ExplodedGraphs where one
simulation is layered on another.
llvm-svn: 47926
2008-03-05 00:59:43 +00:00
Chris Lattner
43c103ab1b
move this into the right file.
...
llvm-svn: 47925
2008-03-05 00:53:34 +00:00
Ted Kremenek
d5804b31c4
Plug-in transfer function "EvalCall" now takes as an argument the current
...
GRStmtNodeBuilder and is now responsible for adding its own nodes to the graph.
llvm-svn: 47923
2008-03-05 00:33:14 +00:00
Ted Kremenek
31672dbda3
Cleaned up typedefs involving StateTy so that we always use "StateTy*" instead of StateTy.
...
This is conceptually much cleaner, as it shows that the state is always a pointer.
It also makes it easier to marshall these values around across the internal APIs
of the path-sensitive engine.
llvm-svn: 47921
2008-03-05 00:11:33 +00:00
Ted Kremenek
c3c8c5762f
Make GRStmtNodeBuilder only depend on StateTy, and not the type definition
...
of the entire checker.
llvm-svn: 47920
2008-03-04 23:50:00 +00:00
Ted Kremenek
a81c9de767
Moved implementation of GRExprEngine::Nodify into GRStmtNodeBuilder. This will
...
allow us to pass the builder to plug-in transfer functions and allow those
functions to create intermediate nodes.
llvm-svn: 47919
2008-03-04 23:39:43 +00:00
Ted Kremenek
3a3f6e3946
Moved GRExprEngine::NodeSet out of GRExprEngine and made it a standalone class: ExplodedNodeSet.
...
Made GRExprEngine::NodeSet a typedef of ExplodedNodeSet.
llvm-svn: 47914
2008-03-04 23:13:06 +00:00
Ted Kremenek
c76a83f1b6
CallExprs are now no longer block-level expressions in the CFG by construction.
...
llvm-svn: 47913
2008-03-04 22:29:40 +00:00
Ted Kremenek
9f3f827e65
Added preliminary transfer function support for references.
...
llvm-svn: 47912
2008-03-04 22:16:08 +00:00
Ted Kremenek
7aedc47285
For the transfer function for CallExpr, invalidate all arguments
...
passed-by-reference to builtin functions until we have better builtin support.
llvm-svn: 47910
2008-03-04 22:01:56 +00:00
Anders Carlsson
c83008a281
Make intrinsics always_inline.
...
llvm-svn: 47902
2008-03-04 21:11:29 +00:00
Ted Kremenek
229f6773bb
For the transfer function of DeclStmt, for now initialize the values of
...
structs (local variables) to Unknown instead of Undefined. (added FIXME to initialize *members* of struct to undefined)
llvm-svn: 47901
2008-03-04 20:40:11 +00:00
Ted Kremenek
e26c37d37d
Fixed another obscure node-caching bug.
...
llvm-svn: 47898
2008-03-04 19:52:15 +00:00
Ted Kremenek
122a529ab4
Implemented "print" method for ValueState.
...
llvm-svn: 47894
2008-03-04 18:30:35 +00:00
Chris Lattner
0fdc379475
The operand to the visibility attribute is required to be a quoted string, not a bare identifier.
...
llvm-svn: 47893
2008-03-04 18:08:48 +00:00
Ted Kremenek
c490bdbdb1
TargetInfo objects now own the TargetInfoImpl objects they refer to.
...
TargetInfo::AddSecondaryTarget is now private, as it is only used during
object construction.
llvm-svn: 47891
2008-03-04 17:47:18 +00:00
Ted Kremenek
b9832d3cb4
Add transfer function support for the default initialization of static
...
variables that are pointers or integers.
llvm-svn: 47880
2008-03-04 04:18:04 +00:00
Ted Kremenek
2a30ea6269
Fixed insidious state propagation bug that would sometimes cause the state
...
to bifurcate at the wrong places and not propagate at others.
llvm-svn: 47876
2008-03-04 00:56:45 +00:00