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

8746 Commits

Author SHA1 Message Date
David Greene
08b3d807e8 This increases the maximum for MVT::LAST_VALUETYPE
This change doubles the allowable value for MVT::LAST_VALUETYPE. It does
this by doing several things.

1. Introduces MVT::MAX_ALLOWED_LAST_VALUETYPE which in this change has a
value of 64.  This value contains the current maximum for the
MVT::LAST_VALUETYPE.

2. Instead of checking "MVT::LAST_VALUETYPE <= 32", all of those uses
now become "MVT::LAST_VALUETYPE <= MVT::MAX_ALLOWED_LAST_VALUETYPE"

3. Changes the dimension of the ValueTypeActions from 2 elements to four
elements and adds comments ahead of the declaration indicating the it is
"(MVT::MAX_ALLOWED_LAST_VALUETYPE/32) * 2".  This at least lets us find
what is affected if and when MVT::MAX_ALLOWED_LAST_VALUETYPE gets
changed.

4. Adds initializers for the new elements of ValueTypeActions.

This does NOT add any types in MVT. That would be done separately.

This doubles the size of ValueTypeActions from 64 bits to 128 bits and
gives us the freedom to add more types for AVX.

llvm-svn: 74110
2009-06-24 19:41:55 +00:00
Daniel Dunbar
5f2b8ca5e4 Sketch streamer support for .align, .org functionality.
llvm-svn: 74109
2009-06-24 19:25:34 +00:00
Chris Lattner
ee30c14d3b sink management of DwarfWriter & MachineModuleInfo into the AsmPrinter base class.
llvm-svn: 74101
2009-06-24 19:09:55 +00:00
Chris Lattner
0690755320 eliminate the ExtWeakSymbols set from AsmPrinter. This eliminates
a bunch of code from all the targets, and eliminates nondeterministic
ordering of directives being emitted in the output.

llvm-svn: 74096
2009-06-24 18:52:01 +00:00
Chris Lattner
cabe904f79 Rearrange some stuff in MachineOperand and add a new TargetFlags field.
llvm-svn: 74087
2009-06-24 17:54:48 +00:00
Owen Anderson
90f7655f57 Get rid of the global CFGOnly flag by threading a ShortNames parameters through the GraphViz rendering code.
Update other uses in the codebase for this change.

llvm-svn: 74084
2009-06-24 17:37:09 +00:00
Daniel Dunbar
082dc70875 We decided to not worry about Atoms for now, it should be straightforward to
reintroduce them later.

Also, don't require MCSection* when creating a symbol.

llvm-svn: 74081
2009-06-24 17:00:42 +00:00
Daniel Dunbar
4f0c4c766c MCStreamer: Add a few more "symbol attributes".
llvm-svn: 74077
2009-06-24 16:36:52 +00:00
Dan Gohman
725c99702b Remove an obsolete comment and fix some 80-column violations.
llvm-svn: 74059
2009-06-24 04:47:54 +00:00
Chris Lattner
61a6509f6a add trivial support for passing label definitions through the MCStreamer.
This is suboptimal in several aspects, see the commented out assertion.
I need to talk to Daniel about this.

llvm-svn: 74057
2009-06-24 04:31:49 +00:00
Dan Gohman
4f4bda36df Extend ScalarEvolution's multiple-exit support to compute exact
trip counts in more cases.

Generalize ScalarEvolution's isLoopGuardedByCond code to recognize
And and Or conditions, splitting the code out into an
isNecessaryCond helper function so that it can evaluate Ands and Ors
recursively, and make SCEVExpander be much more aggressive about
hoisting instructions out of loops.

test/CodeGen/X86/pr3495.ll has an additional instruction now, but
it appears to be due to an arbitrary register allocation difference.

llvm-svn: 74048
2009-06-24 01:18:18 +00:00
Daniel Dunbar
0e5051b251 Start MCAsmStreamer implementation.
llvm-svn: 74044
2009-06-24 01:03:06 +00:00
Dan Gohman
3bf5d76081 Move the special cases for constants out of getUnknown and into
createSCEV. Also, recognize UndefValue in createSCEV.

