Re: LSan curiosity in t1300
- From
Jeff King <peff@peff.net>
- Date
- Sep 8, 2022, 18:15 UTC
- Message-ID
- <YxoxRus2NjsYmM63@coredump.intra.peff.net>
- In-Reply-To
- <xmqq8rmtrbfq.fsf@gitster.g>
On Thu, Sep 08, 2022 at 11:03:05AM -0700, Junio C Hamano wrote:
Show 11 quoted lines
> > But if you run this in a debugger, you'll find that under -O2 the "key" > > variable has been optimized out! So LSan is producing the wrong result > > due to the optimization. It doesn't know that "key" is conceptually > > still reachable. > > Yikes. > > Is that related to the cause of the other patch from you, i.e. > wanting to get "registers" but unable to? If they manage to get the > value of the register that holds 'key', would this disappear, I > wonder?
I don't think so. t1300 fails consistently for me with -O2, and it doesn't have the "register" message (and never came up as one of the racy losers). I think the "register" thing is mostly just a harmless warning that doesn't change the output, but simply confuses our "did lsan produce any logs" check.
-Peff