[PATCH] D108690: Explicit approach to controlling symbol visibility
serge via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Aug 25 01:24:24 PDT 2021
serge-sans-paille created this revision.
serge-sans-paille added reviewers: tstellar, dblaikie.
Herald added subscribers: foad, frasercrmck, dexonsmith, jdoerfert, kerbowa, luismarques, apazos, sameer.abuasal, pengfei, s.egerton, dmgreen, Jim, jocewei, PkmX, jfb, the_o, brucehoult, MartinMosbeck, rogfer01, atanasyan, edward-jones, zzheng, jrtc27, niosHD, sabuasal, simoncook, johnrusso, rbar, asb, javed.absar, fedor.sergeev, kbarton, hiraditya, jgravelle-google, sbc100, mgorny, nhaehnle, jvesely, nemanjai, sdardis, dylanmckay, jyknight, dschuff, arsenm, qcolombet, MatzeB, jholewinski.
serge-sans-paille requested review of this revision.
Herald added subscribers: llvm-commits, MaskRay, aheejin.
Herald added a project: LLVM.
Setting -fvisibility=hidden when compiling Target libs has the advantage of
not being intrusive on the codebase, but it also sets the visibility of all
functions within header-only component like ADT. In the end, we endup with
some symbols with hidden visibility within llvm dylib (through the target libs),
and some with external visibility (through other libs). This paves the way for
subtle bugs like https://reviews.llvm.org/D101972
It's easier to reason on explicit, pin-point linkage as provided in this patch.
This also paves the way for a more visibility control in all components,
something -fvisibility=hidden doesn't help with.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D108690
Files:
llvm/include/llvm/ADT/Any.h
llvm/lib/Target/AArch64/AArch64.h
llvm/lib/Target/AArch64/AArch64CallingConvention.h
llvm/lib/Target/AArch64/AArch64ExpandImm.cpp
llvm/lib/Target/AArch64/AArch64ExpandImm.h
llvm/lib/Target/AArch64/AArch64FastISel.cpp
llvm/lib/Target/AArch64/AArch64FrameLowering.h
llvm/lib/Target/AArch64/AArch64GenRegisterBankInfo.def
llvm/lib/Target/AArch64/AArch64ISelLowering.h
llvm/lib/Target/AArch64/AArch64InstrInfo.h
llvm/lib/Target/AArch64/AArch64MCInstLower.h
llvm/lib/Target/AArch64/AArch64MachineFunctionInfo.h
llvm/lib/Target/AArch64/AArch64MacroFusion.cpp
llvm/lib/Target/AArch64/AArch64MacroFusion.h
llvm/lib/Target/AArch64/AArch64PBQPRegAlloc.h
llvm/lib/Target/AArch64/AArch64RegisterInfo.h
llvm/lib/Target/AArch64/AArch64SelectionDAGInfo.h
llvm/lib/Target/AArch64/AArch64StackTaggingPreRA.cpp
llvm/lib/Target/AArch64/AArch64Subtarget.h
llvm/lib/Target/AArch64/AArch64TargetMachine.h
llvm/lib/Target/AArch64/AArch64TargetObjectFile.h
llvm/lib/Target/AArch64/AArch64TargetTransformInfo.h
llvm/lib/Target/AArch64/Disassembler/AArch64Disassembler.h
llvm/lib/Target/AArch64/Disassembler/AArch64ExternalSymbolizer.h
llvm/lib/Target/AArch64/GISel/AArch64CallLowering.h
llvm/lib/Target/AArch64/GISel/AArch64GlobalISelUtils.h
llvm/lib/Target/AArch64/GISel/AArch64InstructionSelector.cpp
llvm/lib/Target/AArch64/GISel/AArch64LegalizerInfo.h
llvm/lib/Target/AArch64/GISel/AArch64PostLegalizerCombiner.cpp
llvm/lib/Target/AArch64/GISel/AArch64PostLegalizerLowering.cpp
llvm/lib/Target/AArch64/GISel/AArch64PostSelectOptimize.cpp
llvm/lib/Target/AArch64/GISel/AArch64PreLegalizerCombiner.cpp
llvm/lib/Target/AArch64/GISel/AArch64RegisterBankInfo.h
llvm/lib/Target/AArch64/MCTargetDesc/AArch64AddressingModes.h
llvm/lib/Target/AArch64/MCTargetDesc/AArch64ELFStreamer.cpp
llvm/lib/Target/AArch64/MCTargetDesc/AArch64ELFStreamer.h
llvm/lib/Target/AArch64/MCTargetDesc/AArch64FixupKinds.h
llvm/lib/Target/AArch64/MCTargetDesc/AArch64InstPrinter.h
llvm/lib/Target/AArch64/MCTargetDesc/AArch64MCAsmInfo.h
llvm/lib/Target/AArch64/MCTargetDesc/AArch64MCExpr.h
llvm/lib/Target/AArch64/MCTargetDesc/AArch64MCTargetDesc.h
llvm/lib/Target/AArch64/MCTargetDesc/AArch64TargetStreamer.cpp
llvm/lib/Target/AArch64/MCTargetDesc/AArch64TargetStreamer.h
llvm/lib/Target/AArch64/MCTargetDesc/AArch64WinCOFFObjectWriter.cpp
llvm/lib/Target/AArch64/MCTargetDesc/AArch64WinCOFFStreamer.cpp
llvm/lib/Target/AArch64/MCTargetDesc/AArch64WinCOFFStreamer.h
llvm/lib/Target/AArch64/SVEIntrinsicOpts.cpp
llvm/lib/Target/AArch64/TargetInfo/AArch64TargetInfo.h
llvm/lib/Target/AArch64/Utils/AArch64BaseInfo.cpp
llvm/lib/Target/AArch64/Utils/AArch64BaseInfo.h
llvm/lib/Target/AMDGPU/AMDGPU.h
llvm/lib/Target/AMDGPU/AMDGPUAliasAnalysis.h
llvm/lib/Target/AMDGPU/AMDGPUArgumentUsageInfo.h
llvm/lib/Target/AMDGPU/AMDGPUAsmPrinter.h
llvm/lib/Target/AMDGPU/AMDGPUCallLowering.h
llvm/lib/Target/AMDGPU/AMDGPUExportClustering.cpp
llvm/lib/Target/AMDGPU/AMDGPUExportClustering.h
llvm/lib/Target/AMDGPU/AMDGPUFrameLowering.h
llvm/lib/Target/AMDGPU/AMDGPUGenRegisterBankInfo.def
llvm/lib/Target/AMDGPU/AMDGPUGlobalISelUtils.h
llvm/lib/Target/AMDGPU/AMDGPUHSAMetadataStreamer.cpp
llvm/lib/Target/AMDGPU/AMDGPUHSAMetadataStreamer.h
llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp
llvm/lib/Target/AMDGPU/AMDGPUISelLowering.h
llvm/lib/Target/AMDGPU/AMDGPUInstrInfo.h
llvm/lib/Target/AMDGPU/AMDGPUInstructionSelector.h
llvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.h
llvm/lib/Target/AMDGPU/AMDGPULibCalls.cpp
llvm/lib/Target/AMDGPU/AMDGPULibFunc.h
llvm/lib/Target/AMDGPU/AMDGPUMIRFormatter.h
llvm/lib/Target/AMDGPU/AMDGPUMachineFunction.h
llvm/lib/Target/AMDGPU/AMDGPUMachineModuleInfo.cpp
llvm/lib/Target/AMDGPU/AMDGPUMachineModuleInfo.h
llvm/lib/Target/AMDGPU/AMDGPUMacroFusion.cpp
llvm/lib/Target/AMDGPU/AMDGPUMacroFusion.h
llvm/lib/Target/AMDGPU/AMDGPUPTNote.h
llvm/lib/Target/AMDGPU/AMDGPUPerfHintAnalysis.h
llvm/lib/Target/AMDGPU/AMDGPUPostLegalizerCombiner.cpp
llvm/lib/Target/AMDGPU/AMDGPUPreLegalizerCombiner.cpp
llvm/lib/Target/AMDGPU/AMDGPUPrintfRuntimeBinding.cpp
llvm/lib/Target/AMDGPU/AMDGPUPropagateAttributes.cpp
llvm/lib/Target/AMDGPU/AMDGPURegBankCombiner.cpp
llvm/lib/Target/AMDGPU/AMDGPURegisterBankInfo.h
llvm/lib/Target/AMDGPU/AMDGPUSubtarget.h
llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.h
llvm/lib/Target/AMDGPU/AMDGPUTargetObjectFile.h
llvm/lib/Target/AMDGPU/AMDGPUTargetTransformInfo.h
llvm/lib/Target/AMDGPU/AMDILCFGStructurizer.cpp
llvm/lib/Target/AMDGPU/Disassembler/AMDGPUDisassembler.h
llvm/lib/Target/AMDGPU/GCNHazardRecognizer.h
llvm/lib/Target/AMDGPU/GCNILPSched.cpp
llvm/lib/Target/AMDGPU/GCNIterativeScheduler.cpp
llvm/lib/Target/AMDGPU/GCNIterativeScheduler.h
llvm/lib/Target/AMDGPU/GCNMinRegStrategy.cpp
llvm/lib/Target/AMDGPU/GCNRegPressure.h
llvm/lib/Target/AMDGPU/GCNSchedStrategy.h
llvm/lib/Target/AMDGPU/GCNSubtarget.h
llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUELFStreamer.h
llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUFixupKinds.h
llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUInstPrinter.h
llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUMCAsmInfo.h
llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUMCCodeEmitter.h
llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUMCTargetDesc.h
llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUTargetStreamer.h
llvm/lib/Target/AMDGPU/R600AsmPrinter.h
llvm/lib/Target/AMDGPU/R600EmitClauseMarkers.cpp
llvm/lib/Target/AMDGPU/R600FrameLowering.h
llvm/lib/Target/AMDGPU/R600ISelLowering.h
llvm/lib/Target/AMDGPU/R600InstrInfo.h
llvm/lib/Target/AMDGPU/R600MachineFunctionInfo.h
llvm/lib/Target/AMDGPU/R600MachineScheduler.h
llvm/lib/Target/AMDGPU/R600RegisterInfo.h
llvm/lib/Target/AMDGPU/R600Subtarget.h
llvm/lib/Target/AMDGPU/SIDefines.h
llvm/lib/Target/AMDGPU/SIFrameLowering.h
llvm/lib/Target/AMDGPU/SIISelLowering.h
llvm/lib/Target/AMDGPU/SIInstrInfo.cpp
llvm/lib/Target/AMDGPU/SIInstrInfo.h
llvm/lib/Target/AMDGPU/SIMachineFunctionInfo.h
llvm/lib/Target/AMDGPU/SIMachineScheduler.cpp
llvm/lib/Target/AMDGPU/SIMachineScheduler.h
llvm/lib/Target/AMDGPU/SIProgramInfo.h
llvm/lib/Target/AMDGPU/SIRegisterInfo.h
llvm/lib/Target/AMDGPU/TargetInfo/AMDGPUTargetInfo.h
llvm/lib/Target/AMDGPU/Utils/AMDGPUAsmUtils.cpp
llvm/lib/Target/AMDGPU/Utils/AMDGPUAsmUtils.h
llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp
llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.h
llvm/lib/Target/AMDGPU/Utils/AMDGPUPALMetadata.h
llvm/lib/Target/AMDGPU/Utils/AMDKernelCodeTUtils.h
llvm/lib/Target/ARC/ARC.h
llvm/lib/Target/ARC/ARCBranchFinalize.cpp
llvm/lib/Target/ARC/ARCFrameLowering.h
llvm/lib/Target/ARC/ARCISelLowering.h
llvm/lib/Target/ARC/ARCInstrInfo.h
llvm/lib/Target/ARC/ARCMCInstLower.h
llvm/lib/Target/ARC/ARCMachineFunctionInfo.h
llvm/lib/Target/ARC/ARCOptAddrMode.cpp
llvm/lib/Target/ARC/ARCRegisterInfo.h
llvm/lib/Target/ARC/ARCSubtarget.h
llvm/lib/Target/ARC/ARCTargetMachine.h
llvm/lib/Target/ARC/ARCTargetStreamer.h
llvm/lib/Target/ARC/ARCTargetTransformInfo.h
llvm/lib/Target/ARC/MCTargetDesc/ARCInfo.h
llvm/lib/Target/ARC/MCTargetDesc/ARCInstPrinter.h
llvm/lib/Target/ARC/MCTargetDesc/ARCMCAsmInfo.h
llvm/lib/Target/ARC/MCTargetDesc/ARCMCTargetDesc.h
llvm/lib/Target/ARC/TargetInfo/ARCTargetInfo.h
llvm/lib/Target/ARM/ARM.h
llvm/lib/Target/ARM/ARMAsmPrinter.h
llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp
llvm/lib/Target/ARM/ARMBaseInstrInfo.h
llvm/lib/Target/ARM/ARMBaseRegisterInfo.h
llvm/lib/Target/ARM/ARMBasicBlockInfo.cpp
llvm/lib/Target/ARM/ARMBasicBlockInfo.h
llvm/lib/Target/ARM/ARMBlockPlacement.cpp
llvm/lib/Target/ARM/ARMCallLowering.h
llvm/lib/Target/ARM/ARMCallingConv.h
llvm/lib/Target/ARM/ARMConstantPoolValue.h
llvm/lib/Target/ARM/ARMFastISel.cpp
llvm/lib/Target/ARM/ARMFeatures.h
llvm/lib/Target/ARM/ARMFrameLowering.h
llvm/lib/Target/ARM/ARMHazardRecognizer.h
llvm/lib/Target/ARM/ARMISelLowering.h
llvm/lib/Target/ARM/ARMInstrInfo.h
llvm/lib/Target/ARM/ARMInstructionSelector.cpp
llvm/lib/Target/ARM/ARMLegalizerInfo.h
llvm/lib/Target/ARM/ARMMachineFunctionInfo.h
llvm/lib/Target/ARM/ARMMacroFusion.cpp
llvm/lib/Target/ARM/ARMMacroFusion.h
llvm/lib/Target/ARM/ARMRegisterBankInfo.cpp
llvm/lib/Target/ARM/ARMRegisterBankInfo.h
llvm/lib/Target/ARM/ARMRegisterInfo.h
llvm/lib/Target/ARM/ARMSelectionDAGInfo.h
llvm/lib/Target/ARM/ARMSubtarget.h
llvm/lib/Target/ARM/ARMTargetMachine.cpp
llvm/lib/Target/ARM/ARMTargetMachine.h
llvm/lib/Target/ARM/ARMTargetObjectFile.h
llvm/lib/Target/ARM/ARMTargetTransformInfo.h
llvm/lib/Target/ARM/AsmParser/ARMAsmParser.cpp
llvm/lib/Target/ARM/Disassembler/ARMDisassembler.cpp
llvm/lib/Target/ARM/MCTargetDesc/ARMAddressingModes.h
llvm/lib/Target/ARM/MCTargetDesc/ARMAsmBackend.h
llvm/lib/Target/ARM/MCTargetDesc/ARMAsmBackendDarwin.h
llvm/lib/Target/ARM/MCTargetDesc/ARMBaseInfo.h
llvm/lib/Target/ARM/MCTargetDesc/ARMELFStreamer.cpp
llvm/lib/Target/ARM/MCTargetDesc/ARMFixupKinds.h
llvm/lib/Target/ARM/MCTargetDesc/ARMInstPrinter.h
llvm/lib/Target/ARM/MCTargetDesc/ARMMCAsmInfo.h
llvm/lib/Target/ARM/MCTargetDesc/ARMMCExpr.h
llvm/lib/Target/ARM/MCTargetDesc/ARMMCTargetDesc.h
llvm/lib/Target/ARM/MCTargetDesc/ARMUnwindOpAsm.h
llvm/lib/Target/ARM/MCTargetDesc/ARMWinCOFFObjectWriter.cpp
llvm/lib/Target/ARM/MVETailPredUtils.h
llvm/lib/Target/ARM/TargetInfo/ARMTargetInfo.h
llvm/lib/Target/ARM/Thumb1FrameLowering.h
llvm/lib/Target/ARM/Thumb1InstrInfo.h
llvm/lib/Target/ARM/Thumb2InstrInfo.h
llvm/lib/Target/ARM/ThumbRegisterInfo.cpp
llvm/lib/Target/ARM/ThumbRegisterInfo.h
llvm/lib/Target/ARM/Utils/ARMBaseInfo.cpp
llvm/lib/Target/ARM/Utils/ARMBaseInfo.h
llvm/lib/Target/AVR/AVR.h
llvm/lib/Target/AVR/AVRAsmPrinter.cpp
llvm/lib/Target/AVR/AVRExpandPseudoInsts.cpp
llvm/lib/Target/AVR/AVRFrameLowering.cpp
llvm/lib/Target/AVR/AVRFrameLowering.h
llvm/lib/Target/AVR/AVRISelDAGToDAG.cpp
llvm/lib/Target/AVR/AVRISelLowering.cpp
llvm/lib/Target/AVR/AVRISelLowering.h
llvm/lib/Target/AVR/AVRInstrInfo.cpp
llvm/lib/Target/AVR/AVRInstrInfo.h
llvm/lib/Target/AVR/AVRMCInstLower.cpp
llvm/lib/Target/AVR/AVRMCInstLower.h
llvm/lib/Target/AVR/AVRMachineFunctionInfo.h
llvm/lib/Target/AVR/AVRRegisterInfo.cpp
llvm/lib/Target/AVR/AVRRegisterInfo.h
llvm/lib/Target/AVR/AVRRelaxMemOperations.cpp
llvm/lib/Target/AVR/AVRSelectionDAGInfo.h
llvm/lib/Target/AVR/AVRSubtarget.cpp
llvm/lib/Target/AVR/AVRSubtarget.h
llvm/lib/Target/AVR/AVRTargetMachine.cpp
llvm/lib/Target/AVR/AVRTargetMachine.h
llvm/lib/Target/AVR/AVRTargetObjectFile.cpp
llvm/lib/Target/AVR/AVRTargetObjectFile.h
llvm/lib/Target/AVR/MCTargetDesc/AVRAsmBackend.cpp
llvm/lib/Target/AVR/MCTargetDesc/AVRAsmBackend.h
llvm/lib/Target/AVR/MCTargetDesc/AVRELFObjectWriter.cpp
llvm/lib/Target/AVR/MCTargetDesc/AVRELFStreamer.cpp
llvm/lib/Target/AVR/MCTargetDesc/AVRELFStreamer.h
llvm/lib/Target/AVR/MCTargetDesc/AVRFixupKinds.h
llvm/lib/Target/AVR/MCTargetDesc/AVRInstPrinter.cpp
llvm/lib/Target/AVR/MCTargetDesc/AVRInstPrinter.h
llvm/lib/Target/AVR/MCTargetDesc/AVRMCAsmInfo.cpp
llvm/lib/Target/AVR/MCTargetDesc/AVRMCAsmInfo.h
llvm/lib/Target/AVR/MCTargetDesc/AVRMCCodeEmitter.cpp
llvm/lib/Target/AVR/MCTargetDesc/AVRMCCodeEmitter.h
llvm/lib/Target/AVR/MCTargetDesc/AVRMCELFStreamer.cpp
llvm/lib/Target/AVR/MCTargetDesc/AVRMCELFStreamer.h
llvm/lib/Target/AVR/MCTargetDesc/AVRMCExpr.cpp
llvm/lib/Target/AVR/MCTargetDesc/AVRMCExpr.h
llvm/lib/Target/AVR/MCTargetDesc/AVRMCTargetDesc.h
llvm/lib/Target/AVR/MCTargetDesc/AVRTargetStreamer.cpp
llvm/lib/Target/AVR/MCTargetDesc/AVRTargetStreamer.h
llvm/lib/Target/AVR/TargetInfo/AVRTargetInfo.cpp
llvm/lib/Target/AVR/TargetInfo/AVRTargetInfo.h
llvm/lib/Target/BPF/BPF.h
llvm/lib/Target/BPF/BPFAbstractMemberAccess.cpp
llvm/lib/Target/BPF/BPFCORE.h
llvm/lib/Target/BPF/BPFFrameLowering.h
(448 more files...)
More information about the llvm-commits
mailing list