oota-llvm.git
14 years agotrim some spurious references to DwarfWriter. SDIsel really doesn't
Chris Lattner [Mon, 5 Apr 2010 04:09:20 +0000 (04:09 +0000)]
trim some spurious references to DwarfWriter.  SDIsel really doesn't
need it anymore, so don't addRequire it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100400 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoprune some #includes.
Chris Lattner [Mon, 5 Apr 2010 04:04:10 +0000 (04:04 +0000)]
prune some #includes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100399 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoeliminate DwarfDebug::shouldEmit, which is the same now as MMI::hasDebugInfo
Chris Lattner [Mon, 5 Apr 2010 03:52:55 +0000 (03:52 +0000)]
eliminate DwarfDebug::shouldEmit, which is the same now as MMI::hasDebugInfo

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100386 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agofix a regression on 2009-08-17-DebugInfo.m
Chris Lattner [Mon, 5 Apr 2010 03:49:26 +0000 (03:49 +0000)]
fix a regression on 2009-08-17-DebugInfo.m

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100385 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoReplace TSFlagsFields and TSFlagsShifts with a simpler TSFlags field.
Jakob Stoklund Olesen [Mon, 5 Apr 2010 03:10:20 +0000 (03:10 +0000)]
Replace TSFlagsFields and TSFlagsShifts with a simpler TSFlags field.

When a target instruction wants to set target-specific flags, it should simply
set bits in the TSFlags bit vector defined in the Instruction TableGen class.

This works well because TableGen resolves member references late:

class I : Instruction {
  AddrMode AM = AddrModeNone;
  let TSFlags{3-0} = AM.Value;
}

let AM = AddrMode4 in
def ADD : I;

TSFlags gets the expected bits from AddrMode4 in this example.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100384 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoselection dag doesn't need DwarfWriter, remove some tendrils.
Chris Lattner [Mon, 5 Apr 2010 02:23:33 +0000 (02:23 +0000)]
selection dag doesn't need DwarfWriter, remove some tendrils.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100382 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agofastisel doesn't need DwarfWriter, remove some tendricles.
Chris Lattner [Mon, 5 Apr 2010 02:19:28 +0000 (02:19 +0000)]
fastisel doesn't need DwarfWriter, remove some tendricles.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100381 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoTemporarily remove to disable building of ARM disassembler.
Evan Cheng [Mon, 5 Apr 2010 01:57:50 +0000 (01:57 +0000)]
Temporarily remove to disable building of ARM disassembler.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100380 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoRe-apply 100265 but instead disable building of ARM disassembly for now.
Evan Cheng [Mon, 5 Apr 2010 01:34:00 +0000 (01:34 +0000)]
Re-apply 100265 but instead disable building of ARM disassembly for now.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100379 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoReverting 100265 to try to get buildbots green again. Lots of self-hosting buildbots...
Evan Cheng [Mon, 5 Apr 2010 01:04:27 +0000 (01:04 +0000)]
Reverting 100265 to try to get buildbots green again. Lots of self-hosting buildbots started complaining since this commit. Also xfail ARM disassembly tests.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100378 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agojust have all targets create the DwarfWriter.
Chris Lattner [Mon, 5 Apr 2010 00:42:55 +0000 (00:42 +0000)]
just have all targets create the DwarfWriter.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100377 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agosimplify various getAnalysisUsage implementations.
Chris Lattner [Mon, 5 Apr 2010 00:38:44 +0000 (00:38 +0000)]
simplify various getAnalysisUsage implementations.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100376 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agonuke DwarfPrinter
Chris Lattner [Mon, 5 Apr 2010 00:27:29 +0000 (00:27 +0000)]
nuke DwarfPrinter

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100375 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agomake DwarfException not inherit from DwarfPrinter.
Chris Lattner [Mon, 5 Apr 2010 00:26:50 +0000 (00:26 +0000)]
make DwarfException not inherit from DwarfPrinter.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100374 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agochange SizeOf to take AsmPrinter instead of TargetData,
Chris Lattner [Mon, 5 Apr 2010 00:18:22 +0000 (00:18 +0000)]
change SizeOf to take AsmPrinter instead of TargetData,
simplifying a bunch of code.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100373 91177308-0d34-0410-b5e6-96231b3b80d8

