Skip to content
Commit 02054d3a authored by Fangrui Song's avatar Fangrui Song
Browse files

[LTO] Simplify internalize logic. NFC

D151965 removed incorrect internalization for {linkonce,weak}{,_odr} when
the prevailing copy is in native code. The multiple conditions are based
on negative conditions, which can be simplified to be based on positive cases:

* an object with an external linkage (must be prevailing) can be internalized
* a prevailing object with a {linkonce,weak}{,_odr} or common linkage can be internalized.

Further, the lengthy comment is a bit misleading, as it doesn't say that
objects with an external/linkonce/weak linkage can be internalized.
Clarify it.

Reviewed By: tejohnson

Differential Revision: https://reviews.llvm.org/D158949
parent 5fe6f565
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment