llvm-project/llvm/lib
Tom Stellard 3d36e5c3e6 Only promote args when function attributes are compatible
Summary:
Check to make sure that the caller and the callee have compatible
function arguments before promoting arguments.  This uses the same
TargetTransformInfo queries that are used to determine if attributes
are compatible for inlining.

The goal here is to avoid breaking ABI when a called function's ABI
depends on a target feature that is not enabled in the caller.

This is a very conservative fix for PR37358.  Ideally we would have a more
sophisticated check for ABI compatiblity rather than checking if the
attributes are compatible for inlining.

Reviewers: echristo, chandlerc, eli.friedman, craig.topper

Reviewed By: echristo, chandlerc

Subscribers: nikic, xbolva00, rkruppe, alexcrichton, llvm-commits

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

llvm-svn: 351296
2019-01-16 05:15:31 +00:00
..
Analysis Only promote args when function attributes are compatible 2019-01-16 05:15:31 +00:00
AsmParser Give helper classes/functions local linkage. NFC. 2019-01-12 18:36:22 +00:00
BinaryFormat llvm-dwarfdump: Improve/fix pretty printing of array dimensions 2018-12-19 19:34:24 +00:00
Bitcode [LTO] Record whether LTOUnit splitting is enabled in index 2019-01-11 18:31:57 +00:00
CodeGen [GISel]: Add support for CSEing continuously during GISel passes. 2019-01-16 00:40:37 +00:00
DebugInfo [CodeView] More appropriate name and type for a Microsoft precompiled headers parameter. NFC 2019-01-07 13:53:16 +00:00
Demangle [llvm-undname] Add support for demangling msvc's noexcept types. 2019-01-08 21:05:51 +00:00
ExecutionEngine Revert r351138 "[ORC] Move ORC Core symbol map and set types into their own 2019-01-15 15:21:13 +00:00
FuzzMutate [New PM] Introducing PassInstrumentation framework 2018-09-20 17:08:45 +00:00
Fuzzer
IR [EH] Rename llvm.x86.seh.recoverfp intrinsic to llvm.eh.recoverfp 2019-01-16 00:37:13 +00:00
IRReader
LTO [LTO] Record whether LTOUnit splitting is enabled in index 2019-01-11 18:31:57 +00:00
LineEditor
Linker ThinLTO: Do not import debug info for imported global constants 2018-12-05 21:42:17 +00:00
MC [WebAssembly] Store section alignment as a power of 2 2019-01-16 01:34:48 +00:00
MCA [MCA] Fix wrong definition of ResourceUnitMask in DefaultResourceStrategy. 2019-01-10 13:59:13 +00:00
Object [Object] Return a symbol_iterator, rather than a basic_symbol_iterator, from 2019-01-14 22:05:12 +00:00
ObjectYAML [WebAssembly] Massive instruction renaming 2019-01-08 06:25:55 +00:00
OptRemarks Reland: [OptRemarks] Add library for parsing optimization remarks 2018-10-10 18:43:42 +00:00
Option [opt] Change the parameter of OptTable::PrintHelp from Name to Usage and don't append "[options] <inputs>" 2018-10-10 00:15:31 +00:00
Passes [LoopUnroll] add parsing for unroll parameters in -passes pipeline 2019-01-10 10:01:53 +00:00
ProfileData [PGO] Use SourceFileName rather module name in PGOFuncName 2019-01-08 22:39:47 +00:00
Support [VFS] Move RedirectingFileSystem interface into header (NFC) 2019-01-15 22:36:41 +00:00
TableGen Let TableGen write output only if it changed, instead of doing so in cmake, attempt 2 2018-12-19 13:35:53 +00:00
Target [GISel]: Add support for CSEing continuously during GISel passes. 2019-01-16 00:40:37 +00:00
Testing Fix error with SmallString implicit conversion. 2018-09-06 22:47:32 +00:00
TextAPI [TextAPI][elfabi] Fix YAML support for weak symbols 2018-12-21 20:45:58 +00:00
ToolDrivers [opt] Change the parameter of OptTable::PrintHelp from Name to Usage and don't append "[options] <inputs>" 2018-10-10 00:15:31 +00:00
Transforms Only promote args when function attributes are compatible 2019-01-16 05:15:31 +00:00
WindowsManifest
XRay [Object] Rename getRelrRelocationType to getRelativeRelocationType 2018-12-14 07:46:58 +00:00
CMakeLists.txt [llvm-mca] Move llvm-mca library to llvm/lib/MCA. 2018-12-17 08:08:31 +00:00
LLVMBuild.txt [llvm-mca] Move llvm-mca library to llvm/lib/MCA. 2018-12-17 08:08:31 +00:00