[PATCH] D53311: [llvm-objcopy] Introduce dispatch mechanism based on input type

Jake Ehrlich via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 23 07:34:35 PDT 2018


I haven't had an opportunity to look at this. I will look at it today.
Please don't nlland it just yet.

On Tue, Oct 23, 2018, 1:45 AM James Henderson via Phabricator <
reviews at reviews.llvm.org> wrote:

> jhenderson accepted this revision.
> jhenderson added a comment.
> This revision is now accepted and ready to land.
>
> Much better, thanks!
>
> LGTM, although I do have one query about raw binary input. Should this go
> through a similar dispatch mechanism to enable other file formats to read
> in raw binary?
>
>
>
> ================
> Comment at: llvm-objcopy.cpp:655
>      FileBuffer FB(Config.OutputFilename);
> -    BinaryReader Reader(Config.BinaryArch, BufOrErr->get());
> -    executeElfObjcopyOnBinary(Config, Reader, FB,
> -                              getOutputElfType(Config.BinaryArch));
> +    elf::executeObjcopyOnRawBinary(Config, *BufOrErr->get(), FB);
>    } else {
> ----------------
> It seems a bit odd still having mention of elf at this level. Is it
> allowed to read binary input for COFF or Mach-O output?
>
>
> Repository:
>   rL LLVM
>
> https://reviews.llvm.org/D53311
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20181023/43a5de9b/attachment.html>


More information about the llvm-commits mailing list