]> granicus.if.org Git - clang/commit
CodeGen: support blocks on COFF targets in DLLs
authorSaleem Abdulrasool <compnerd@compnerd.org>
Sat, 28 May 2016 19:41:35 +0000 (19:41 +0000)
committerSaleem Abdulrasool <compnerd@compnerd.org>
Sat, 28 May 2016 19:41:35 +0000 (19:41 +0000)
commite9b4ce30ae4bfb1276c096b837e5f060996c2f71
tree614a66c2fad60ace095c16027209478e800e13ea
parentdf03e52a20e3e9f34d23cdb6ec7974e71fcb2ecc
CodeGen: support blocks on COFF targets in DLLs

This extends the blocks support to support blocks with a dynamically linked
blocks runtime.  The previous code generation would work only for static builds
of the blocks runtime.  Mark the block "isa" pointers and functions as dllimport
if no explicit declaration marked with __declspec(dllexport) is found.  This
additional check allows for the use of the functionality in the runtime library
if desired.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@271138 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/CGBlocks.cpp
test/CodeGen/blocks-windows.c [new file with mode: 0644]