This is an archive of the discontinued LLVM Phabricator instance.

Link jumptable attributes consistently with unnamed_addr
AbandonedPublic

Authored by tmroeder on Nov 26 2014, 1:33 PM.

Details

Reviewers
None
Summary

This patch changes the module linker to not unset unnamed_addr on merged functions that have the jumptable attribute. As the test case demonstrates, this can happen with a declaration that has no jumptable attribute and no unnamed_addr when it is linked with a defined function that has both.

Diff Detail

Event Timeline

tmroeder updated this revision to Diff 16662.Nov 26 2014, 1:33 PM
tmroeder retitled this revision from to Link jumptable attributes consistently with unnamed_addr.
tmroeder updated this object.
tmroeder edited the test plan for this revision. (Show Details)
tmroeder set the repository for this revision to rL LLVM.
tmroeder added a subscriber: Unknown Object (MLST).
rafael added inline comments.
lib/Linker/LinkModules.cpp
1029

Shouldn't it drop the jumptable instead? Or report an error?

If unnamed_addr is not present in a module, then that module can depend on the address of that GV. Adding it also produces an invalid module.

tmroeder abandoned this revision.Nov 16 2018, 3:56 PM

This is very old and doesn't need to be open anymore.