Ted Kremenek
80ff44ff30
Moved implementation of "RemoveDeadBindings" from the main
...
GRConstants logic to ValueStateManager.
llvm-svn: 46888
2008-02-08 19:17:19 +00:00
Ted Kremenek
5d9073c776
Removed ability to create symbol bindings
...
in VarKey and VariableBindingsTy.
llvm-svn: 46887
2008-02-08 19:08:13 +00:00
Steve Naroff
8c099c3f03
Use getLogicalLineNumber() in FuzzyParseMicrosoftAsmStatement(), it's more general and simplifies the code.
...
llvm-svn: 46885
2008-02-08 18:01:27 +00:00
Ted Kremenek
09d6ba1496
Moved that clang doesn't depend on llvm-gcc above
...
the subsection of building clang with llvm.
llvm-svn: 46884
2008-02-08 07:32:26 +00:00
Ted Kremenek
fd39e73b7a
Implemented transfer functions for "<<" and ">>" when the RValues are
...
ConcreteInts.
llvm-svn: 46883
2008-02-08 07:14:58 +00:00
Ted Kremenek
6beacb1e14
Constified operator<< in APSInt.
...
llvm-svn: 46882
2008-02-08 07:14:19 +00:00
Eric Christopher
6aa87cbb63
Add instructions for building clang while building llvm.
...
llvm-svn: 46881
2008-02-08 07:10:48 +00:00
Ted Kremenek
707b07ccf9
Implemented transfer functions for Statement-Expressions and Commas.
...
Fixed bug in dispatching to the correct transfer function for |=, &=, and ^|.
llvm-svn: 46880
2008-02-08 07:05:39 +00:00
Eric Christopher
2dc30a5ac8
De-^Mify file.
...
llvm-svn: 46879
2008-02-08 06:45:49 +00:00
Steve Naroff
db5f7d7699
Support fuzzy parsing MS line-oriented __asm's that originate from a macro (a case where we can't obtain source line info). As the test case indicates, we don't currently support line-oriented asm statements that mix file/macro body tokens.
...
llvm-svn: 46878
2008-02-08 03:36:19 +00:00
Dan Gohman
7a55a94ba1
Avoid needlessly casting away const qualifiers.
...
llvm-svn: 46877
2008-02-08 03:29:40 +00:00
Dan Gohman
140a73efac
Avoid needlessly casting away const qualifiers.
...
llvm-svn: 46876
2008-02-08 03:26:46 +00:00
Ted Kremenek
fd641f1056
More variable renamings.
...
llvm-svn: 46875
2008-02-08 03:02:48 +00:00
Ted Kremenek
173743da67
Renamed InvalidValue to UnknownVal.
...
Renamed UninitializedValue to UninitializedVal.
llvm-svn: 46874
2008-02-08 02:57:34 +00:00
Eli Friedman
113eed5cff
Fix indentation.
...
llvm-svn: 46873
2008-02-08 01:24:30 +00:00
Eli Friedman
1974e5321a
Detabify SemaExpr. My text editor defaults to 8 spaces per tab, so it
...
gets kind of annoying.
llvm-svn: 46872
2008-02-08 01:19:44 +00:00
Eli Friedman
4297826cac
Improve diagnostic for illegal array initialization.
...
llvm-svn: 46869
2008-02-08 00:48:24 +00:00
Anders Carlsson
5c6c05956e
Put back the top-level asm code; all tests pass now.
...
llvm-svn: 46868
2008-02-08 00:33:21 +00:00
Anders Carlsson
0fae4f56df
Back out 46855 for now, it causes test failures on Darwin.
...
llvm-svn: 46867
2008-02-08 00:23:11 +00:00
Evan Cheng
8d59dd119b
Added missing entries in X86 load / store folding tables.
...
llvm-svn: 46866
2008-02-08 00:12:56 +00:00
Steve Naroff
4e79d340bd
- Add support for fuzzy parsing line-oriented __asm's (yuck).
...
- Change handling of __w64 to a built-in macro.
llvm-svn: 46864
2008-02-07 23:24:32 +00:00
Devang Patel
eef348687e
Begin setting features for target based on target triple string.
...
llvm-svn: 46863
2008-02-07 22:32:50 +00:00
Evan Cheng
6a80462568
Remove remnant of load folding in local register allocator. Patch by Holger Schurig.
...
llvm-svn: 46861
2008-02-07 19:46:55 +00:00
Lauro Ramos Venancio
9eff02d9f8
Simplify bitfield codegen.
...
Fix codegen of struct { short a[3]; int b:15; }.
llvm-svn: 46859
2008-02-07 19:29:53 +00:00
Dan Gohman
16d4bc3dc0
Follow Chris' suggestion; change the PseudoSourceValue accessors
...
to return pointers instead of references, since this is always what
is needed.
llvm-svn: 46857
2008-02-07 18:41:25 +00:00
Lauro Ramos Venancio
0f166de892
Fix codegen of
...
struct {
char a[3];
unsigned char b:1;
};
Fix PR1990.
llvm-svn: 46856
2008-02-07 18:18:58 +00:00
Anders Carlsson
bcc3a4bf64
Handle top-level asm declarations.
...
llvm-svn: 46855
2008-02-07 17:19:11 +00:00
Dan Gohman
63a8452e9c
Add SourceValue information for outgoing argument stores on x86.
...
llvm-svn: 46854
2008-02-07 16:28:05 +00:00
Dan Gohman
b781c79d2c
Don't abort if a MemOperand is missing a SourceValue; just print it
...
as <unknown>. And make some minor adjustments to the MemOperand
dump format.
llvm-svn: 46853
2008-02-07 16:18:00 +00:00
Steve Naroff
6936a08704
Minor cleanup from yesterday's -fms-extension commit. Move __int* MS keywords to predefined macros. This removes some of the MS-madness from Parser::ParseDeclarationSpecifiers().
...
llvm-svn: 46852
2008-02-07 15:26:07 +00:00
Ted Kremenek
e187d0511f
Added some more opcode pretty-printing.
...
Minor cleanups with generating nodes for NULL-pointer dereferences.
llvm-svn: 46851
2008-02-07 15:20:13 +00:00
Evan Cheng
a20a773654
Fix a x86-64 codegen deficiency. Allow gv + offset when using rip addressing mode.
...
Before:
_main:
subq $8, %rsp
leaq _X(%rip), %rax
movsd 8(%rax), %xmm1
movss _X(%rip), %xmm0
call _t
xorl %ecx, %ecx
movl %ecx, %eax
addq $8, %rsp
ret
Now:
_main:
subq $8, %rsp
movsd _X+8(%rip), %xmm1
movss _X(%rip), %xmm0
call _t
xorl %ecx, %ecx
movl %ecx, %eax
addq $8, %rsp
ret
Notice there is another idiotic codegen issue that needs to be fixed asap:
xorl %ecx, %ecx
movl %ecx, %eax
llvm-svn: 46850
2008-02-07 08:53:49 +00:00
Evan Cheng
1bc1cae318
In some cases, e.g. ADD32ri, no transformation is made. Guide against it.
...
llvm-svn: 46849
2008-02-07 08:29:53 +00:00
Nick Lewycky
7c1d787977
Don't make up new directives. (".set_foobar")
...
llvm-svn: 46848
2008-02-07 06:36:26 +00:00
Ted Kremenek
d74da0838f
Added proof-of-concept NULL pointer diagnostics to GRConstants.
...
Modified the driver to pass the Diagnostic object to GRConstants.
llvm-svn: 46847
2008-02-07 06:33:19 +00:00
Ted Kremenek
149512c013
Added support to distinguish between both implicit and explicit null dereferences.
...
llvm-svn: 46846
2008-02-07 06:04:18 +00:00
Chris Lattner
3b5054dda0
Implement support for the extremely atrocious MS /##/ extension,
...
which pastes together a comment. This is only enabled with
-fms-extensions of course.
llvm-svn: 46845
2008-02-07 06:03:59 +00:00
Chris Lattner
f96e8d0925
these aren't tokens.
...
llvm-svn: 46844
2008-02-07 05:57:50 +00:00
Ted Kremenek
e324704e62
Added recording of "implicit" NULL dereferences of symbolic pointers.
...
llvm-svn: 46843
2008-02-07 05:48:01 +00:00
Eli Friedman
69d56cff31
Add a FIXME for alternate address spaces.
...
llvm-svn: 46841
2008-02-07 05:24:51 +00:00
Chris Lattner
6bd4c7f94f
get the tree building again
...
llvm-svn: 46840
2008-02-07 05:01:42 +00:00
Ted Kremenek
88da1de048
Added several guards in transfer functions for "InvalidValues".
...
Fixed bug in RemoveDeadBindings by implementing a simple "mark-and-sweep"
cleaner over the bindings, starting from the Decls and block-level expressions
that are considered "live" by the Liveness analysis.
Fixed bug in isa<> implementation for class LValue.
Added "VisitDeclRefExpr" to GRConstants so that we explicitly bind the current
value of variable to the Block-level Expression (i.e., when the DeclRefExpr is
at the CFGBlock level).
llvm-svn: 46839
2008-02-07 04:16:04 +00:00
Steve Naroff
b2c80c7c7b
Implement -fms-extensions. This allows us to fuzzy parse non-standard MS constructs used in "windows.h".
...
llvm-svn: 46838
2008-02-07 03:50:06 +00:00
Ted Kremenek
a56c08a2e4
Fixed bug in LiveVariables analysis where Block-level exprs appearing
...
as the initializers for DeclStmts were not being registered as being
live at the start of the DeclStmt.
llvm-svn: 46837
2008-02-07 02:38:55 +00:00
Dan Gohman
b3efe03672
Fix a typo in a comment.
...
llvm-svn: 46836
2008-02-07 02:30:40 +00:00
Ted Kremenek
43523e0fe8
Added transfer function logic for ReturnStmts.
...
Fixed insidious bug in handling dereferences.
llvm-svn: 46835
2008-02-07 01:08:27 +00:00
Dan Gohman
4f26eb7270
Add support to FoldingSet for hashing APInt objects.
...
llvm-svn: 46833
2008-02-06 23:09:15 +00:00
Ted Kremenek
4aa77cee11
Minor reordering of the serialization of the fields of MemberExpr to result
...
in a smaller encoding on disk.
llvm-svn: 46832
2008-02-06 23:03:14 +00:00
Ted Kremenek
cdd0be1dc1
Major code refactoring/cleanup with transfer function logic. Now the
...
code structure is more suitable for additional symbolic analysis.
llvm-svn: 46831
2008-02-06 22:50:25 +00:00
Eli Friedman
1242fff6ec
Make sure to propagate qualifiers through the member operator.
...
llvm-svn: 46830
2008-02-06 22:48:16 +00:00