Open alexsaezm opened 8 months ago
@cherrymui
Thanks for the report. The simplest fix is probably just adding those cases to allowedMismatchObjdump
. A more principled fix is probably implement some matching algorithm so that those cases are considered "match". Feel free to send a CL. Thanks.
I'll take a look into it :D thanks for the suggestions.
The assembly format output by different binutils versions may also be different, which makes it difficult to do in Go. So in Go we have to allow this difference.
Go version
go 1.22
Output of
go env
in your module/workspace:What did you do?
While building a newer version of the arch package in Fedora I found that it doesn't build correctly on the latest version which has binutils 2.42.50 . I was able to reproduce this outside the building process by doing:
go test ./...
with the newer binutils version so it is not related to the package.Recently, ARM decided to tighten up the disassembly so objdump now matches exactly matches the specification in the AArch64 ISA document. I confirmed this by reaching out Nick Clifton from binutils.
I was going to submit a PR, but I realized that as this depends on the version the user is running, the solution is not as easy as just adapt the syntax because it will break older versions.
What did you see happen?
What did you expect to see?
All test passing.