1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-20 03:23:01 +02:00
Commit Graph

9529 Commits

Author SHA1 Message Date
Daniel Dunbar
952aa01cb9 Revert 78680 until I figure out why it completely broke things.
llvm-svn: 78697
2009-08-11 18:11:15 +00:00
Devang Patel
df6d338da2 Link NamedMDNodes.
llvm-svn: 78696
2009-08-11 18:01:24 +00:00
Dan Gohman
aed57ee5b0 Add convenience functions for creating inbounds GEPs.
llvm-svn: 78695
2009-08-11 17:57:01 +00:00
Chris Lattner
be69fa08b6 add a trivial line # cache to SourceMgr to make repeated queries to
FindLineNumber much faster when in sequence.

llvm-svn: 78693
2009-08-11 17:49:14 +00:00
Benjamin Kramer
9a590500ea Make LLVMContext and LLVMContextImpl classes instead of structs.
llvm-svn: 78690
2009-08-11 17:45:13 +00:00
Daniel Dunbar
92bda7b2e0 Remove some unnecessary LoadInst constructors, missed during Twinification.
llvm-svn: 78689
2009-08-11 17:38:47 +00:00
Benjamin Kramer
15a20278ff Fix struct/class mismatch.
llvm-svn: 78686
2009-08-11 17:27:20 +00:00
Dan Gohman
cf73a006f0 Use isa instead of dyn_cast when the result is only converted to bool.
llvm-svn: 78685
2009-08-11 17:20:16 +00:00
Devang Patel
057559abba Fix cut-n-pasto in comment.
llvm-svn: 78684
2009-08-11 17:15:47 +00:00
Dan Gohman
82b3823bb7 Add convenience functions for creating exact sdiv operators, and
use them in CreatePtrDiff.

llvm-svn: 78682
2009-08-11 17:05:24 +00:00
Dan Gohman
1d382f0ee7 Avoid implicitly depending on Instructions.h.
llvm-svn: 78681
2009-08-11 17:03:18 +00:00
Benjamin Kramer
81ce360762 Revert 78662 to fix broken windows build. Add a comment which explains the problem.
llvm-svn: 78679
2009-08-11 16:41:22 +00:00
Dan Gohman
24939b2c4f Tidy #includes.
llvm-svn: 78677
2009-08-11 16:02:12 +00:00
Dan Gohman
0c6e8e18aa Add an explicit keyword.
llvm-svn: 78675
2009-08-11 15:57:42 +00:00
Dan Gohman
8e39bf3fb6 ConstantFolder and NoFolder no longer require their Context members.
llvm-svn: 78673
2009-08-11 15:56:12 +00:00
Dan Gohman
3056a83ca5 Use the default copy-ctor, copy-assignment, and destructor.
llvm-svn: 78670
2009-08-11 15:52:30 +00:00
Dan Gohman
f610241b61 Add a comment about the additional meaning of setPreservesCFG() for
MachineFunctionPass passes.

llvm-svn: 78669
2009-08-11 15:50:56 +00:00
Dan Gohman
618fc2fc8e Remove an unnecessary mutable.
llvm-svn: 78662
2009-08-11 15:03:52 +00:00
Shantonu Sen
9a3cc1a771 Regenerate per request of Gabor Greif (r78628)
llvm-svn: 78661
2009-08-11 13:39:52 +00:00
Erick Tryzelaar
85056aa5c8 Change llvm-c's ordering of contexts to make it consistent.
llvm-svn: 78656
2009-08-11 07:46:16 +00:00
Devang Patel
4609ecd4bd Remove dead metadata.
llvm-svn: 78651
2009-08-11 06:31:57 +00:00
Jakob Stoklund Olesen
40c33bb2b2 Rebuild RegScavenger::DistanceMap each time it is needed.
The register scavenger maintains a DistanceMap that maps MI pointers to their
distance from the top of the current MBB. The DistanceMap is built
incrementally in forward() and in bulk in findFirstUse(). It is used by
scavengeRegister() to determine which candidate register has the longest
unused interval.

