Open ldez opened 1 year ago
I think you've fixed this in #10? I'm closing this issue, feel free to reopen if relevant.
I cannot reopen an issue you closed.
As I said: Even with changes from #10, I'm not able to run go-binsize-viz
Would you be ok sharing some details of the binary that causes trouble? Or is this issue the same for any binary?
from my memories, it's for any binaries.
Maybe you can give https://github.com/Zxilly/go-size-analyzer a try. If you find that your binary cannot be analyzed and don't mind making this binary public, please send it to me. I'm collecting weird GoLang binaries for integration testing.
I noticed that you are a maintainer of golangci-lint, here is a basic analysis for golangci-lint 1.59 linux amd64
@Zxilly thanks for the link. This is a very good piece of software! Can it also analyze objects produced by other languages, present in the symbol table? For example, the script I produced is able to parse entries generated by C/C++ when using CGo. This is useful for programs that include external libraries.
Yes, it can load these info from dwarf.
Even with changes from #10, I'm not able (without running steps by hand and ignoring errors) to run go-binsize-viz.
I don't know if those errors are expected (I guess not) and should be ignored in the script. Note: I'm on linux/amd64.
debug (run step by step and ignore errors)
```console $ docker run --rm -it --entrypoint sh -v ./dist:/dist -p 8000:8000 knz-go-binsize-viz:temp ~ $ tmpdir=$(mktemp -d) ~ $ binary=/dist/binary ~ $ go tool nm -size "${binary}" | c++filt >${tmpdir}/symtab.txt ~ $ python3 ./tab2pydic.py ${tmpdir}/symtab.txt >${tmpdir}/out.py ... unknown T sym format: type:.eq.vendor/golang.org/x/net/idna.labelError unknown T sym format: type:.eq.vendor/golang.org/x/sys/cpu.option unknown T sym format: type:.hash.github.com/sacloud/iaas-api-go/search.FilterKey unknown T sym format: type:.hash.golang.org/x/net/http2/hpack.pairNameValue unknown T sym format: type:.hash.google.golang.org/grpc/resolver.Address unknown T sym format: type:.hash.google.golang.org/protobuf/internal/filedesc.pathKey unknown T sym format: type:.hash.internal/intern.key unknown T sym format: type:.hash.net/http.connectMethodKey unknown T sym format: type:.hash.reflect.visit unknown T sym format: type:.hash.vendor/golang.org/x/net/http2/hpack.pairNameValu ... ~ $ python3 ./simplify.py ${tmpdir}/out.py >${tmpdir}/data.js loading... transforming... output... ~ $ cp -r ./js ${tmpdir}/js ~ $ cp ./app3.js ${tmpdir}/app3.js ~ $ cp ./treemap.css ${tmpdir}/treemap.css ~ $ cp ./treemap_v3.html ${tmpdir}/treemap_v3.html ~ $ cd ${tmpdir} /tmp/tmp.hDimnc $ python3 -m http.server Serving HTTP on 0.0.0.0 port 8000 (http://0.0.0.0:8000/) ... ```