[all-commits] [llvm/llvm-project] bf0629: [OffloadPackager] Add option to extract files from...

Joseph Huber via All-commits all-commits at lists.llvm.org
Tue Aug 23 05:57:44 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: bf062954364d69e0fb8e3e04ef3a65c432e8bd50
      https://github.com/llvm/llvm-project/commit/bf062954364d69e0fb8e3e04ef3a65c432e8bd50
  Author: Joseph Huber <jhuber6 at vols.utk.edu>
  Date:   2022-08-23 (Tue, 23 Aug 2022)

  Changed paths:
    M clang/docs/ClangOffloadPackager.rst
    A clang/test/Driver/offload-packager.c
    M clang/tools/clang-offload-packager/ClangOffloadPackager.cpp

  Log Message:
  -----------
  [OffloadPackager] Add option to extract files from images

We use the `clang-offload-packager` too bundle many files into a single
binary format containing metadata. This is used for offloading
compilation which may contain multiple device binaries of different
types and architectures in a single file. We use this special binary
format to store these files along with some necessary metadata around
them. We use this format because of the difficulty of determining the
filesize of the various binary inputs that will be passed to the
offloading toolchain rather than engineering a solution for each input.

Previously we only support packaing many files into a single binary.
This patch adds support for doing the reverse by using the same
`--image=` syntax. To unpackage a binary we now present an input file
instead of an output.

Reviewed By: tra

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




More information about the All-commits mailing list