Anders Carlsson
e73e3ecc04
Initialize the cleanup.dst variable if necessary. Fixes PR3789.
...
llvm-svn: 67075
2009-03-17 05:53:35 +00:00
Devang Patel
bd93351c42
Fix struct field's debug info.
...
llvm-svn: 67062
2009-03-16 23:47:53 +00:00
Sebastian Redl
0f8b23f71f
Almost complete implementation of rvalue references. One bug, and a few unclear areas. Maybe Doug can shed some light on some of the fixmes.
...
llvm-svn: 67059
2009-03-16 23:22:08 +00:00
Douglas Gregor
23d75bb326
Build system changes to use TableGen to generate the various
...
diagnostics. This builds on the patch that Sebastian committed and
then revert. Major differences are:
- We don't remove or use the current ".def" files. Instead, for now,
we just make sure that we're building the ".inc" files.
- Fixed CMake makefiles to run TableGen and build the ".inc" files
when needed. Tested with both the Xcode and Makefile generators
provided by CMake, so it should be solid.
- Fixed normal makefiles to handle out-of-source builds that involve
the ".inc" files.
I'll send a separate patch to the list with Sebastian's changes that
eliminate the use of the .def files.
llvm-svn: 67058
2009-03-16 23:06:59 +00:00
Daniel Dunbar
27a08fab6b
Add note on theoretical IRgen improvement.
...
llvm-svn: 67024
2009-03-15 06:39:56 +00:00
Daniel Dunbar
64895a0703
Remove a FIXME.
...
llvm-svn: 67022
2009-03-15 06:05:20 +00:00
Mike Stump
5469f29aa9
Do up codegen for function static data and externs in functions in block
...
literals.
llvm-svn: 66984
2009-03-13 23:34:28 +00:00
Fariborz Jahanian
b03d5a6b36
Fix a bug in building function pointer type
...
corresponding to block pointer.
llvm-svn: 66940
2009-03-13 20:36:41 +00:00
Mike Stump
f807ccc58e
Remove FIXME, issue has been resolved.
...
llvm-svn: 66931
2009-03-13 19:38:54 +00:00
Chris Lattner
cda4d7e196
introduce a new -fheinous-gnu-extensions flag that enables really
...
really horrible extensions that are disabled by default but that can
be accepted by -fheinous-gnu-extensions (but which always emit a
warning when enabled).
As our first instance of this, implement PR3788/PR3794, which allows
non-lvalues in inline asms in contexts where lvalues are required. bleh.
llvm-svn: 66910
2009-03-13 17:38:01 +00:00
Steve Naroff
c4b30e596c
Fix <rdar://problem/6675489> BlockDecl should not use llvm::smallvector.
...
Also changed BlockDecl API to be more consistent (wrt FunctionDecl).
llvm-svn: 66904
2009-03-13 16:56:44 +00:00
Fariborz Jahanian
1b074a3eb7
Fixed an ir-gen bug related to strong-cast generation of
...
source being a non-pointer.
llvm-svn: 66854
2009-03-13 00:42:52 +00:00
Fariborz Jahanian
1bf7288529
More objc2's ivar layout bitmap.
...
bitmap generation for basic ivars seem to
work now. This is work in progress.
llvm-svn: 66836
2009-03-12 22:50:49 +00:00
Daniel Dunbar
a61bb4d198
Fix uninitialized use in GetAddrOfGlobalBlock, reenable assert.
...
- Mike, please verify.
llvm-svn: 66762
2009-03-12 03:07:24 +00:00
Daniel Dunbar
8ce48d8c10
x86_32 ABI: Don't try and expand structures with bitfields.
...
- This is an ABI incompatiblity, but this is not likely to be a huge
deal in practice. For now we at least generate self consistent code
instead of crashing.
- <rdar://problem/6657601> x86-32 ABI: Bitfields in small structures
are not passed correctly
llvm-svn: 66713
2009-03-11 22:05:26 +00:00
Fariborz Jahanian
99bee42be2
Code refactoring. No change in functionality.
...
llvm-svn: 66710
2009-03-11 21:42:00 +00:00
Fariborz Jahanian
cbaf73cd26
More of objc2's ivar layout bitmap (Next: specific).
...
Work in progress.
llvm-svn: 66707
2009-03-11 20:59:05 +00:00
Duncan Sands
1918413137
Adjust for linkage name change.
...
llvm-svn: 66691
2009-03-11 20:15:27 +00:00
Duncan Sands
bdf086f7c0
Correct for change of this name in LLVM.
...
llvm-svn: 66652
2009-03-11 08:40:02 +00:00
Fariborz Jahanian
3b0f886c3f
More Next objc2's gc ivar layout bitmap work.
...
Work in progress.
llvm-svn: 66615
2009-03-11 00:07:04 +00:00
Chris Lattner
d8c7ba278e
add plumbing to report diagnostics back through sema for malformed asmstrings.
...
llvm-svn: 66598
2009-03-10 23:41:04 +00:00
Chris Lattner
35b5836147
move the asm string analysis code out of codegen into common
...
code where Sema can get to it. No functionality change.
llvm-svn: 66596
2009-03-10 23:21:44 +00:00
Devang Patel
c0f58ea60b
Emit super class debug info.
...
llvm-svn: 66580
2009-03-10 21:30:26 +00:00
Fariborz Jahanian
156506e749
ir-gen support for class getter/setter call
...
using property dot-syntax.
llvm-svn: 66556
2009-03-10 18:03:11 +00:00
Daniel Dunbar
4095d89532
Remove some now-unneeded calls to llvm::errs().flush().
...
llvm-svn: 66555
2009-03-10 18:00:19 +00:00
Anders Carlsson
0275115f66
Address Doug's comments wrt the mangler and fix Eli's test case
...
llvm-svn: 66549
2009-03-10 17:07:44 +00:00
Fariborz Jahanian
524bb20b4b
More objc2's gc meta-data work related to ivar layout bitmap.
...
Work in progress.
llvm-svn: 66546
2009-03-10 16:22:08 +00:00
Chris Lattner
f85a938985
Fix PR3682 by just disabling a broken assertion. This check should be
...
done in sema, and is reflected by the existing PR3258. In the meantime,
fix PR3682 by disabling a bogus assertion (which doesn't account for +
operands).
llvm-svn: 66533
2009-03-10 06:42:37 +00:00
Chris Lattner
6dd0f9263d
reduce duplication of parsing code between %0 and %x0 and
...
add support for modifiers on named references, like %c[foo].
llvm-svn: 66532
2009-03-10 06:38:02 +00:00
Chris Lattner
d7d5fdf090
move matching of named operands into AsmStmt class. At the same
...
time handle + operands in operand counting, fixing asm.c:t7 to
expand into $2 instead of $1.
llvm-svn: 66531
2009-03-10 06:33:24 +00:00
Chris Lattner
80337892f4
reduce nesting, use memchr instead of explicit loop, eliminate a
...
temporary std::string to fix a fixme.
llvm-svn: 66530
2009-03-10 06:11:34 +00:00
Chris Lattner
2d43eaefa2
Expand %= into ${:uid} so that the code generator emits a unique ID for the
...
asm. This allows us to properly handle the case when an optimizer duplicates
the asm, such as here:
void bar() {
int i;
for (i = 0; i < 3; ++i)
asm("foo %=" : : "r"(0));
}
we now produce:
_bar:
xorl %eax, %eax
## InlineAsm Start
foo 0
## InlineAsm End
## InlineAsm Start
foo 1
## InlineAsm End
## InlineAsm Start
foo 2
## InlineAsm End
ret
instead of:
_bar:
xorl %eax, %eax
## InlineAsm Start
foo 1
## InlineAsm End
## InlineAsm Start
foo 1
## InlineAsm End
## InlineAsm Start
foo 1
## InlineAsm End
ret
This also fixes a fixme by eliminating a static.
llvm-svn: 66528
2009-03-10 05:39:21 +00:00
Chris Lattner
72bbf17340
add some helper methods to AsmStmt and add some comments.
...
llvm-svn: 66521
2009-03-10 04:59:06 +00:00
Chris Lattner
57e673772e
slightly simplify some code, pull the 'is simple asm' case up in
...
ConvertAsmString and shrink it a bit. No functionality change.
llvm-svn: 66520
2009-03-10 04:38:46 +00:00
Daniel Dunbar
99d2835099
Backout r66408, we don't want handling of globals to rely on the
...
module symbol table. The root problem inspiring this was fixed in
r66316 (and again in r66506).
llvm-svn: 66512
2009-03-09 23:53:08 +00:00
Daniel Dunbar
ae3338429f
NeXT: Set alignment on a number of ObjC metadata variables (matching llvm-gcc).
...
llvm-svn: 66481
2009-03-09 22:18:41 +00:00
Daniel Dunbar
c2d4b62046
NeXT: Move some routines over to CreateMetadataVar.
...
- No intended functionality change.
llvm-svn: 66473
2009-03-09 21:49:58 +00:00
Daniel Dunbar
463cc8ade5
Tweak CreateMetadataVar, take the exact alignment instead of relying
...
on LLVM TargetData.
llvm-svn: 66455
2009-03-09 20:50:13 +00:00
Fariborz Jahanian
de2f33373b
More fix for bitfield ivar meta-data and code gen accessing it.
...
Now, we can actually execute dejagnu test with bitfield ivars
in non-fragile abi mode.
llvm-svn: 66448
2009-03-09 20:44:22 +00:00
Daniel Dunbar
91b000f771
Fix typo in pref commit.
...
llvm-svn: 66433
2009-03-09 20:16:39 +00:00
Daniel Dunbar
30c653655d
NeXT: Add CreateMetadataVar utility method to encapsulate creation of
...
Obj-C metadata variables (which generally should be handled the same,
although they aren't currently).
- No functionality change.
llvm-svn: 66432
2009-03-09 20:09:19 +00:00
Mike Stump
e3193ff452
Be sure to never create two functions with the same name, instead arrange to
...
reuse the prior one.
llvm-svn: 66408
2009-03-09 06:40:26 +00:00
Fariborz Jahanian
6772621acf
Code refactoring. No functional change.
...
llvm-svn: 66391
2009-03-08 20:18:37 +00:00
Anders Carlsson
4ed74dd6b7
Make mangling work with anonymous tag types. Doug, please review
...
llvm-svn: 66353
2009-03-07 23:57:03 +00:00
Anders Carlsson
16d5d291ec
Mangle Objective-C interfaces correctly (where correctly refers to what gcc does)
...
llvm-svn: 66349
2009-03-07 22:03:21 +00:00
Eli Friedman
4663a3368d
Make constant emission for @encode use the common string emission code.
...
This is a bit cleaner, and also "fixes" bad code that compares the
addresses of the string constants.
llvm-svn: 66346
2009-03-07 20:17:55 +00:00
Fariborz Jahanian
03676f557c
correct bitfield ivar offset in ivar meta-data.
...
(objc abi specific).
llvm-svn: 66345
2009-03-07 19:43:20 +00:00
Sanjiv Gupta
06cc45ec85
Mangle param names with .arg. only.
...
llvm-svn: 66343
2009-03-07 18:09:52 +00:00
Mike Stump
a6ca334389
Fixup our uses of various linkages to match how llvm now works. I think they are all
...
correct, but an extra set of ObjC eyes would be good.
llvm-svn: 66342
2009-03-07 16:33:28 +00:00
Mike Stump
de373a033f
If someone could figure out this is necessary, that would be good.
...
llvm-svn: 66341
2009-03-07 16:32:25 +00:00