14 years ago1) make DIE take AsmPrinter instead of DwarfPrinter.
Chris Lattner [Mon, 5 Apr 2010 00:13:49 +0000 (00:13 +0000)]
1) make DIE take AsmPrinter instead of DwarfPrinter.
2) change DwarfDebug to not inherit from DwarfPrinter.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100372 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoMove EmitFrameMoves into AsmPrinter.
Chris Lattner [Sun, 4 Apr 2010 23:41:46 +0000 (23:41 +0000)]
Move EmitFrameMoves into AsmPrinter.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100371 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agomissed a header :(
Chris Lattner [Sun, 4 Apr 2010 23:36:52 +0000 (23:36 +0000)]
missed a header :(

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100370 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agosimplify code and reduce indentation.
Chris Lattner [Sun, 4 Apr 2010 23:31:58 +0000 (23:31 +0000)]
simplify code and reduce indentation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100369 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agonow that the magic is dispelled, move EmitSectionOffset to AsmPrinter.
Chris Lattner [Sun, 4 Apr 2010 23:25:33 +0000 (23:25 +0000)]
now that the magic is dispelled, move EmitSectionOffset to AsmPrinter.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100368 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoeliminate the magic AbsoluteDebugSectionOffsets MAI hook,
Chris Lattner [Sun, 4 Apr 2010 23:22:29 +0000 (23:22 +0000)]
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.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100367 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoonly emit section labels if we have debug info, fixing a few
Chris Lattner [Sun, 4 Apr 2010 23:17:54 +0000 (23:17 +0000)]
only emit section labels if we have debug info, fixing a few
regtest failures.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100366 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoI was wrong, ocaml isn't referencing 'Ldata_begin', so remove it.
Chris Lattner [Sun, 4 Apr 2010 23:10:38 +0000 (23:10 +0000)]
I was wrong, ocaml isn't referencing 'Ldata_begin', so remove it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100365 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoadd some assertions to EmitSectionOffset.
Chris Lattner [Sun, 4 Apr 2010 23:06:31 +0000 (23:06 +0000)]
add some assertions to EmitSectionOffset.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100364 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agostop emitting some dead L labels.
Chris Lattner [Sun, 4 Apr 2010 23:02:02 +0000 (23:02 +0000)]
stop emitting some dead L labels.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100363 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoStore an use the symbols emitted at the start of the debug
Chris Lattner [Sun, 4 Apr 2010 22:59:04 +0000 (22:59 +0000)]
Store an use the symbols emitted at the start of the debug
sections instead of magically rematerializing them later.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100362 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoremove the didInitial ivar, rename emitInitial to be more
Chris Lattner [Sun, 4 Apr 2010 22:33:59 +0000 (22:33 +0000)]
remove the didInitial ivar, rename emitInitial to be more
descriptive, change EmitSectionOffset back to taking a
symbol instead of a string.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100361 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agosimplify EmitSectionOffset a little bit, improve comments.
Chris Lattner [Sun, 4 Apr 2010 22:25:14 +0000 (22:25 +0000)]
simplify EmitSectionOffset a little bit, improve comments.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100360 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agorevert my patch, need to reconsider this and figure out what is really going on.
Chris Lattner [Sun, 4 Apr 2010 21:49:31 +0000 (21:49 +0000)]
revert my patch, need to reconsider this and figure out what is really going on.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100358 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agofix pasto, this is the wrong setting for arm elf.
Chris Lattner [Sun, 4 Apr 2010 21:37:20 +0000 (21:37 +0000)]
fix pasto, this is the wrong setting for arm elf.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100357 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoThe "IsSmall" argument to EmitSectionOffset is always true,
Chris Lattner [Sun, 4 Apr 2010 21:34:40 +0000 (21:34 +0000)]
The "IsSmall" argument to EmitSectionOffset is always true,
constant fold it away.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100356 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoeliminate the "isEH" argument to EmitSectionOffset.
Chris Lattner [Sun, 4 Apr 2010 21:31:54 +0000 (21:31 +0000)]
eliminate the "isEH" argument to EmitSectionOffset.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100355 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoisAbsoluteEHSectionOffsets always returns false, eliminate it
Chris Lattner [Sun, 4 Apr 2010 21:29:44 +0000 (21:29 +0000)]
isAbsoluteEHSectionOffsets always returns false, eliminate it
and substitute false at the one call site.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100354 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoClean up SSEDomainFix pass.
Jakob Stoklund Olesen [Sun, 4 Apr 2010 21:27:26 +0000 (21:27 +0000)]
Clean up SSEDomainFix pass.

Restrict bit mask operations to the DomainValue class. Rename methods for
clarity.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100353 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agodon't reset the default.
Chris Lattner [Sun, 4 Apr 2010 21:06:50 +0000 (21:06 +0000)]
don't reset the default.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100352 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agomove some more stuff to asmprinter.
Chris Lattner [Sun, 4 Apr 2010 20:20:50 +0000 (20:20 +0000)]
move some more stuff to asmprinter.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100351 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agosimplify some code.
Chris Lattner [Sun, 4 Apr 2010 20:10:41 +0000 (20:10 +0000)]
simplify some code.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100350 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agomove EmitEncodingByte to AsmPrinter.
Chris Lattner [Sun, 4 Apr 2010 20:04:21 +0000 (20:04 +0000)]
move EmitEncodingByte to AsmPrinter.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100349 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agomove EmitCFAByte to AsmPrinter.
Chris Lattner [Sun, 4 Apr 2010 20:01:25 +0000 (20:01 +0000)]
move EmitCFAByte to AsmPrinter.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100348 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoinline EmitDifference away.
Chris Lattner [Sun, 4 Apr 2010 19:58:12 +0000 (19:58 +0000)]
inline EmitDifference away.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100347 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoresolve a fixme.
Chris Lattner [Sun, 4 Apr 2010 19:28:59 +0000 (19:28 +0000)]
resolve a fixme.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100346 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agomove gettemplabel and getdwlabel to AsmPrinter and rename
Chris Lattner [Sun, 4 Apr 2010 19:25:43 +0000 (19:25 +0000)]
move gettemplabel and getdwlabel to AsmPrinter and rename
them for consistency.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100345 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agomove uleb/sleb printing into AsmPrinter from DwarfPrinter.
Chris Lattner [Sun, 4 Apr 2010 19:09:29 +0000 (19:09 +0000)]
move uleb/sleb printing into AsmPrinter from DwarfPrinter.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100344 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agomore interface cleanup make some helpers static functions.
Chris Lattner [Sun, 4 Apr 2010 18:58:53 +0000 (18:58 +0000)]
more interface cleanup make some helpers static functions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100343 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoclean up the asmprinter header and privatize some stuff.
Chris Lattner [Sun, 4 Apr 2010 18:52:31 +0000 (18:52 +0000)]
clean up the asmprinter header and privatize some stuff.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100342 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agouse stringref instead of strtol to avoid errno gymnastics.
Chris Lattner [Sun, 4 Apr 2010 18:42:18 +0000 (18:42 +0000)]
use stringref instead of strtol to avoid errno gymnastics.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100341 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agosplit inline asm support out to its own .cpp file.
Chris Lattner [Sun, 4 Apr 2010 18:34:07 +0000 (18:34 +0000)]
split inline asm support out to its own .cpp file.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100340 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoinline processDebugLoc and simplify it.
Chris Lattner [Sun, 4 Apr 2010 18:18:51 +0000 (18:18 +0000)]
inline processDebugLoc and simplify it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100339 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agominor tidying.
Chris Lattner [Sun, 4 Apr 2010 18:16:38 +0000 (18:16 +0000)]
minor tidying.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100338 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoclean up the asmprinter interface a bit, rename a few
Chris Lattner [Sun, 4 Apr 2010 18:14:01 +0000 (18:14 +0000)]
clean up the asmprinter interface a bit, rename a few
"Print" methods to "Emit".  Emit is something that goes
to an mc streamer, Print is something that goes to a
raw_ostream (for inline asm)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100337 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoremove TargetMachine.h #include, also, TRI isn't used frequently
Chris Lattner [Sun, 4 Apr 2010 18:06:11 +0000 (18:06 +0000)]
remove TargetMachine.h #include, also, TRI isn't used frequently
enough to warrant caching in AsmPrinter, so remove it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100336 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoSwitch SSEDomainFix to SpecificBumpPtrAllocator.
Jakob Stoklund Olesen [Sun, 4 Apr 2010 18:00:21 +0000 (18:00 +0000)]
Switch SSEDomainFix to SpecificBumpPtrAllocator.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100332 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agolazily allocate the GCMetadataPrinters map and remove DenseMap
Chris Lattner [Sun, 4 Apr 2010 17:57:56 +0000 (17:57 +0000)]
lazily allocate the GCMetadataPrinters map and remove DenseMap
from the AsmPrinter interface.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100331 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoCurFn is only used for relocations. Use EmissionDetails.MF->getFunction() instead.
Nicolas Geoffray [Sun, 4 Apr 2010 10:31:49 +0000 (10:31 +0000)]
CurFn is only used for relocations. Use EmissionDetails.MF->getFunction() instead.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100328 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoMomentous day: remove the "O" member from AsmPrinter. Now all
Chris Lattner [Sun, 4 Apr 2010 08:18:47 +0000 (08:18 +0000)]
Momentous day: remove the "O" member from AsmPrinter.  Now all
"asm printering" happens through MCStreamer.  This also
Streamerizes PIC16 debug info, which escaped my attention.

This removes a leak from LLVMTargetMachine of the 'legacy'
output stream.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100327 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agonow that all operand printing happens to specified streams, we can
Chris Lattner [Sun, 4 Apr 2010 07:50:12 +0000 (07:50 +0000)]
now that all operand printing happens to specified streams, we can
print function level inline asm with EmitInlineAsm instead of writing
it directly to "O".

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100326 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoremove the raw_ostream from various dwarf printing things.
Chris Lattner [Sun, 4 Apr 2010 07:48:20 +0000 (07:48 +0000)]
remove the raw_ostream from various dwarf printing things.

The only thing left is LEB printing, which uses EmitRawText
for now.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100325 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agomcize the gc metadata printing stuff.
Chris Lattner [Sun, 4 Apr 2010 07:39:04 +0000 (07:39 +0000)]
mcize the gc metadata printing stuff.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100324 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agouse EmitRawText instead of O in DwarfPrinter.
Chris Lattner [Sun, 4 Apr 2010 07:25:52 +0000 (07:25 +0000)]
use EmitRawText instead of O in DwarfPrinter.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100323 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agomc'ize the remaining uses of O.
Chris Lattner [Sun, 4 Apr 2010 07:23:00 +0000 (07:23 +0000)]
mc'ize the remaining uses of O.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100322 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agofinish eliminating uses of O.
Chris Lattner [Sun, 4 Apr 2010 07:17:25 +0000 (07:17 +0000)]
finish eliminating uses of O.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100321 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agomcize more of ppc stub printing.
Chris Lattner [Sun, 4 Apr 2010 07:12:28 +0000 (07:12 +0000)]
mcize more of ppc stub printing.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100320 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agomcize a bunch more stuff, using EmitRawText for things we
Chris Lattner [Sun, 4 Apr 2010 07:05:53 +0000 (07:05 +0000)]
mcize a bunch more stuff, using EmitRawText for things we
don't have mcstreamer support for yet.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100319 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoconvert the non-MCInstPrinter'ized EmitInstruction
Chris Lattner [Sun, 4 Apr 2010 06:12:20 +0000 (06:12 +0000)]
convert the non-MCInstPrinter'ized EmitInstruction
implementations to use EmitRawText instead of writing
directly to "O".

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100318 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agostreamerize the rest of PIC16 asm printer.
Chris Lattner [Sun, 4 Apr 2010 05:53:03 +0000 (05:53 +0000)]
streamerize the rest of PIC16 asm printer.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100317 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agostreamerize printing of dbg_value, the x86 backend is now fully
Chris Lattner [Sun, 4 Apr 2010 05:40:34 +0000 (05:40 +0000)]
streamerize printing of dbg_value, the x86 backend is now fully
streamerized for everything.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100316 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agosplit DEBUG_VALUE printing stuff out to its own method.
Chris Lattner [Sun, 4 Apr 2010 05:38:19 +0000 (05:38 +0000)]
split DEBUG_VALUE printing stuff out to its own method.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100315 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agomc'ize elf stub printing, convert cygwin stuff to EmitRawText,
Chris Lattner [Sun, 4 Apr 2010 05:35:04 +0000 (05:35 +0000)]
mc'ize elf stub printing, convert cygwin stuff to EmitRawText,
which will abort in .o file writing mode.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100314 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agofix PrintAsmOperand and PrintAsmMemoryOperand to pass down
Chris Lattner [Sun, 4 Apr 2010 05:29:35 +0000 (05:29 +0000)]
fix PrintAsmOperand and PrintAsmMemoryOperand to pass down
raw_ostream to print to.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100313 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agouse predicates in DBG_VALUE printing code to simplify it.
Chris Lattner [Sun, 4 Apr 2010 05:21:31 +0000 (05:21 +0000)]
use predicates in DBG_VALUE printing code to simplify it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100312 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoremove more implicit uses of "O".
Chris Lattner [Sun, 4 Apr 2010 05:19:20 +0000 (05:19 +0000)]
remove more implicit uses of "O".

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100311 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agochange this back too
Chris Lattner [Sun, 4 Apr 2010 05:09:10 +0000 (05:09 +0000)]
change this back too

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100310 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agocheck in what I tested. :(
Chris Lattner [Sun, 4 Apr 2010 05:08:10 +0000 (05:08 +0000)]
check in what I tested. :(

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100309 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoMMI is always available, rename O -> OS in printInlineAsm.
Chris Lattner [Sun, 4 Apr 2010 05:07:45 +0000 (05:07 +0000)]
MMI is always available, rename O -> OS in printInlineAsm.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100308 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agofix an ugly wart in the MCInstPrinter api where the
Chris Lattner [Sun, 4 Apr 2010 05:04:31 +0000 (05:04 +0000)]
fix an ugly wart in the MCInstPrinter api where the
raw_ostream to print an instruction to had to be specified
at MCInstPrinter construction time instead of being able
to pick at each call to printInstruction.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100307 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agochange a ton of code to not implicitly use the "O" raw_ostream
Chris Lattner [Sun, 4 Apr 2010 04:47:45 +0000 (04:47 +0000)]
change a ton of code to not implicitly use the "O" raw_ostream
member of AsmPrinter.  Instead, pass it in explicitly.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100306 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoReapply address space patch after fixing an issue in MemCopyOptimizer.
Mon P Wang [Sun, 4 Apr 2010 03:10:48 +0000 (03:10 +0000)]
Reapply address space patch after fixing an issue in MemCopyOptimizer.
Added support for address spaces and added a isVolatile field to memcpy, memmove, and memset,
e.g., llvm.memcpy.i32(i8*, i8*, i32, i32) -> llvm.memcpy.p0i8.p0i8.i32(i8*, i8*, i32, i32, i1)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100304 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoasmstreamerize the .size directive for function bodies, force clients
Chris Lattner [Sat, 3 Apr 2010 22:28:33 +0000 (22:28 +0000)]
asmstreamerize the .size directive for function bodies, force clients
of printOffset to pass in a stream to print to.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100296 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoemit the cygwin stub thing through mcstreamer.
Chris Lattner [Sat, 3 Apr 2010 22:19:41 +0000 (22:19 +0000)]
emit the cygwin stub thing through mcstreamer.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100295 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoadd a twine form of MCStreamer::EmitRawText, and mc'ize
Chris Lattner [Sat, 3 Apr 2010 22:12:35 +0000 (22:12 +0000)]
add a twine form of MCStreamer::EmitRawText, and mc'ize
a few more things in AsmPrinter.cpp.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100294 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoallow attaching comments to raw text.
Chris Lattner [Sat, 3 Apr 2010 22:06:56 +0000 (22:06 +0000)]
allow attaching comments to raw text.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100292 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agostart moving towards emitting inline asm statements with
Chris Lattner [Sat, 3 Apr 2010 22:01:50 +0000 (22:01 +0000)]
start moving towards emitting inline asm statements with
EmitInlineAsm.  However, this attempt is foiled by operands
being emitted directly to "O" so I'll have to do some surgery
and finish MCizing the world.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100291 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoadd <cstdlib> header for abort() on linux builders.
Chris Lattner [Sat, 3 Apr 2010 21:48:59 +0000 (21:48 +0000)]
add <cstdlib> header for abort() on linux builders.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100290 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoadd a new EmitInlineAsm function to asmprinter to handle inline asm.
Chris Lattner [Sat, 3 Apr 2010 21:35:55 +0000 (21:35 +0000)]
add a new EmitInlineAsm function to asmprinter to handle inline asm.
If we have an MCAsmStreamer, we continue to emit asm textually,
otherwise we (currently) emit an error to errs and ignore it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100289 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agomc'ize comment printing around file scope inline asm.
Chris Lattner [Sat, 3 Apr 2010 21:13:18 +0000 (21:13 +0000)]
mc'ize comment printing around file scope inline asm.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100288 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoremove some extraneous casts
Chris Lattner [Sat, 3 Apr 2010 21:03:50 +0000 (21:03 +0000)]
remove some extraneous casts

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100287 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agorequire that the branch being controlled by the IV
Chris Lattner [Sat, 3 Apr 2010 07:21:39 +0000 (07:21 +0000)]
require that the branch being controlled by the IV
exits the loop.  With this information we can guarantee
the iteration count of the loop is bounded by the
compare.  I think this xforms is finally safe now.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100285 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoadd integer overflow check for the fp induction variable
Chris Lattner [Sat, 3 Apr 2010 07:18:48 +0000 (07:18 +0000)]
add integer overflow check for the fp induction variable
checker.  Amusingly, we already had tests that we should
have rejects because they would be miscompiled in the
testsuite.

The remaining issue with this is that we don't check that
the branch causes us to exit the loop if it fails, so we
don't actually know if we remain in bounds.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100284 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoadd a comment and fix some consistency issues, converting
Chris Lattner [Sat, 3 Apr 2010 06:41:49 +0000 (06:41 +0000)]
add a comment and fix some consistency issues, converting
to a signed vs unsigned value depending on the sign of the
constant fp means that we can't distinguish between a
truly negative number and a positive number so large the
32nd bit is set.  So, do don't this!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100283 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agofix PR6761, a miscompilation due to the fp->int IV conversion
Chris Lattner [Sat, 3 Apr 2010 06:30:03 +0000 (06:30 +0000)]
fix PR6761, a miscompilation due to the fp->int IV conversion
stuff.  More bugs remain though.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100282 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoconvert to filecheck
Chris Lattner [Sat, 3 Apr 2010 06:27:56 +0000 (06:27 +0000)]
convert to filecheck

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100281 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agojust eliminate the uitofp checks. This code isn't doing
Chris Lattner [Sat, 3 Apr 2010 06:25:21 +0000 (06:25 +0000)]
just eliminate the uitofp checks.  This code isn't doing
the required validity checks in the first place, and supporting
a condition large enough to require the 32'nd bit isn't worth it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100280 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agorename feature test.
Chris Lattner [Sat, 3 Apr 2010 06:24:28 +0000 (06:24 +0000)]
rename feature test.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100279 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoactually just remove this, will move the real feature test here.
Chris Lattner [Sat, 3 Apr 2010 06:24:03 +0000 (06:24 +0000)]
actually just remove this, will move the real feature test here.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100278 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agorename test since it is a feature test.
Chris Lattner [Sat, 3 Apr 2010 06:22:52 +0000 (06:22 +0000)]
rename test since it is a feature test.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100277 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agorename PH -> PN to be consistent with WeakPN and the rest
Chris Lattner [Sat, 3 Apr 2010 06:17:08 +0000 (06:17 +0000)]
rename PH -> PN to be consistent with WeakPN and the rest
of llvm.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100276 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agoimprove comment and drop a dead check. If PH had
Chris Lattner [Sat, 3 Apr 2010 06:16:22 +0000 (06:16 +0000)]
improve comment and drop a dead check.  If PH had
no uses, it would have been deleted by
RecursivelyDeleteTriviallyDeadInstructions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100275 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agostrength reduce a ridiculous use of APInt.
Chris Lattner [Sat, 3 Apr 2010 06:13:12 +0000 (06:13 +0000)]
strength reduce a ridiculous use of APInt.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100274 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agorename stuff improve comment grammar.
Chris Lattner [Sat, 3 Apr 2010 06:11:07 +0000 (06:11 +0000)]
rename stuff improve comment grammar.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100273 91177308-0d34-0410-b5e6-96231b3b80d8

14 years agosimplify some code and resolve a fixme.
Chris Lattner [Sat, 3 Apr 2010 06:06:59 +0000 (06:06 +0000)]
simplify some code and resolve a fixme.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100272 91177308-0d34-0410-b5e6-96231b3b80d8