<div dir="ltr">I think we're talking about different things, sorry if I miscommunicated. My concern is this: say you have a pass. The pass modifies IR (specifically, deletes Constants). Should the pass manager be informed of that so it may appropriately invalidate analyses?</div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sat, Sep 11, 2021 at 11:44 AM Roman Lebedev via Phabricator <<a href="mailto:reviews@reviews.llvm.org">reviews@reviews.llvm.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">lebedev.ri added a comment.<br>
<br>
In D109294#2996057 <<a href="https://reviews.llvm.org/D109294#2996057" rel="noreferrer" target="_blank">https://reviews.llvm.org/D109294#2996057</a>>, @mtrofin wrote:<br>
<br>
> An analysis could count uses, for example; or could enumerate constants in<br>
> a module and refine some calculation from that set, but<br>
> removeDeadUsersOfConstant may delete some such constants.<br>
<br>
I think, there is a lot of things that could happen,<br>
but if llvm development is driven by FUD,<br>
as opposed to written guarantees and test-cases,<br>
a forward progress may be somewhat restricted.<br>
<br>
> (what's a "VH-like thing"?)<br>
<br>
`ValueHandle`, so that the use is actually kept alive,<br>
not just by a rouge constant expression.<br>
<br>
<br>
Repository:<br>
  rG LLVM Github Monorepo<br>
<br>
CHANGES SINCE LAST ACTION<br>
  <a href="https://reviews.llvm.org/D109294/new/" rel="noreferrer" target="_blank">https://reviews.llvm.org/D109294/new/</a><br>
<br>
<a href="https://reviews.llvm.org/D109294" rel="noreferrer" target="_blank">https://reviews.llvm.org/D109294</a><br>
<br>
</blockquote></div>