]> granicus.if.org Git - clang/commit
Allow bundle size to be 0 in clang-offload-bundler
authorYaxun Liu <Yaxun.Liu@amd.com>
Tue, 5 Mar 2019 17:52:32 +0000 (17:52 +0000)
committerYaxun Liu <Yaxun.Liu@amd.com>
Tue, 5 Mar 2019 17:52:32 +0000 (17:52 +0000)
commita73ceaf4aed15d968b17fafbd1b1606ccbd986e5
treecfc9ffd8c1ed82630cb0bb97590c2b7371f72188
parent8650dc5d838e74671340f7bca62beedf75ae8a54
Allow bundle size to be 0 in clang-offload-bundler

HIP uses clang-offload-bundler to create fat binary. The bundle for host is empty.
Currently clang-offload-bundler checks if the bundle size is 0 when unbundling.
If so it will exit without unbundling the remaining bundles. This causes
clang-offload-bundler not being able to unbundle fat binaries generated for HIP.

This patch allows bundles size to be 0 when clang-offload-bundler unbundles
input files.

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

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@355419 91177308-0d34-0410-b5e6-96231b3b80d8
tools/clang-offload-bundler/ClangOffloadBundler.cpp