Evan Cheng
ac90d47ea3
Post regalloc LICM. Work in progress.
...
llvm-svn: 100592
2010-04-07 00:41:17 +00:00
Devang Patel
bcab88162a
Do not emit specification DIE with DW_AT_specification attribute for member functions of a funcation local class. This trips gdb's partial scan of DIEs at load time. Fixes Radar 7833483.
...
llvm-svn: 100586
2010-04-06 23:53:48 +00:00
John McCall
e20cc3b28c
Fix a number of clang -Wsign-compare warnings that didn't have an obvious
...
solution. The only reason these don't fire with gcc-4.2 is that gcc turns off
part of -Wsign-compare in C++ on accident.
llvm-svn: 100581
2010-04-06 23:35:53 +00:00
Dale Johannesen
2a51b8abe5
Revert 100573, it's causing some testsuite problems.
...
llvm-svn: 100578
2010-04-06 22:45:26 +00:00
Dale Johannesen
fefeacda3b
Move printing of DEBUG_VALUE comments to target-independent place.
...
There is probably a more elegant way to do this.
llvm-svn: 100573
2010-04-06 22:21:07 +00:00
Dale Johannesen
fef6eb4076
Allow for the possibility that a debug-value points
...
to a SDNode that didn't have code generated for it.
llvm-svn: 100566
2010-04-06 21:59:56 +00:00
Stuart Hastings
4f6cdc07e9
Reverting 100530 & 100531 due to regressions in the GDB test suite.
...
llvm-svn: 100563
2010-04-06 21:38:29 +00:00
Evan Cheng
99617bac24
Code clean up. Move includes from VirtRegRewriter.h to VirtRegRewriter.cpp.
...
llvm-svn: 100532
2010-04-06 17:19:55 +00:00
Stuart Hastings
749cf45929
Revise debug info machinery to digest nested functions and classes.
...
A certain GDB testsuite case (local.cc) has a function nested inside a
class nested inside another function. GCC presents the innermost
function to llvm-convert first. Heretofore, the debug info mistakenly
placed the inner function at module scope. This patch walks the GCC
context links and instantiates the outer class and function so the
debug info is properly nested. Radar 7426545.
llvm-svn: 100530
2010-04-06 17:19:32 +00:00
Mon P Wang
c0da8af5c3
Remove assert to treat memmove and memset like memcpy
...
llvm-svn: 100521
2010-04-06 08:27:51 +00:00
Chris Lattner
960095d2c8
propagate cookie management out one layer of function calls.
...
llvm-svn: 100510
2010-04-06 00:58:50 +00:00
Chris Lattner
344a742ed1
report errors through LLVMContext's inline asm handler if available.
...
llvm-svn: 100509
2010-04-06 00:55:39 +00:00
Chris Lattner
8c1f45d90b
Give MachineModuleInfo an actual Module*.
...
llvm-svn: 100508
2010-04-06 00:51:52 +00:00
Devang Patel
5e0cb53223
Remove unnecessary include.
...
llvm-svn: 100505
2010-04-06 00:38:32 +00:00
Evan Cheng
c6dc63d62c
Fix an obvious copy-n-paste bug. It's not known to cause any miscompilation.
...
llvm-svn: 100494
2010-04-05 23:33:29 +00:00
Chris Lattner
f753452587
Give AsmParser an option to control whether it finalizes
...
the stream. New demo:
$ clang asm.c -S -o - -emit-llvm | llc -filetype=obj -o t.o
$ otool -tv t.o
t.o:
(__TEXT,__text) section
_foo:
0000000000000000 subq $0x08,%rsp
0000000000000004 movl %edi,(%rsp)
0000000000000007 movl %edi,%eax
0000000000000009 incl %eax
000000000000000b movl %eax,(%rsp)
000000000000000e movl %eax,0x04(%rsp)
0000000000000012 addq $0x08,%rsp
0000000000000016 ret
llvm-svn: 100492
2010-04-05 23:15:42 +00:00
Chris Lattner
5b4c7591ac
add .o file writing for inline asm in llc. Here's a silly
...
demo:
$ clang asm.c -S -o - -emit-llvm | llc -filetype=obj -o t.o
<inline asm>:1:2: error: unrecognized instruction
abc incl %eax
^
LLVM ERROR: Error parsing inline asm
Only problem seems to be that the parser finalizes OutStreamer
at the end of the first inline asm, which isn't what we want.
For example:
$ cat asm.c
int foo(int X) {
__asm__ ("incl %0" : "+r" (X));
return X;
}
$ clang asm.c -S -o - -emit-llvm | llc
...
subq $8, %rsp
movl %edi, (%rsp)
movl %edi, %eax
## InlineAsm Start
incl %eax
## InlineAsm End
movl %eax, (%rsp)
movl %eax, 4(%rsp)
addq $8, %rsp
ret
$ clang asm.c -S -o - -emit-llvm | llc -filetype=obj -o t.o
$ otool -tv t.o
t.o:
(__TEXT,__text) section
_foo:
0000000000000000 subq $0x08,%rsp
0000000000000004 movl %edi,(%rsp)
0000000000000007 movl %edi,%eax
0000000000000009 incl %eax
$
don't stop at inc!
llvm-svn: 100491
2010-04-05 23:11:24 +00:00
Bill Wendling
bf50ddf6ac
Output floating point representations in DWARF format. This is done by outputing
...
the FP encoding directly as a hex representation.
llvm-svn: 100487
2010-04-05 22:59:21 +00:00
Chris Lattner
269737461d
stringref-ize the MemoryBuffer::get apis. This requires
...
a co-committed clang patch.
llvm-svn: 100485
2010-04-05 22:42:30 +00:00
Dan Gohman
302746a632
Add a comment.
...
llvm-svn: 100459
2010-04-05 20:24:08 +00:00
Chris Lattner
7d609ea6cb
lowering a volatile llvm.memcpy to a libc memcpy is ok.
...
PR6779
llvm-svn: 100457
2010-04-05 20:11:45 +00:00
Dan Gohman
2aff0055c1
Don't do code sinking on unreachable blocks. It's unprofitable and hazardous.
...
llvm-svn: 100455
2010-04-05 19:17:22 +00:00
Chris Lattner
aa58ed7c00
remove the now-redundant MMI pointer in SelectionDAG.
...
llvm-svn: 100419
2010-04-05 06:19:28 +00:00
Chris Lattner
91309715b4
hopefully sate the clang self host build, which is apparently
...
instantiating some folding set stuff that GCC isn't, requiring
some types to not be incomplete.
I don't know if clang is right or wrong, but unbreaking the
bot is goodness. Here's the broken build:
http://google1.osuosl.org:8011/builders/clang-x86_64-darwin10-selfhost/builds/1813/steps/compile.llvm.stage2/logs/stdio
llvm-svn: 100418
2010-04-05 06:12:01 +00:00
Chris Lattner
097a332684
remove some redundant MMI arguments.
...
llvm-svn: 100417
2010-04-05 06:10:13 +00:00
Chris Lattner
6f3c3f60ce
unthread MMI from FastISel
...
llvm-svn: 100416
2010-04-05 06:05:26 +00:00
Chris Lattner
cfca39ef59
remove the MMI pointer from MachineFrameInfo.
...
llvm-svn: 100415
2010-04-05 05:57:52 +00:00
Chris Lattner
811d538611
enhance MachineFunction to have a MMI pointer.
...
llvm-svn: 100414
2010-04-05 05:49:50 +00:00
Chris Lattner
341747c032
privatize more stuff, eliminate vtables.
...
llvm-svn: 100410
2010-04-05 05:32:45 +00:00
Chris Lattner
5d96bd2bbe
reprivatize now that DwarfWriter is gone.
...
llvm-svn: 100409
2010-04-05 05:31:04 +00:00
Chris Lattner
59156acba1
prune #includes, MMI can never be null
...
llvm-svn: 100408
2010-04-05 05:28:23 +00:00
Chris Lattner
f2fb401571
prune #includes, realize the MMI can never be null.
...
llvm-svn: 100407
2010-04-05 05:24:55 +00:00
Chris Lattner
37d4f1e56e
finally blast DwarfWriter away.
...
llvm-svn: 100406
2010-04-05 05:12:59 +00:00
Chris Lattner
df6b0827aa
change AsmPrinter to use DwarfDebug/DwarfException directly
...
instead of going through DwarfWriter.
llvm-svn: 100405
2010-04-05 05:11:15 +00:00
Chris Lattner
248e65ec05
trim some spurious references to DwarfWriter. SDIsel really doesn't
...
need it anymore, so don't addRequire it.
llvm-svn: 100400
2010-04-05 04:09:20 +00:00
Chris Lattner
16ed3bfb2b
eliminate DwarfDebug::shouldEmit, which is the same now as MMI::hasDebugInfo
...
llvm-svn: 100386
2010-04-05 03:52:55 +00:00
Chris Lattner
697c2edddc
fix a regression on 2009-08-17-DebugInfo.m
...
llvm-svn: 100385
2010-04-05 03:49:26 +00:00
Chris Lattner
c930f73b4d
selection dag doesn't need DwarfWriter, remove some tendrils.
...
llvm-svn: 100382
2010-04-05 02:23:33 +00:00
Chris Lattner
1fda8b3a8b
fastisel doesn't need DwarfWriter, remove some tendricles.
...
llvm-svn: 100381
2010-04-05 02:19:28 +00:00
Chris Lattner
6040137045
just have all targets create the DwarfWriter.
...
llvm-svn: 100377
2010-04-05 00:42:55 +00:00
Chris Lattner
fd80e7cca8
nuke DwarfPrinter
...
llvm-svn: 100375
2010-04-05 00:27:29 +00:00
Chris Lattner
122288eb97
make DwarfException not inherit from DwarfPrinter.
...
llvm-svn: 100374
2010-04-05 00:26:50 +00:00
Chris Lattner
c1b63a2dfa
change SizeOf to take AsmPrinter instead of TargetData,
...
simplifying a bunch of code.
llvm-svn: 100373
2010-04-05 00:18:22 +00:00
Chris Lattner
2b89b0d279
1) make DIE take AsmPrinter instead of DwarfPrinter.
...
2) change DwarfDebug to not inherit from DwarfPrinter.
llvm-svn: 100372
2010-04-05 00:13:49 +00:00
Chris Lattner
0744c47856
Move EmitFrameMoves into AsmPrinter.
...
llvm-svn: 100371
2010-04-04 23:41:46 +00:00
Chris Lattner
303e9e2e0a
simplify code and reduce indentation.
...
llvm-svn: 100369
2010-04-04 23:31:58 +00:00
Chris Lattner
2eaed62f7c
now that the magic is dispelled, move EmitSectionOffset to AsmPrinter.
...
llvm-svn: 100368
2010-04-04 23:25:33 +00:00
Chris Lattner
ecdad4bb0c
eliminate the magic AbsoluteDebugSectionOffsets MAI hook,
...
which is really a property of the section being referenced.
Add a predicate to MCSection to replace it.
Yay for reduction in magic.
llvm-svn: 100367
2010-04-04 23:22:29 +00:00
Chris Lattner
957eddbcb0
only emit section labels if we have debug info, fixing a few
...
regtest failures.
llvm-svn: 100366
2010-04-04 23:17:54 +00:00
Chris Lattner
7295a273aa
I was wrong, ocaml isn't referencing 'Ldata_begin', so remove it.
...
llvm-svn: 100365
2010-04-04 23:10:38 +00:00