[PATCH] llvm-link: Add -override flag to prefer duplicate symbols from one module.

Luqman Aden me+llvm at luqman.ca
Wed Apr 15 14:51:08 PDT 2015


This adds an -override flag to llvm-link which lets you specify further .bc's which should take precedent in case you hit duplicate symbols.

The intended use case is for example you have a large module from which you extract a single function. You then modify this functions (perhaps by hand or running it through opt) and then want to merge it back into the original module. If you simply tried to pass both to llvm-link now you'd get an error about duplicate symbols.

REPOSITORY
  rL LLVM

http://reviews.llvm.org/D9041

Files:
  include/llvm/Linker/Linker.h
  lib/Linker/LinkModules.cpp
  test/tools/llvm-link/Inputs/foo.ll
  test/tools/llvm-link/hello.ll
  test/tools/llvm-link/lit.local.cfg
  tools/llvm-link/llvm-link.cpp

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D9041.23804.patch
Type: text/x-patch
Size: 5350 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150415/f7f9e3e8/attachment.bin>


More information about the llvm-commits mailing list