[PATCH] D129507: [llvm-objcopy] Add option to dump embedded offloading images

Joseph Huber via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 11 11:48:15 PDT 2022


jhuber6 created this revision.
jhuber6 added reviewers: jdoerfert, tianshilei1992, MaskRay, yaxunl, tra, saiislam, alexander-shaposhnikov, jhenderson, JonChesterfield.
Herald added subscribers: StephenFan, abrachet, hiraditya, emaste.
Herald added a reviewer: rupprecht.
Herald added a project: All.
jhuber6 requested review of this revision.
Herald added subscribers: llvm-commits, sstefan1.
Herald added a project: LLVM.

We use a special format to create fatbinaries for offloading
compilation. This will store the results from many different offloading
compilations inside the host ELF. A previous patch added support for
viewing these in `llvm-objdump` but a user may want to be able to
extract the contents and inspect them. This patch adds a new option
`--dump-offloading N=<file>` which dumps the N-th found offloading image
to the specified file.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D129507

Files:
  llvm/include/llvm/ObjCopy/CommonConfig.h
  llvm/lib/ObjCopy/ConfigManager.cpp
  llvm/lib/ObjCopy/ELF/ELFObjcopy.cpp
  llvm/test/tools/llvm-objcopy/Offloading/Inputs/binary.yaml
  llvm/test/tools/llvm-objcopy/Offloading/alignment.test
  llvm/test/tools/llvm-objcopy/Offloading/binary.test
  llvm/test/tools/llvm-objcopy/Offloading/failure.test
  llvm/test/tools/llvm-objcopy/Offloading/non-elf.test
  llvm/test/tools/llvm-objcopy/Offloading/not-found.test
  llvm/tools/llvm-objcopy/ObjcopyOptions.cpp
  llvm/tools/llvm-objcopy/ObjcopyOpts.td

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D129507.443703.patch
Type: text/x-patch
Size: 14642 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220711/cef1ea96/attachment.bin>


More information about the llvm-commits mailing list