Allow global address space forward decls using IDs in .ll files.
authorKarl Schimpf <kschimpf@google.com>
Thu, 3 Sep 2015 18:06:44 +0000 (18:06 +0000)
committerKarl Schimpf <kschimpf@google.com>
Thu, 3 Sep 2015 18:06:44 +0000 (18:06 +0000)
commitb80c5f51a40a9c8c1c6a61e250b8197f74806b8c
treec032442cf4ff65305402c910c0eca10b09c586d1
parent3610c9fe552807eba80b7df8545da5029e1245d6
Allow global address space forward decls using IDs in .ll files.

Summary:
This fixes bugzilla bug 24656. Fixes the case where there is a forward
reference to a global variable using an ID (i.e. @0). It does this by
passing the address space of the initializer pointer for which the
forward referenced global is used.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@246788 91177308-0d34-0410-b5e6-96231b3b80d8
lib/AsmParser/LLParser.cpp
test/Assembler/global-addrspace-forwardref.ll