Unfortunately the DistanceMap contents can become outdated. The first time
scavengeRegister() is called, the DistanceMap is filled to cover the MBB. If
then instructions are inserted in the MBB (as they always are following
scavengeRegister()), the recorded distances are too short. This causes bad
behaviour in the included test case where a register use /after/ the current
position is ignored because findFirstUse() thinks is is /before/ the current
position. A "using an undefined register" assertion follows promptly.

The fix is to build a fresh DistanceMap at the top of scavengeRegister(), and
discard it after use. This means that DistanceMap is no longer needed as a
RegScavenger member variable, and forward() doesn't need to update it.

The fix then discloses issue number two in the same test case: The candidate
search in scavengeRegister() finds a CSR that has been saved in the prologue,
but is currently unused. It would be both inefficient and wrong to spill such
a register in the emergency spill slot. In the present case, the emergency
slot restore is placed immediately before the normal epilogue restore, leading
to a "Redefining a live register" assertion.

Fix number two: When scavengerRegister() stumbles upon an unused register that
is overwritten later in the MBB, return that register early. It is important
to verify that the register is defined later in the MBB, otherwise it might be
an unspilled CSR.

llvm-svn: 78650
2009-08-11 06:25:12 +00:00
Bob Wilson
d64e304671 Use vAny type to get rid of Neon intrinsics that differed only in whether
the overloaded vector types allowed floating-point or integer vector elements.
Most of these operations actually depend on the element type, so bitcasting
was not an option.

If you include the vpadd intrinsics that I updated earlier, this gets rid
of 20 intrinsics.

llvm-svn: 78646
2009-08-11 05:39:44 +00:00
Bob Wilson
1c75a23299 Use new EVT::vAny type to combine Neon intrinsics for VPADD.
llvm-svn: 78632
2009-08-11 01:15:26 +00:00
Bob Wilson
4a3ccbda6a Add a new overloaded EVT::vAny type for use in TableGen to allow intrinsic
arguments that are vectors of any size and element type.

llvm-svn: 78631
2009-08-11 01:14:02 +00:00
Jim Grosbach
c9a1dd9291 SjLj based exception handling unwinding support. This patch is nasty, brutish
and short. Well, it's kinda short. Definitely nasty and brutish.

The front-end generates the register/unregister calls into the SjLj runtime,
call-site indices and landing pad dispatch. The back end fills in the LSDA
with the call-site information provided by the front end. Catch blocks are
not yet implemented.

Built on Darwin and verified no llvm-core "make check" regressions.

llvm-svn: 78625
2009-08-11 00:09:57 +00:00
Lang Hames
1503988bb5 Modified VNInfo. The "copy" member is now a union which holds the copy for a register interval, or the defining register for a stack interval. Access is via getCopy/setCopy and getReg/setReg.
llvm-svn: 78620
2009-08-10 23:43:28 +00:00
Owen Anderson
b4bce99769 Rename MVT to EVT, in preparation for splitting SimpleValueType out into its own struct type.
llvm-svn: 78610
2009-08-10 22:56:29 +00:00
Devang Patel
6858a6e408 Align comments.
llvm-svn: 78605
2009-08-10 22:20:38 +00:00
Devang Patel
86894d4e56 Keep track of DIType.
llvm-svn: 78602
2009-08-10 22:09:58 +00:00
Daniel Dunbar
15c79b6fd7 llvm-mc/AsmParser: Allow .td users to redefine the names of the methods to call
on target specific operands for testing class membership and converting to
MCInst operands.

