1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-24 05:23:45 +02:00
llvm-mirror/lib/Transforms/IPO
David L. Jones 268960185f [Analysis] Add LibFunc_ prefix to enums in TargetLibraryInfo. (NFC)
Summary:
The LibFunc::Func enum holds enumerators named for libc functions.
Unfortunately, there are real situations, including libc implementations, where
function names are actually macros (musl uses "#define fopen64 fopen", for
example; any other transitively visible macro would have similar effects).

Strictly speaking, a conforming C++ Standard Library should provide any such
macros as functions instead (via <cstdio>). However, there are some "library"
functions which are not part of the standard, and thus not subject to this
rule (fopen64, for example). So, in order to be both portable and consistent,
the enum should not use the bare function names.

The old enum naming used a namespace LibFunc and an enum Func, with bare
enumerators. This patch changes LibFunc to be an enum with enumerators prefixed
with "LibFFunc_". (Unfortunately, a scoped enum is not sufficient to override
macros.)

There are additional changes required in clang.

Reviewers: rsmith

Subscribers: mehdi_amini, mzolotukhin, nemanjai, llvm-commits

Differential Revision: https://reviews.llvm.org/D28476

llvm-svn: 292848
2017-01-23 23:16:46 +00:00
..
AlwaysInliner.cpp [PM] Teach the always inliner in the new pass manager to support 2016-12-26 23:43:27 +00:00
ArgumentPromotion.cpp Revert @llvm.assume with operator bundles (r289755-r289757) 2016-12-19 08:22:17 +00:00
BarrierNoopPass.cpp
CMakeLists.txt IPO: Introduce ThinLTOBitcodeWriter pass. 2016-12-16 00:26:30 +00:00
ConstantMerge.cpp [PM] Remove support for omitting the AnalysisManager argument to new 2016-06-17 00:11:01 +00:00
CrossDSOCFI.cpp Consistently use ModuleAnalysisManager 2016-08-09 00:28:38 +00:00
DeadArgumentElimination.cpp Replace some callers of setTailCall with setTailCallKind 2016-11-25 22:35:09 +00:00
ElimAvailExtern.cpp [PM] Remove support for omitting the AnalysisManager argument to new 2016-06-17 00:11:01 +00:00
ExtractGV.cpp Apply clang-tidy's modernize-loop-convert to most of lib/Transforms. 2016-06-26 12:28:59 +00:00
ForceFunctionAttrs.cpp [PM] Remove support for omitting the AnalysisManager argument to new 2016-06-17 00:11:01 +00:00
FunctionAttrs.cpp Revert @llvm.assume with operator bundles (r289755-r289757) 2016-12-19 08:22:17 +00:00
FunctionImport.cpp [ThinLTO] Drop non-prevailing non-ODR weak to declarations 2017-01-20 21:54:58 +00:00
GlobalDCE.cpp [PM] Replace the hard invalidate in JumpThreading for LVI with correct 2017-01-23 08:33:24 +00:00
GlobalOpt.cpp [Analysis] Add LibFunc_ prefix to enums in TargetLibraryInfo. (NFC) 2017-01-23 23:16:46 +00:00
GlobalSplit.cpp [GlobalSplit] Port to the new pass manager. 2016-11-21 00:28:23 +00:00
InferFunctionAttrs.cpp Consistently use ModuleAnalysisManager 2016-08-09 00:28:38 +00:00
Inliner.cpp [PM] Clear any analyses for a dead function after inlining it and before 2017-01-23 07:03:41 +00:00
InlineSimple.cpp Improve PGO support for the new inliner 2017-01-20 22:44:04 +00:00
Internalize.cpp Consistently use ModuleAnalysisManager 2016-08-09 00:28:38 +00:00
IPConstantPropagation.cpp Apply clang-tidy's modernize-loop-convert to most of lib/Transforms. 2016-06-26 12:28:59 +00:00
IPO.cpp Introduce GlobalSplit pass. 2016-11-16 23:40:26 +00:00
LLVMBuild.txt Add missing library dep. 2016-12-16 00:43:00 +00:00
LoopExtractor.cpp Apply clang-tidy's modernize-loop-convert to most of lib/Transforms. 2016-06-26 12:28:59 +00:00
LowerTypeTests.cpp LowerTypeTests: Fix use-after-free. Found by asan/msan. 2017-01-21 01:57:44 +00:00
MergeFunctions.cpp MergeFunctions: Preserve debug info in thunks, under option -mergefunc-preserve-debug-info 2017-01-21 02:02:56 +00:00
PartialInlining.cpp Apply clang-tidy's performance-unnecessary-value-param to LLVM. 2017-01-13 14:39:03 +00:00
PassManagerBuilder.cpp IPO, LTO: Plumb the summary from the LTO API into the pass manager. 2017-01-20 22:18:52 +00:00
PruneEH.cpp [PruneEH] Be correct in the face IPO 2016-10-03 19:35:30 +00:00
SampleProfile.cpp Revert "Refactor SampleProfile.cpp to move computation inside a branch. (NFC)" 2017-01-23 22:40:08 +00:00
StripDeadPrototypes.cpp [PM] Remove support for omitting the AnalysisManager argument to new 2016-06-17 00:11:01 +00:00
StripSymbols.cpp [IR] Remove the DIExpression field from DIGlobalVariable. 2016-12-20 02:09:43 +00:00
ThinLTOBitcodeWriter.cpp ThinLTOBitcodeWriter: Clear comdats on filtered globals. 2017-01-18 20:03:02 +00:00
WholeProgramDevirt.cpp WholeProgramDevirt: Teach the pass to handle structs of arrays. 2016-12-09 01:10:11 +00:00