Change getIntegerSCEV's comment to avoid mentioning FP types,
and re-implement it in terms of getConstant instead of getUnknown.

llvm-svn: 74041
2009-06-24 00:54:57 +00:00
Chris Lattner
1b0e4717b3 stub out a trivial constructor method.
llvm-svn: 74038
2009-06-24 00:51:35 +00:00
Dan Gohman
9ccdc738a9 Add an isAllOnesValue utility function, similar to isZero and isOne.
llvm-svn: 74032
2009-06-24 00:30:26 +00:00
Bob Wilson
7bd642b80c Provide InitializeAllTargets and InitializeNativeTarget functions in the
C bindings.  Change all the backend "Initialize" functions to have C linkage.
Change the "llvm/Config/Targets.def" header to use C-style comments to avoid
compile warnings.

llvm-svn: 74026
2009-06-23 23:59:40 +00:00
Daniel Dunbar
813ea8a8a7 Update for MCImm -> MCValue rename.
llvm-svn: 74024
2009-06-23 23:39:15 +00:00
Chris Lattner
3962231b43 rename MCImm ->MCValue.
llvm-svn: 74023
2009-06-23 23:31:52 +00:00
Daniel Dunbar
3126e3e4e2 Add comments for the MCStreamer interface.
llvm-svn: 74019
2009-06-23 23:02:31 +00:00
Devang Patel
5fe5a578c7 It is not a good idea to have data member's name match argument's name. In fact, it is a simple receipe to waste an hour or so.
llvm-svn: 74018
2009-06-23 22:25:41 +00:00
Devang Patel
46160f96fb Add DISubprogram::getReturnTypeName()
llvm-svn: 74015
2009-06-23 22:07:48 +00:00
Daniel Dunbar
323218db15 Start flushing out MCContext.
- Lives inside new library lib/MC (LLVMMC.a)

llvm-svn: 74013
2009-06-23 22:01:43 +00:00
Owen Anderson
2d65e89f30 Use atomic operations when accessing statistics, and make the lazy initialization of statistics actually threadsafe.
llvm-svn: 74005
2009-06-23 21:19:38 +00:00
Owen Anderson
5bda03a404 Add atomic multiply and divide operations, built on top of CompareAndSwap.
llvm-svn: 74004
2009-06-23 21:19:04 +00:00
Owen Anderson
226e1d8bda Make timers threadsafe again. This isn't quite as nice as I'd hoped (it uses locking rather than atomic arithmetic),
but should work on all the platforms we care about.

I might revisit this if a totally awesome way to do it occurs to me.

llvm-svn: 74002
2009-06-23 20:52:29 +00:00
Mikhail Glushenkov
f7b3bf53e2 Make llvmc work again.
Chris recently broke llvmc with his Makefile changes (r75379). That patch made
the global change .o -> .a, which caused built-in llvmc plugins to stop working
since plugin initialization in llvmc is based on static variables not referenced
from the main executable. This patch implements auto-generated forced references
to the plugin libraries.

llvm-svn: 74000
2009-06-23 20:46:48 +00:00
Mikhail Glushenkov
a09aae730a Typo.
llvm-svn: 73999
2009-06-23 20:46:00 +00:00
Daniel Dunbar
92eddad1ba Start sketching MCStreamer interface.
llvm-svn: 73994
2009-06-23 20:24:17 +00:00
Owen Anderson
c11dfb46c1 Revert my last series of commits related to Timer and 64-bit atomics. Not all the targets
we care about are capable of supporting it.

