Relax zero-fill edge assertions to only consider relocation edges. Keep-alive edges to zero-fill blocks can cause this assertion which is too strict.
Details
Details
Diff Detail
Diff Detail
Event Timeline
Comment Actions
Otherwise LGTM.
llvm/include/llvm/ExecutionEngine/JITLink/JITLink.h | ||
---|---|---|
306–307 | Can this specifically check for K == Edge::KeepAlive for now? Invalid is also a non-relocation edge, but we wouldn't want it sneaking through here. | |
llvm/lib/ExecutionEngine/JITLink/JITLinkGeneric.h | ||
131–132 | We don't want to drop this entirely. I think it should be rewritten as: assert((!B->isZeroFill() || all_of(B->edges(), [](const Edge &E) { return E.getKind() == Edge::KeepAlive; })) && "Non-KeepAlive edges in zero-fill block?"); |
Can this specifically check for K == Edge::KeepAlive for now? Invalid is also a non-relocation edge, but we wouldn't want it sneaking through here.