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

48564 Commits

Author SHA1 Message Date
Duncan Sands
7dfdc32405 String constants are now output with private linkage.
llvm-svn: 75777
2009-07-15 12:09:18 +00:00
Daniel Dunbar
590904c36b Kill off unused TargetMachineRegistry methods and ivars.
llvm-svn: 75774
2009-07-15 11:48:36 +00:00
Daniel Dunbar
1d5b4e20c9 Migrate llc and the JIT to using the TargetRegistry for lookups.
- They still use the TargetMachineRegistry to populate the contents of the
   -march option (via the listener interface). We can't just populate it in the
   option parser because we can't expect the TargetRegistry to be populated yet
   (we no longer rely on static constructors).

 - There are a couple ways to finish killing off TargetMachineRegistry, but I
   haven't figured out the cleanest one yet...

llvm-svn: 75773
2009-07-15 11:36:15 +00:00
Daniel Dunbar
25ad58480b Include the Target& in the TargetMachineRegisterEntry.
llvm-svn: 75772
2009-07-15 11:23:49 +00:00
Daniel Dunbar
f69bd722c3 Allow multiple registrations of the same target.
- This doesn't necessarily seem like a good idea, but the JIT unittest
   currently relies on it.

llvm-svn: 75769
2009-07-15 10:32:44 +00:00
Daniel Dunbar
14503ce849 Initialize the target info via the InitializeNativeTarget() hook.
llvm-svn: 75768
2009-07-15 10:29:55 +00:00
Daniel Dunbar
e4ac57c0d1 Switch some obvious clients to using the new TargetRegistry.
llvm-svn: 75767
2009-07-15 10:05:03 +00:00
Daniel Dunbar
61ce410af9 Reimplement TargetMachineRegistry in terms of TargetRegistry.
- This is a temporary hack to aid in incremental refactoring, for now we
   allocate a new TargetMachineRegistryEntry on every getClosest... call.

 - No intended functionality change, other than the leaked memory.

llvm-svn: 75766
2009-07-15 09:53:37 +00:00
Daniel Dunbar
79a15cde61 Mark Target's creation routines as const.
llvm-svn: 75763
2009-07-15 09:38:10 +00:00
Daniel Dunbar
a2af870bd7 Register Target's TargetMachine and AsmPrinter in the new registry.
- This abuses TargetMachineRegistry's constructor for now, this will get
   cleaned up in time.

