Ted Kremenek
7686ffaf07
retain/release checker: Refactor the guts of getClassMethodSummary to not depend
...
on ObjCMessageExpr. This will enable us to use it elsewhere. This should not
change any functionality.
llvm-svn: 70352
2009-04-29 00:42:39 +00:00
Evan Cheng
cfb4cae201
Determine allocation 'preference' with right register class. I haven't seen this changing codegen so no test case.
...
llvm-svn: 70351
2009-04-29 00:42:27 +00:00
Ted Kremenek
ebc6d91f4e
Add regression test case provided by <rdar://problem/6833332>.
...
llvm-svn: 70350
2009-04-29 00:41:31 +00:00
Bill Wendling
9f795134f3
The second part of the change from -fast to -O#. This changes the JIT to accept
...
an optimization level instead of a simple boolean telling it to generate code
"fast" or the other type of "fast".
llvm-svn: 70347
2009-04-29 00:32:19 +00:00
Bill Wendling
084669a1c9
Second attempt:
...
Massive check in. This changes the "-fast" flag to "-O#" in llc. If you want to
use the old behavior, the flag is -O0. This change allows for finer-grained
control over which optimizations are run at different -O levels.
Most of this work was pretty mechanical. The majority of the fixes came from
verifying that a "fast" variable wasn't used anymore. The JIT still uses a
"Fast" flag. I'll change the JIT with a follow-up patch.
llvm-svn: 70343
2009-04-29 00:15:41 +00:00
Bill Wendling
d4eb842404
Correct comment.
...
llvm-svn: 70340
2009-04-29 00:09:22 +00:00
Douglas Gregor
272842aa1c
Enable PCH by default
...
llvm-svn: 70339
2009-04-28 22:44:02 +00:00
Douglas Gregor
c1547eb338
Force driver's PTH test to use PTH
...
llvm-svn: 70338
2009-04-28 22:43:20 +00:00
Chris Lattner
af6094eafc
In -fdiagnostics-print-source-range-info mode, print a space before the
...
lines that clang extracts from the source code so that machine parsing can
easily ignore them.
llvm-svn: 70337
2009-04-28 22:33:16 +00:00
Ted Kremenek
869292d5b6
Implement ownership attribute 'objc_ownership_make_collectable'. This allows one
...
to add 'CFMakeCollectable' semantics to a method.
llvm-svn: 70336
2009-04-28 22:32:26 +00:00
Chris Lattner
865efd72b3
add support for -Wendif-labels, PR4101
...
llvm-svn: 70335
2009-04-28 22:19:16 +00:00
Dan Gohman
ed7f3a0eec
As with r70333, give the primary induction variable a use so
...
that it can't be trivially eliminated.
llvm-svn: 70334
2009-04-28 22:05:13 +00:00
Dan Gohman
2625f2cb80
Make this testcase slightly less trivial, so that it doesn't fail
...
if indvars happens to optimize away the unused primary induction
variable.
llvm-svn: 70333
2009-04-28 22:03:26 +00:00
Douglas Gregor
ce1a9c5a6b
Make all PCH-incompatibility warnings into errors, and abort
...
compilation if the user requested a PCH file but no such PCH file
exists.
llvm-svn: 70332
2009-04-28 22:01:16 +00:00
Dan Gohman
807dff7486
Fix a grammaro in a comment.
...
llvm-svn: 70331
2009-04-28 21:54:23 +00:00
Douglas Gregor
6f00bf8ceb
Make the PCH reader use the diagnostics system for its complaints.
...
llvm-svn: 70330
2009-04-28 21:53:25 +00:00
Chris Lattner
8577f62622
Implement -Wfour-char-constants, which is an extension, not an extwarn,
...
and apparently not part of -Wall
llvm-svn: 70329
2009-04-28 21:51:46 +00:00
Anton Korobeynikov
dac88bae4f
Properly print 'P' modifier on inline asm memory operands.
...
This should fix PR3379 and PR4064.
Patch inspired by Edwin Török!
llvm-svn: 70328
2009-04-28 21:49:33 +00:00
Ted Kremenek
89c3861061
Improve retain/release test cases for ownership attributes.
...
llvm-svn: 70327
2009-04-28 21:43:40 +00:00
Douglas Gregor
b925652433
Optimize IdentifierInfo storage within the precompiled header. We've
...
now gotten back about 180k of the 500k we lost.
llvm-svn: 70326
2009-04-28 21:32:13 +00:00
Douglas Gregor
1d583f2838
Implement a minor space optimization for the PCH identifier table,
...
which eliminates the storage for IdentifierInfo in the "uninteresting
identifier" cases. Sadly, this only brought back 7k of the 500k we
lost :(
llvm-svn: 70325
2009-04-28 21:18:29 +00:00
Douglas Gregor
cd07dd168d
Fix a typo noticed by Gabor
...
llvm-svn: 70323
2009-04-28 21:06:13 +00:00
Douglas Gregor
1a949368e4
Replace a lame fprintf with a slightly-less lame diagnostic
...
llvm-svn: 70322
2009-04-28 20:36:16 +00:00
Douglas Gregor
e6648fb79e
Implement checking for macro definitions that occur on the command
...
line when using a PCH that were not provided when building the PCH
file. If those names were used as identifiers somewhere in the PCH
file, reject the PCH file.
llvm-svn: 70321
2009-04-28 20:33:11 +00:00
Douglas Gregor
ab4df58193
Revert r70075 and r70078, which reorganized the PCH on-disk hash table
...
for identifiers to separate "interesting" from "uninteresting"
identifiers. However, to cope with compiler invocations where the
predefines buffers mismatch, we need to be able to search the complete
identifier table. Cocoa.h.pch is now about 500k larger that it used to
be :(
llvm-svn: 70320
2009-04-28 20:01:51 +00:00
Bob Wilson
3d948164f7
Fix trailing whitespace and 80-col. violations in recent TableGen changes.
...
llvm-svn: 70319
2009-04-28 19:41:44 +00:00
Daniel Dunbar
fb83baaf76
With -ccc-pch-is-pch, always treat precompiled inputs as PCH,
...
regardless of extension.
- Otherwise we can't expect that just plugging in -ccc-pch-is-pch
will work.
llvm-svn: 70318
2009-04-28 19:38:45 +00:00
Eli Friedman
a38da57cd6
PR4097: add logic to Evaluate to handle pointer equality comparisons.
...
llvm-svn: 70317
2009-04-28 19:17:36 +00:00
Douglas Gregor
c379c07240
Allow some differences between the predefines buffer used to build a
...
PCH file and the predefines buffer used when including the PCH
file. We (explicitly) detect conflicting macro definitions (rejecting
the PCH file) and about missing macro definitions (they'll be
automatically pulled from the PCH file anyway).
We're missing some checking to make sure that new macro definitions
won't have any impact on the PCH file itself (e.g., #define'ing an
identifier that the PCH file used).
llvm-svn: 70316
2009-04-28 18:58:38 +00:00
Chris Lattner
74c95e20af
implement -Wmultichar
...
llvm-svn: 70315
2009-04-28 18:52:02 +00:00
Eli Friedman
5406f5430b
Add some text to the user manual describing the current state of C
...
support in clang.
llvm-svn: 70314
2009-04-28 18:48:34 +00:00
Ted Kremenek
ea62bf4e58
Revert 70293.
...
llvm-svn: 70313
2009-04-28 18:48:13 +00:00
Chris Lattner
0cd56890ef
merge number.c into constants.c and start running it in -verify mode.
...
llvm-svn: 70310
2009-04-28 18:43:12 +00:00
Evan Cheng
e0eb5483d1
Move getMatchingSuperReg() out of coalescer and into TargetRegisterInfo.
...
llvm-svn: 70309
2009-04-28 18:29:27 +00:00
Eli Friedman
4058a842e6
Fix a minor edge case in C89 mode related to the definition of a
...
"function designator".
(This causes a minor glitch in the
diagnostics for C++ member pointers, but we weren't printing the
right diagnostic there anyway.)
llvm-svn: 70307
2009-04-28 17:59:09 +00:00
Eli Friedman
9f1d66419d
Fix additional issues pointed out in PR4088.
...
llvm-svn: 70305
2009-04-28 17:48:05 +00:00
Ted Kremenek
ce6b865c21
ccc-analyzer: Don't automatically generate 'Parser Rejects' files anymore. The
...
frontend is far enough along that most discrepancies between Clang and GCC are
(at least for C and Objective-C) are intentional. We also now have codegen to
test the frontend.
llvm-svn: 70303
2009-04-28 17:37:44 +00:00
Dale Johannesen
25148e11fb
Test for llvm-gcc bug fixed by 70301.
...
llvm-svn: 70302
2009-04-28 17:16:30 +00:00
Sanjiv Gupta
7bfed8a9f4
GlobalValue is always pointer type, so an assert isn't required.
...
llvm-svn: 70300
2009-04-28 16:39:45 +00:00
Stefanus Du Toit
d2b7be6e9b
Fix choice of version of Windows callback to use to consider not only the Visual Studio version, but also the Windows SDK version.
...
Patch by Tareq Siraj.
llvm-svn: 70299
2009-04-28 16:37:58 +00:00
Jakob Stoklund Olesen
fb9e23b217
Don't coalesce a physical register with an incompatible virtual register.
...
If the physical register does not belong to the virtual register's regclass,
don't coalesce. The physical register could be an invalid operand for an
instruction using the vreg.
The regclass matching is done after determining the actual subregisters being copied.
llvm-svn: 70298
2009-04-28 16:34:35 +00:00
Sanjiv Gupta
99b1b27dc2
Initialized arrays can be in any address space.
...
llvm-svn: 70297
2009-04-28 16:34:20 +00:00
Jakob Stoklund Olesen
604248e81f
Move getSubRegisterRegClass from ScheduleDagSDNodesEmit.cpp to a TargetRegisterClass method.
...
Also make the method non-asserting. It will return NULL when given an invalid subreg index.
The method is needed by an upcoming patch.
llvm-svn: 70296
2009-04-28 16:34:09 +00:00
Ted Kremenek
ed70968484
Update analyzer build.
...
llvm-svn: 70295
2009-04-28 14:32:50 +00:00
Zhongxing Xu
3c3fee0fb8
Add test case.
...
llvm-svn: 70294
2009-04-28 13:52:13 +00:00
Zhongxing Xu
6e304e6323
Now we can remove the 'blast-through' code.
...
llvm-svn: 70293
2009-04-28 13:49:42 +00:00
Douglas Gregor
76fe50c654
Improve compatibility with GCC regarding inline semantics in GNU89
...
mode and in the presence of __gnu_inline__ attributes. This should fix
both PR3989 and PR4069.
As part of this, we now keep track of all of the attributes attached
to each declaration even after we've performed declaration
merging. This fixes PR3264.
llvm-svn: 70292
2009-04-28 06:37:30 +00:00
Evan Cheng
7e09994cb8
Fix PR4034. Bug in LiveInterval::join when it's compacting new valno's.
...
llvm-svn: 70291
2009-04-28 06:24:09 +00:00
Jakob Stoklund Olesen
f4e74fe62f
Initial test commit
...
llvm-svn: 70290
2009-04-28 06:15:00 +00:00
Ted Kremenek
9bea0dc178
Extensive diagnostics: Do not add a location context for do...while statements.
...
llvm-svn: 70286
2009-04-28 04:28:12 +00:00