1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-19 11:02:59 +02:00
Commit Graph

51918 Commits

Author SHA1 Message Date
Devang Patel
253aa4d192 Add llvm::Metadata to manage metadata used in a context.
This interface will be used to attach metadata with an instruction.

llvm-svn: 82060
2009-09-16 18:09:00 +00:00
Kevin Enderby
41b1d4288a Fixed some problems with the logic of parsing line comments by adding
isAtStartOfComment and using that instead in two places where a loop
to check if the char was in MAI.getCommentString().

llvm-svn: 82059
2009-09-16 18:08:00 +00:00
Kevin Enderby
007cc571b8 Fix incorrect assert that should be a user error for code like 'mov $0, %%eax'.
llvm-svn: 82054
2009-09-16 17:18:29 +00:00
Dan Gohman
c7e3d84790 Change FoldPHIArgBinOpIntoPHI to decline folding if it would introduce two
phis, similar to the FoldPHIArgGEPIntoPHI change.

Also, delete some comments that don't reflect the code.

llvm-svn: 82053
2009-09-16 16:50:24 +00:00
Dan Gohman
2296899a6b Fix the comment in this test.
llvm-svn: 82051
2009-09-16 16:33:59 +00:00
Xerxes Ranby
d7ea8f55c2 Make cmake generated llvm-config output correct JIT backend for non X86 targets.
llvm-svn: 82049
2009-09-16 14:36:35 +00:00
Benjamin Kramer
55ae32042d Don't sort the vector when it is empty. This should fix some expensive checking
failures.

llvm-svn: 82040
2009-09-16 11:43:12 +00:00
Andreas Neustifter
15e9f61d26 Reapplied r81355 with the problems fixed.
(See http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20090907/086737.html and
http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20090907/086746.html)

llvm-svn: 82039
2009-09-16 11:35:50 +00:00
Xerxes Ranby
9232899c5c updated lib/CodeGen/CMakeLists.txt to unbreak cmake build after r82018
llvm-svn: 82038
2009-09-16 10:18:36 +00:00
Andreas Neustifter
3c9b4c4c75 Preserve ProfileInfo during CodeGenPrepare.
llvm-svn: 82034
2009-09-16 09:26:52 +00:00
Chris Lattner
f91260f6cf move FnStubs/GVSTubs/HiddenGVStub handling out of the X86 asmprinter
and use MachineModuleInfoMachO instead.

llvm-svn: 82022
2009-09-16 06:25:03 +00:00
Chris Lattner
481a417960 revert a hunk of r82018 that wasn't supposed to go in yet.
llvm-svn: 82020
2009-09-16 06:04:53 +00:00
Chris Lattner
4452afa6d8 add a new MachineModuleInfoMachO class, which is the per-module
stuff common across all macho targets.

llvm-svn: 82018
2009-09-16 06:03:48 +00:00
Chris Lattner
7a72ad7d64 apparently russians are really hard to sort or something!
llvm-svn: 82016
2009-09-16 05:42:12 +00:00
Chris Lattner
8faffd7a23 I can sort, no really.
llvm-svn: 82015
2009-09-16 05:37:13 +00:00
Chris Lattner
dff97f437f make more clear since it is sorted by last name now.
llvm-svn: 82014
2009-09-16 05:36:54 +00:00
Chris Lattner
f84436f884 Doug is now the code owner for most of the Clang frontend.
llvm-svn: 82013
2009-09-16 05:36:07 +00:00
Chris Lattner
d6143d7aff the pointer MMI keeps will start out with object-file format specific stuff
llvm-svn: 82012
2009-09-16 05:26:00 +00:00
Chris Lattner
bc8d86ec5a tidy up
llvm-svn: 82011
2009-09-16 05:25:43 +00:00
Chris Lattner
e6bd7b39eb rearrange X86ATTAsmPrinter::doFinalization, making a scan of
the global variable list only happen for COFF targets.

llvm-svn: 82010
2009-09-16 05:20:33 +00:00
Chris Lattner
2bb1f0bbd8 Ted is christened as the owner of the clang static analyzer.
llvm-svn: 82008
2009-09-16 04:59:30 +00:00
Chris Lattner
0a6f37ec43 remove the AsmPrinter::printMCInst hook hack now that
we have MCInstPrinter.

llvm-svn: 82006
2009-09-16 04:57:15 +00:00
Shantonu Sen
cdd58c2969 fix cmake build
llvm-svn: 81999
2009-09-16 04:44:00 +00:00
Chris Lattner
fab7b49bb0 use an accessor to simplify code.
llvm-svn: 81997
2009-09-16 04:12:47 +00:00
Nate Begeman
e9d86c0126 Do not try and sink a load whose chain result has more than one use, when
trying to create RMW opportunities in the x86 backend.  This can cause a 
cycle to appear in the graph, since the other uses may eventually feed into
the TokenFactor we are sinking the load below.

llvm-svn: 81996
2009-09-16 03:20:46 +00:00
Sean Callanan
0fb60155bd Added the ENTER instruction, which sets up a stack
frame, to the Intel instruction tables.

llvm-svn: 81995
2009-09-16 02:57:13 +00:00
Sean Callanan
a3e93882f3 Added the definitions for one-bit left shifts to
the Intel instruction tables.

The patterns will stay blank because ADD reg, reg
is faster, but having the encoding available is
useful for the disassembler.

llvm-svn: 81994
2009-09-16 02:28:43 +00:00
Dan Gohman
77638f25b1 Don't sink gep operators through phi nodes if the result would require
more than one phi, since that leads to higher register pressure on
entry to the phi. This is especially problematic when the phi is in
a loop header, as it increases register pressure throughout the loop.

