Re: [PATCH v2 33/33] tools/testing/vma: output compared expression on ASSERT_[EQ, NE]()
Lorenzo Stoakes <[email protected]> Sat, 11 Jul 2026 07:32:51 +0100
| Newsgroups | org.kernel.vger.linux-sgx,dev.linux.lists.iommu,org.freedesktop.lists.dri-devel,org.kernel.vger.kvm,org.kernel.vger.linux-arm-msm,org.kernel.vger.linux-kernel,org.kernel.vger.linux-tegra,org.kvack.linux-mm |
|---|---|
| Message-ID | <alHjL4lT8WLrJ1uj@lucifer> |
On Fri, Jul 10, 2026 at 05:09:54PM -0400, Gregory Price wrote: > On Fri, Jul 10, 2026 at 09:17:14PM +0100, Lorenzo Stoakes wrote: > > Update the macros to output the compared values at hex for easier debugging > > when test asserts fail. > > > > We have to be careful not to re-evaluate expressions as they may have > > side-effects. So update the code to take local copies and use these for > > both the test and the debug output. > > Aw you found it before i reported it :] Claude did :) I take no credit for it :P I guess I thought the re-eval wouldn't be an issue but obviously when it's a side-effect and the userland tests do do that, it's very important you DON'T re-evaluate :P Human 'meh that'll probably be fine-ish' vs. robot/Gregory laser-focused vision doing the whole 'Sorry Dave I'm afraid I can't do that' ;) > > > > > Also remove unused IS_SET() macro. > > > > Signed-off-by: Lorenzo Stoakes <[email protected]> > > > Reviewed-by: Gregory Price <[email protected]> > Cheers, Lorenzo