llvm-6502/test/Transforms
Rafael Espindola 1f21e0dd0d Remove the linker_private and linker_private_weak linkages.
These linkages were introduced some time ago, but it was never very
clear what exactly their semantics were or what they should be used
for. Some investigation found these uses:

* utf-16 strings in clang.
* non-unnamed_addr strings produced by the sanitizers.

It turns out they were just working around a more fundamental problem.
For some sections a MachO linker needs a symbol in order to split the
section into atoms, and llvm had no idea that was the case. I fixed
that in r201700 and it is now safe to use the private linkage. When
the object ends up in a section that requires symbols, llvm will use a
'l' prefix instead of a 'L' prefix and things just work.

With that, these linkages were already dead, but there was a potential
future user in the objc metadata information. I am still looking at
CGObjcMac.cpp, but at this point I am convinced that linker_private
and linker_private_weak are not what they need.

The objc uses are currently split in

* Regular symbols (no '\01' prefix). LLVM already directly provides
whatever semantics they need.
* Uses of a private name (start with "\01L" or "\01l") and private
linkage. We can drop the "\01L" and "\01l" prefixes as soon as llvm
agrees with clang on L being ok or not for a given section. I have two
patches in code review for this.
* Uses of private name and weak linkage.

The last case is the one that one could think would fit one of these
linkages. That is not the case. The semantics are

* the linker will merge these symbol by *name*.
* the linker will hide them in the final DSO.

Given that the merging is done by name, any of the private (or
internal) linkages would be a bad match. They allow llvm to rename the
symbols, and that is really not what we want. From the llvm point of
view, these objects should really be (linkonce|weak)(_odr)?.

For now, just keeping the "\01l" prefix is probably the best for these
symbols. If we one day want to have a more direct support in llvm,
IMHO what we should add is not a linkage, it is just a hidden_symbol
attribute. It would be applicable to multiple linkages. For example,
on weak it would produce the current behavior we have for objc
metadata. On internal, it would be equivalent to private (and we
should then remove private).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203866 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-13 23:18:37 +00:00
..
ADCE
AddDiscriminators Pass to emit DWARF path discriminators. 2014-03-03 20:06:11 +00:00
ArgumentPromotion
BBVectorize Change math intrinsic attributes from readonly to readnone. These 2014-03-06 00:18:15 +00:00
BranchFolding Re-commit: Demote EmitRawText call in AsmPrinter::EmitInlineAsm() and remove hasRawTextSupport() call 2014-02-13 14:44:26 +00:00
CodeExtractor
CodeGenPrepare CodeGenPrep: sink extends of illegal types into use block. 2014-03-13 13:36:25 +00:00
ConstantHoisting/X86 [Constant Hoisting] Fix insertion point for constant materialization. 2014-02-08 00:20:49 +00:00
ConstantMerge Remove the linker_private and linker_private_weak linkages. 2014-03-13 23:18:37 +00:00
ConstProp
CorrelatedValuePropagation
DeadArgElim IR: Change inalloca's grammar a bit 2014-03-09 06:41:58 +00:00
DeadStoreElimination
DebugIR
EarlyCSE
FunctionAttrs
GCOVProfiling
GlobalDCE
GlobalOpt Reject alias to undefined symbols in the verifier. 2014-03-12 20:15:49 +00:00
GVN Reject alias to undefined symbols in the verifier. 2014-03-12 20:15:49 +00:00
IndVarSimplify
Inline Set default of inlinecold-threshold to 225. 2014-02-06 01:59:22 +00:00
InstCombine Fix a bug in InstCombine where we would incorrectly attempt to construct a 2014-03-13 22:51:43 +00:00
InstSimplify
Internalize
IPConstantProp
JumpThreading
LCSSA
LICM [LPM] Switch LICM to actively use LCSSA in addition to preserving it. 2014-02-11 12:52:27 +00:00
LoopDeletion
LoopIdiom
LoopReroll
LoopRotate
LoopSimplify [LPM] Switch LICM to actively use LCSSA in addition to preserving it. 2014-02-11 12:52:27 +00:00
LoopStrengthReduce This test need the X86 backend, move it to the X86 sub directory. 2014-03-12 22:03:43 +00:00
LoopUnroll
LoopUnswitch
LoopVectorize LoopVectorizer: Preserve fast-math flags 2014-03-05 21:10:47 +00:00
LowerAtomic IR: add a second ordering operand to cmpxhg for failure 2014-03-11 10:48:52 +00:00
LowerExpectIntrinsic
LowerInvoke
LowerSwitch
Mem2Reg
MemCpyOpt MemCpyOpt: When merging memsets also merge the trivial case of two memsets with the same destination. 2014-03-10 21:05:13 +00:00
MergeFunc
MetaRenamer Reject alias to undefined symbols in the verifier. 2014-03-12 20:15:49 +00:00
ObjCARC Remove the linker_private and linker_private_weak linkages. 2014-03-13 23:18:37 +00:00
PhaseOrdering
PruneEH
Reassociate
Reg2Mem
SampleProfile Use discriminator information in sample profiles. 2014-03-10 22:41:28 +00:00
Scalarizer
ScalarRepl Fix PR18800. llvm intrinsic memcpy takes 5 arguments void @llvm.memcpy.p0i8.p0i8.i32(i8* <dest>, i8* <src>, i32 <len>, i32 <align>, i1 <isvolatile>).The test case incorrectly uses the old format resulting in isVolatile function in MemIntrinsic to crash during SROA transformation.Modified the test case to use correct signature of memcpy and memset. 2014-03-13 04:50:29 +00:00
SCCP
SimplifyCFG Allow switch-to-lookup table for tables with holes by adding bitmask check 2014-03-12 18:35:40 +00:00
Sink
SLPVectorizer Resubmit "[SLPV] Recognize vectorizable intrinsics during SLP vectorization ..." 2014-03-12 20:21:50 +00:00
SROA [SROA] Use the correct index integer size in GEPs through non-default 2014-02-26 10:08:16 +00:00
StripSymbols Add a debug info code generation level to the compile unit metadata 2014-02-27 01:24:56 +00:00
StructurizeCFG
TailCallElim
TailDup