llvm-svn: 78597
2009-08-10 21:00:45 +00:00
Daniel Dunbar
d71d99853c Rename ConvertType to ConvertConstant to avoid a name conflict on llvm-gcc.
llvm-svn: 78596
2009-08-10 20:56:46 +00:00
Owen Anderson
30bf6c8dab SimpleValueType-ify a few more methods on TargetLowering.
llvm-svn: 78595
2009-08-10 20:46:15 +00:00
Owen Anderson
cf56d576eb Continue the SimpleValueType-ification.
llvm-svn: 78593
2009-08-10 20:18:46 +00:00
Erick Tryzelaar
64635cc637 Convert comments to C90-style so llvm-c can import DataTypes.h.
llvm-svn: 78590
2009-08-10 19:44:53 +00:00
Devang Patel
762e9641fd We are not using FoldingSet for metadata uniquing anymore.
llvm-svn: 78585
2009-08-10 18:59:07 +00:00
Owen Anderson
dcb47bda67 Start moving TargetLowering away from using full MVTs and towards SimpleValueType, which will simplify the privatization of IntegerType in the future.
llvm-svn: 78584
2009-08-10 18:56:59 +00:00
Daniel Dunbar
749ff1de5a llvm-mc/AsmMatcher: Change assembler parser match classes to their own record
structure.

llvm-svn: 78581
2009-08-10 18:41:10 +00:00
Owen Anderson
4cd02c843b Change the MDNode uniquing to a ValueMap, at Devang's request.
llvm-svn: 78577
2009-08-10 18:16:08 +00:00
Chris Lattner
3e6da637f6 split MachO section handling stuff out to its out .h/.cpp file.
llvm-svn: 78576
2009-08-10 18:15:01 +00:00
David Greene
91e0e06670 Add support for printing loop structure information in asm comments.
This definitely slows down asm output so put it under an -asm-exuberant
flag.

This information is useful when doing static analysis of performance
issues.

llvm-svn: 78567
2009-08-10 16:38:07 +00:00
David Goodwin
3245141543 Post RA scheduler changes. Introduce a hazard recognizer that uses the target schedule information to accurately model the pipeline. Update the scheduler to correctly handle multi-issue targets.
llvm-svn: 78563
2009-08-10 15:55:25 +00:00
Daniel Dunbar
86ddd268b4 Add support for a user supplied pointer argument to llvm_install_error_handler.
llvm-svn: 78553
2009-08-10 03:36:26 +00:00
Chris Lattner
cc70d578be Make the big switch: Change MCSectionMachO to represent a section *semantically*
instead of syntactically as a string.  This means that it keeps track of the 
segment, section, flags, etc directly and asmprints them in the right format.
This also includes parsing and validation support for llvm-mc and 
"attribute(section)", so we should now start getting errors about invalid 
section attributes from the compiler instead of the assembler on darwin.

Still todo: 
1) Uniquing of darwin mcsections
2) Move all the Darwin stuff out to MCSectionMachO.[cpp|h]
3) there are a few FIXMEs, for example what is the syntax to get the
   S_GB_ZEROFILL segment type?

llvm-svn: 78547
2009-08-10 01:39:42 +00:00
Chris Lattner
e024b843cd add a simple back() method to StringRef.
llvm-svn: 78544
2009-08-10 00:44:02 +00:00
Bob Wilson
326491672e Change Neon table lookup (VTBL) and table extension (VTBX) intrinsics to
take the table vectors as separate arguments, instead of the previous
approach where they were combined into one big vector.

llvm-svn: 78525
2009-08-09 06:03:09 +00:00
Daniel Dunbar
5a6c69d37d Extend comment on ParserMatchClass .td field, and add some missing
classes for X86.

llvm-svn: 78524
2009-08-09 06:00:04 +00:00
Daniel Dunbar
dff8502076 llvm-mc/AsmParser: Define match classes in the .td file.
-2 FIXMEs.

llvm-svn: 78523
2009-08-09 05:18:30 +00:00
Daniel Dunbar
ff95e6d5f8 STLExtras: Add less_ptr.
llvm-svn: 78521
2009-08-09 03:36:59 +00:00
Chris Lattner
9e2c3aa666 sink the 'name' and 'isdirective' state out of MCSection into its derived classes.
This totally optimizes PIC16 sections by not having an 'isdirective' bit anymore!! ;-)

llvm-svn: 78517
2009-08-08 23:39:42 +00:00