llvm-svn: 73993
2009-06-23 20:17:22 +00:00
Bill Wendling
067eae128b Add include file to get the type for in64_t.
llvm-svn: 73991
2009-06-23 20:02:00 +00:00
Chris Lattner
196bfd3908 add a simple MCImm class.
llvm-svn: 73984
2009-06-23 18:58:00 +00:00
Owen Anderson
c2d02066d0 Atomic ops that do arithmetic use signed arithmetic.
llvm-svn: 73980
2009-06-23 18:30:27 +00:00
Owen Anderson
27a85303fe Actually, these need to be signed integers, not unsigned.
llvm-svn: 73978
2009-06-23 18:21:13 +00:00
Owen Anderson
7b3570b242 Use 64-bit integer counters for tracking time, rather than doubles. This will be more atomic op friendly.
llvm-svn: 73974
2009-06-23 18:12:30 +00:00
Owen Anderson
1bea9b9158 Label the existing atomic functions as 32-bit specific, and add a 64-bit one that will be useful in
the near future.

llvm-svn: 73971
2009-06-23 18:01:04 +00:00
Chris Lattner
2b8ea5e0c8 add an accessor.
llvm-svn: 73966
2009-06-23 17:50:34 +00:00
Owen Anderson
e0ff9fb130 Add an atomic add operation.
llvm-svn: 73964
2009-06-23 17:39:31 +00:00
Douglas Gregor
674c7a4c20 Work around build problem with OpenJDK, which defines X86 as a
macro. Fixes PR 4427. Patch by Xerxes Rånby!

llvm-svn: 73961
2009-06-23 17:21:35 +00:00
Owen Anderson
0cab9cae36 Revert r73923, which broke clang.
llvm-svn: 73957
2009-06-23 16:36:10 +00:00
Owen Anderson
f00516f54d Add guards around timer groups, which can be shared.
llvm-svn: 73923
2009-06-22 23:37:06 +00:00
Bob Wilson
6db76aaf10 Add support for ARM's Advanced SIMD (NEON) instruction set.
This is still a work in progress but most of the NEON instruction set
is supported.

llvm-svn: 73919
2009-06-22 23:27:02 +00:00
Owen Anderson
422b2c613b Remove the parent pointer from SCEV, since it did not end up being needed.
llvm-svn: 73907
2009-06-22 21:57:23 +00:00
Owen Anderson
c023151c9f SCEVHandle is no more!
llvm-svn: 73906
2009-06-22 21:39:50 +00:00
Bruno Cardoso Lopes
7b196ba30e Add more methods to gather target specific elf stuff
Support for .text relocations, implementing TargetELFWriter overloaded methods for x86/x86_64.
Use a map to track global values to their symbol table indexes
Code cleanup and small fixes

llvm-svn: 73894
2009-06-22 19:16:16 +00:00
Owen Anderson
83b6bbdcb4 Banish global state from ScalarEvolution! SCEV uniquing is now done by tables attached to the ScalarEvolution pass.
This also throws out the SCEV reference counting scheme, as the the SCEVs now have a lifetime controlled by the
ScalarEvolution pass.

Note that SCEVHandle is now a no-op, and will be remove in a future commit.

llvm-svn: 73892
2009-06-22 18:25:46 +00:00
Dan Gohman
cc245913e3 Add a getUMinFromMismatchedTypes helper function.
llvm-svn: 73883
2009-06-22 15:03:27 +00:00
Dan Gohman
d65752db50 Factor out code for computing umin and smin for SCEV expressions into
helper functions. Based on a patch by Nick Lewycky.

llvm-svn: 73869
2009-06-22 03:18:45 +00:00
Dan Gohman
db7860aa40 Teach ScalarEvolution how to analyze loops with multiple exit
blocks, and also exit blocks with multiple conditions (combined
with (bitwise) ands and ors). It's often infeasible to compute an
exact trip count in such cases, but a useful upper bound can often
be found.

llvm-svn: 73866
2009-06-22 00:31:57 +00:00
Dan Gohman
eb0a67278b Fix ScalarEvolution's backedge-taken count computations to check for
overflow when computing a integer division to round up.

Thanks to Nick Lewycky for noticing this!

llvm-svn: 73862
2009-06-21 23:46:38 +00:00
Chris Lattner
dd95ab3ca9 rename SourceMgr::PrintError to PrintMessage.
llvm-svn: 73861
2009-06-21 21:22:11 +00:00