[AArch64] Add support for dllimport of values and functions
authorMartin Storsjo <martin@martin.st>
Wed, 25 Oct 2017 07:25:18 +0000 (07:25 +0000)
committerMartin Storsjo <martin@martin.st>
Wed, 25 Oct 2017 07:25:18 +0000 (07:25 +0000)
commit373c8efa1e2e35324878b83027e20b3970876e1a
treeb5362447e34d361b7278ef947777f14e0aa2a404
parent8a752b77a2868066237f9ec4c5c9b292f9983afa
[AArch64] Add support for dllimport of values and functions

Previously, the dllimport attribute did the right thing in terms
of treating it as a pointer to a value, but this makes sure the
names get mangled properly, and calls to such functions load the
function from the __imp_ pointer.

This is based on SVN r212431 and r212430 where the same was
implemented for ARM.

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

llvm-svn: 316555
llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
llvm/lib/Target/AArch64/AArch64ISelLowering.h
llvm/lib/Target/AArch64/AArch64MCInstLower.cpp
llvm/lib/Target/AArch64/Utils/AArch64BaseInfo.h
llvm/test/CodeGen/AArch64/dllimport.ll [new file with mode: 0644]