[go-nuts] Re: Can a golang program be compiled to run with only ONE goroutine ?

2024-09-10 Thread Zxilly Chou
If you compile it to WebAssembly, it will works under the single thread model. However, there are still multi *goroutine *be created, it was designed to. 在2024年9月10日星期二 UTC+8 21:54:56 写道: > Hello, > > Maybe the question has already been asked, but I would be glad to have > your feedback. > >

[go-nuts] Why is there a huge gap between the memory profile's inuse_space in pprof and the externally obtained memory footprint?

2024-07-20 Thread Zxilly Chou
I'm working on the project https://github.com/Zxilly/go-size-analyzer, a program that can be very memory intensive, so I've written some scripts to fetch the pprof file during integration testing, and I'm using python's psutil to read the cpu and memory usage to automatically plot into the im

[go-nuts] Re: go tool cover vs go tool covdata

2024-07-12 Thread Zxilly Chou
Simply, cover for text format coverage and covdata for bianry format. 在2024年7月10日星期三 UTC+8 18:07:21 写道: > what is the difference between go tool cover and go tool covdata ? > -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from t

Re: [go-nuts] strip / reduce module compile size

2024-06-18 Thread Zxilly Chou
Please try https://github.com/Zxilly/go-size-analyzer . I created this based on reverse engineering, so only the bytes in the final build will be count. 在2024年6月18日星期二 UTC+8 01:14:09 写道: > Are there other tools that may show the final size? I'd like to see if > there are more aggressive flags

[go-nuts] Discover go-size-analyzer: Streamline Your Go Binary Insights

2024-05-21 Thread Zxilly Chou
Hello go-nuts, I'm excited to share a new tool that has landed in our Go ecosystem: go-size-analyzer. This utility is designed to give you a clear picture of the size of your compiled Go binaries, with a focus on how dependencies contribute to the overall footprint. It simplifies the process

[go-nuts] Re: programmatic way to find if application go binary is built with -cover flag ?

2024-05-13 Thread Zxilly Chou
try debug.ReadBuildInfo(), then iterate the pair in the buildinfo.Settings 在2024年5月13日星期一 UTC+8 20:56:51 写道: > Is there a way in go to find whether a go binary is built with -cover flag > ? -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To un

[go-nuts] Re: Reproducible builds with CGO

2024-04-26 Thread Zxilly Chou
golang will embed the path of the source file into the binary, also the .gopclntab will contains the path. try use -trimpath and see if there's any change. 在2024年4月27日星期六 UTC+8 01:28:05 写道: > Hi All, > > *Does anybody have experience in how the use of CGO and dynamic linking > may affect the re

[go-nuts] Which part of go compiler set the symbol "runtime.text" in the final build?

2024-01-24 Thread Zxilly Chou
Yesterday, I reported an issue on debug/gosym at issues/65232 regarding the difference between the symbol table and gopclntab. A member of the Go team informed me that the start of the .text segment is not always kept the same as 'runtime.text' value. I am curious about how the compiler sets th