llvm-svn: 81993
2009-09-16 02:01:52 +00:00
Sean Callanan
e482e93995 Removed a few instructions that were already
covered by other definitions.

llvm-svn: 81992
2009-09-16 01:54:38 +00:00
Chris Lattner
7b52d90c9e Big change #1 for personality function references:
Eliminate the PersonalityPrefix/Suffix & NeedsIndirectEncoding
fields from MAI: they aren't part of the asm syntax, they are
related to the structure of the object file.

To replace their functionality, add a new 
TLOF::getSymbolForDwarfGlobalReference method which asks targets
to decide how to reference a global from EH in a pc-relative way.

The default implementation just returns the symbol.  The default
darwin implementation references the symbol through an indirect
$non_lazy_ptr stub.  The bizarro x86-64 darwin specialization
handles the weird "foo@GOTPCREL+4" hack.

DwarfException.cpp now uses this to emit the reference to the
symbol in the right way, and this also eliminates another 
horrible hack from DwarfException.cpp:

-    if (strcmp(MAI->getPersonalitySuffix(), "+4@GOTPCREL"))
-      O << "-" << MAI->getPCSymbol();

llvm-svn: 81991
2009-09-16 01:46:41 +00:00
Daniel Dunbar
dadd71259e lit: Add a custom test format for use in clang.
llvm-svn: 81987
2009-09-16 01:34:52 +00:00
Chris Lattner
7a0fe1ca4b remove a dead variable.
llvm-svn: 81985
2009-09-16 01:29:11 +00:00
Chris Lattner
006af669b4 add a helper method for creating MCSymbol and MCSymbolRefExpr at
the same time.

llvm-svn: 81984
2009-09-16 01:26:31 +00:00
Sean Callanan
296ed7d1e1 Added a variety of floating-point and SSE instructions.
All of these do not have patterns (they're for the
disassembler).

Many of the floating-point instructions will probably
be rolled into definitions that have patterns, and may
eventually be superseded by mdefs.  So I put them
together and left a comment.

llvm-svn: 81979
2009-09-16 01:13:52 +00:00
Chris Lattner
7a4748ad3a inline AsmPrinter::getCurrentFunctionEHName into its only caller.
llvm-svn: 81970
2009-09-16 00:35:39 +00:00
Bob Wilson
8770c809c2 Expand some more vector operations not supported by Neon.
llvm-svn: 81969
2009-09-16 00:32:15 +00:00
Chris Lattner
8cad2c9d35 remove a dead bool.
llvm-svn: 81968
2009-09-16 00:24:31 +00:00
Chris Lattner
7a07d794ee Eliminate AsmPrinter::EmitExternalGlobal, inlining its (now)
one implementation into its one caller.  This eliminates a totally
awesome and gratuitous hack where we casted a Function* to 
GlobalVariable*.

llvm-svn: 81967
2009-09-16 00:17:39 +00:00
Bob Wilson
c01a94dad0 Neon does not support vector divide or remainder. Expand them.
llvm-svn: 81966
2009-09-16 00:17:28 +00:00
Chris Lattner
91c3b33e33 eliminate the PPC backend's implementation of EmitExternalGlobal
and use PersonalityPrefix/Suffix to achieve the same effect (like
the x86 backend).

This changes the code generated for ppc static mode, but guess what,
we were generating this before:

	.byte	0x9B                                        ; Personality (indirect pcrel sdata4)
	.long	___gxx_personality_v0-.                     ; Personality

which is not correct! (it is not an 'indirect' reference).
 

llvm-svn: 81965
2009-09-16 00:14:19 +00:00
Chris Lattner
f720dd9257 eliminate the horrid AsmPrinter::getGlobalLinkName method, inlining
it into all of its call sites and simplifying them.

llvm-svn: 81962
2009-09-16 00:08:41 +00:00
Chris Lattner
6302039748 simplify some code
llvm-svn: 81961
2009-09-16 00:08:07 +00:00
Bob Wilson
f091792f40 Expand all v2f64 arithmetic operations for Neon.
Radar 7200803.  (This should also fix the
SingleSource/UnitTests/Vector/sumarray-dbl test.)

llvm-svn: 81959
2009-09-15 23:55:57 +00:00
Daniel Dunbar
d383d40999 Put back non-obsolete -f sections for 'opt'.
llvm-svn: 81954
2009-09-15 23:40:07 +00:00
Sean Callanan
a68b2a56bb Added far return instructions (that is, returns to
code in other segments) to the Intel instruction
tables.

llvm-svn: 81953
2009-09-15 23:37:51 +00:00
Chris Lattner
249d5fe8b9 remove some horrible MAI hooks which fortunately turn out to be always empty.
llvm-svn: 81946
2009-09-15 23:11:32 +00:00
Chris Lattner
c06870ad45 strength reduce a call to PrintRelDirective(true).
llvm-svn: 81942
2009-09-15 22:58:35 +00:00
Chris Lattner
8457d8c557 add hooks to hang target-specific goop off MachineModuleInfo,
move MachineFunctionInfo virtual method out of line to give it
a home.

llvm-svn: 81940
2009-09-15 22:44:26 +00:00
Nate Begeman
d34c7760b3 Do not add the SVOffset to the Node CSE ID. The same pointer argument cannot have different
SVOffsets.

llvm-svn: 81937
2009-09-15 22:30:11 +00:00
Eric Christopher
936a41fff1 Expand on comment.
llvm-svn: 81928
2009-09-15 21:56:46 +00:00