Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
cmd/compile: all.bash failures with -dwarflocationlists hard-wired on #22694
What version of Go are you using (
I did a little archeology on this. The block that the checker is complaining about is:
which clearly violates the "no non-phi after phi rule", but in fact this specific testpoint wasn't added until October, meaning that the locations lists work predates the test (the location lists code was written back in June(ish), then the dev.debug branch was merged into master in August).
I'm not familiar enough with the SSA code to know what the right fix is. One thing to do would just be to relax the checking rules to ignore RegKills, since it is pretty clear that they don't correspond to any sort of real value definition.
David, maybe you could weigh in on this. @dr2chase
Thanks. This is working as I intended at the time, and the test could probably be updated to ignore the RegKill ops. Phis put values in registers like anything else, and if one clobbers something that was already in the register before that, there should be a RegKill before it. That was a change in the invariants of the SSA form, but it didn't cause much trouble.
In this particular case, since the set of names that's being set on the registers by the Phis match the ones being removed by the RegKills, they're pointless. But I'm pretty sure there are cases where the set of names differ, and then they are necessary.
Beyond the SSA sanity checker (which should be fixed with 77610) there are also a couple of GDB test failures:
It looks like these two above will go away once my DWARF inlining patch is submitted. After that, there are a set of failures of the following form:
These are due to this line in cmd/compile/internal/gc/main.go:
meaning someone needs to create fill in the DWARF registers for the various non-x86 archs.
Relax the 'phi after non-phi' SSA sanity check to allow RegKill ops interspersed with phi ops in a block. This fixes a sanity check failure when -dwarflocationlists is enabled. Updates #22694. Change-Id: Iaae604ab6f1a8b150664dd120003727a6fb2f698 Reviewed-on: https://go-review.googlesource.com/77610 Run-TryBot: Than McIntosh <email@example.com> TryBot-Result: Gobot Gobot <firstname.lastname@example.org> Reviewed-by: David Chase <email@example.com>