mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-29 10:32:47 +00:00
Make sure the extracted function has external linkage, so that it doesn't
get eliminated by globaldce! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2736 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
1ab854aa1e
commit
6a1359229d
@ -39,6 +39,9 @@ struct FunctionExtractorPass : public Pass {
|
||||
// Yes, it is. Keep track of it...
|
||||
Named = *I;
|
||||
|
||||
// Make sure it's globally accessable...
|
||||
Named->setInternalLinkage(false);
|
||||
|
||||
// Remove the named function from the module.
|
||||
M->getFunctionList().remove(I);
|
||||
E = M->end();
|
||||
|
@ -39,6 +39,9 @@ struct FunctionExtractorPass : public Pass {
|
||||
// Yes, it is. Keep track of it...
|
||||
Named = *I;
|
||||
|
||||
// Make sure it's globally accessable...
|
||||
Named->setInternalLinkage(false);
|
||||
|
||||
// Remove the named function from the module.
|
||||
M->getFunctionList().remove(I);
|
||||
E = M->end();
|
||||
|
Loading…
Reference in New Issue
Block a user