llvm-svn: 75762
2009-07-15 09:22:31 +00:00
Daniel Dunbar
0e528c0005 Fix thinko
llvm-svn: 75760
2009-07-15 08:56:49 +00:00
Daniel Dunbar
2b6a680bf6 Detect write failures on raw_fd_ostream.
llvm-svn: 75758
2009-07-15 08:11:46 +00:00
Daniel Dunbar
0bfc229e3a Tweak CMake component lookup, I misunderstood what was happening here.though. :(
llvm-svn: 75757
2009-07-15 07:52:36 +00:00
Daniel Dunbar
f62be62588 Include Target specific Info initialization routine when initializing all
targets.

llvm-svn: 75756
2009-07-15 07:48:39 +00:00
Daniel Dunbar
9df1ce1251 Teach Makefiles & CMake to link in the <TARGET>Info library when linking the
TARGET component.
 - Also, updated some CMake library dependencies, it is still missing some
   though. :(

llvm-svn: 75755
2009-07-15 07:43:34 +00:00
Daniel Dunbar
4a3e98b0e0 Fix stupid thinko
llvm-svn: 75754
2009-07-15 07:37:49 +00:00
Daniel Dunbar
18e781dae6 Address some review comments on TargetRegistry.
llvm-svn: 75753
2009-07-15 07:09:29 +00:00
Daniel Dunbar
dbeda6179e Add TargetInfo directories to CMake's list.
llvm-svn: 75752
2009-07-15 07:04:27 +00:00
Daniel Dunbar
b70d5cdfe1 Add TargetInfo libraries for all targets.
- Intended to match current TargetMachine implementations.

 - No facilities for linking these in yet.

llvm-svn: 75751
2009-07-15 06:35:19 +00:00
Evan Cheng
6408cda38d Move load / store folding alignment require into the table(s).
llvm-svn: 75749
2009-07-15 06:10:07 +00:00
Ted Kremenek
e6322544c4 Update CMake file.
llvm-svn: 75746
2009-07-15 05:39:55 +00:00
Chris Lattner
f90dad59d2 rename decorateName -> DecorateCygMingName, make it assert if not
cygming, make the two callers only call it if cygming.  Other minor
cleanups.

llvm-svn: 75744
2009-07-15 04:55:56 +00:00
Chris Lattner
48e30f6d1f eliminate the Mangler::PreserveAsmNames bit, the sole client of this
can do it perfectly well itself.

llvm-svn: 75743
2009-07-15 04:50:47 +00:00
Chris Lattner
ac3968ea1d remove printSuffixedName.
llvm-svn: 75742
2009-07-15 04:42:49 +00:00
Chris Lattner
151877b93e convert arm/darwin stubs to use the mangler to synthesize all the names instead of
doing it with printSuffixedName.

llvm-svn: 75741
2009-07-15 04:41:01 +00:00
Daniel Dunbar
cc2e2f1506 Add new TargetRegistry.
Targets implement a single global Target structure which will live in a new
<Target>/TargetInfo library; this will be present in any image which the target
is usable in.
 - Optional target specific classes can then be registered and attached to the
   Target description.

 - Registration for normal Targets will be done via the initialization functions
   instead of using static constructors.

 - This allows clients to use a single interface to obtain target data, without
   requiring the code generator be linked in. It also provides a natural
   extension point for adding new optional target data (assembler parser,
   disassembler, etc.).

 - This also provides a new entry point for obtaining a target for a particular
   triple (without a module).

 - Not yet used, however this should eventually replace the TargetMachineRegistry.

llvm-svn: 75739
2009-07-15 04:24:58 +00:00
Chris Lattner
499fe29f12 fix an arm codegen bug (the same as PR4482 on ppc) where available_externally
symbols were not getting stubs.  While I'm at it, add a big testcase for
stub generation to make sure I don't break anything.

llvm-svn: 75737
2009-07-15 04:12:33 +00:00
Chris Lattner
dd01e838c8 convert [Hidden]GVNonLazyPtrs to compute the global and stub names
with the mangler (like x86 and ppc), instead of going through 
printSuffixedName.

llvm-svn: 75736
2009-07-15 03:12:43 +00:00
Chris Lattner
e65cf5546b use makeNameProper to add the globalprefix instead of doing it manually.
llvm-svn: 75734
2009-07-15 03:01:23 +00:00
Chris Lattner
0c13774a29 get the PPC stub temporary label from the mangler instead of
using horrible string hacking.  This gives us a different label,
but it's just an assembler temporary, so the name doesn't matter.

llvm-svn: 75733
2009-07-15 02:56:53 +00:00
Chris Lattner
0b4dc240bd turn some if/then's into ?:
llvm-svn: 75732
2009-07-15 02:36:21 +00:00
Chris Lattner
34f25a514f eliminate a bunch of printSuffixedName's by using info computed from
Mangler in FnStubs.

llvm-svn: 75731
2009-07-15 02:33:19 +00:00
Chris Lattner
5c6ad7d426 convert FnStubs to using a more structured form, eliminating
a couple instances of printSuffixedName (in favor of having
the mangler do stuff).

llvm-svn: 75729
2009-07-15 02:28:57 +00:00
Chris Lattner
4fd9c770a6 actually $stub labels *are* private, I just missed that
printSuffixedName automatically does this.

llvm-svn: 75727
2009-07-15 01:53:36 +00:00
Chris Lattner
1c4b831cb2 convert this to filecheck style and make it a test of darwin/PPC's
extremely elaborate pic/nopic stubs.

llvm-svn: 75726
2009-07-15 01:43:31 +00:00
Chris Lattner
6f7ab678c9 simplify this test to test the esentials.
llvm-svn: 75725
2009-07-15 01:32:33 +00:00
Ryan Flynn
39eadb4ce5 test commit; add self
llvm-svn: 75724
2009-07-15 01:32:31 +00:00
Dan Gohman
6cc9cb6dc4 Fix indentation.
llvm-svn: 75723
2009-07-15 01:26:32 +00:00
Dan Gohman
81885d5b80 Make makeLoopInvariant report whether it made any changes or not,
and use this to simplify more code.

llvm-svn: 75722
2009-07-15 01:25:43 +00:00
Chris Lattner
84323b260d $stub references should not be private ("L") labels.
llvm-svn: 75721
2009-07-15 01:23:13 +00:00
Chris Lattner
2f7a01f535 simplify "EmitExternalGlobal": it is only used to output a
reference to the personality function for a module, and
those are all added to the GVStubs array by looping
over MMI->getPersonalities()

llvm-svn: 75720
2009-07-15 01:16:38 +00:00
Chris Lattner
b43823c79d Convert GVStubs and HiddenGVStubs to work more like the X86 backend, this
eliminates a bunch of uses of "printSuffixedName" and "getGlobalLinkName".

llvm-svn: 75719
2009-07-15 01:14:44 +00:00
Chris Lattner
441db03418 minor cleanups: only switch sections once before all function stubs, instead of
before each one.

llvm-svn: 75718
2009-07-15 00:55:58 +00:00
Dan Gohman
1e946cc1a7 llvm-c/Core.h is no longer needed in lto.h, and it brings in
several unwanted dependencies.

llvm-svn: 75717
2009-07-15 00:47:00 +00:00
Chris Lattner
32757b2838 Fix a fixme, patch by Ryan Flynn!
llvm-svn: 75716
2009-07-15 00:36:04 +00:00
Evan Cheng
ec2df6b4f5 control reaches end of non-void function.
llvm-svn: 75714
2009-07-14 23:55:32 +00:00
Kevin Enderby
3e47cf1dda Added llvm-mc support for parsing the .include directive.
llvm-svn: 75711
2009-07-14 23:21:55 +00:00
Chris Lattner
0d3021c94c minor syntax cleanup
llvm-svn: 75707
2009-07-14 23:14:10 +00:00
Owen Anderson
8c85061ee6 Move EVER MORE stuff over to LLVMContext.
llvm-svn: 75703
2009-07-14 23:09:55 +00:00
Daniel Dunbar
df466c8f3d Fix path name.
llvm-svn: 75697
2009-07-14 22:58:03 +00:00