ARM: properly lower dllimport'ed global values
authorSaleem Abdulrasool <compnerd@compnerd.org>
Mon, 7 Jul 2014 05:18:35 +0000 (05:18 +0000)
committerSaleem Abdulrasool <compnerd@compnerd.org>
Mon, 7 Jul 2014 05:18:35 +0000 (05:18 +0000)
commit763f9a50a5234fb27c0f03efd54b87ccdd7ca080
tree1e7b41fe1ff5795440dfad0362468ca395b5db87
parent220a0448887e36265efcd590b372f41dec4c7359
ARM: properly lower dllimport'ed global values

This completes the handling for DLL import storage symbols when lowering
instructions.  A DLL import storage symbol must have an additional load
performed prior to use.  This is applicable to variables and functions.

This is particularly important for non-function symbols as it is possible to
handle function references by emitting a thunk which performs the translation
from the unprefixed __imp_ symbol to the proper symbol (although, this is a
non-optimal lowering).  For a variable symbol, no such thunk can be
accommodated.

llvm-svn: 212431
llvm/lib/Target/ARM/ARMISelLowering.cpp
llvm/test/CodeGen/ARM/Windows/dllimport.ll [new file with mode: 0644]