Update profiling on linux jonathan lambrechts authored by Sébastien Timmermans's avatar Sébastien Timmermans
...@@ -4,8 +4,10 @@ ...@@ -4,8 +4,10 @@
## installer un meilleurs pprof (grace a golang) ## installer un meilleurs pprof (grace a golang)
```apt install golang``` ```apt install golang```
``` GOPATH=$HOME/go go get github.com/google/pprof``` ``` GOPATH=$HOME/go go get github.com/google/pprof```
Be careful, an error may occur `undefined os.UserConfigDir`. In this case, you will have to update the go version or use an older version of pprof.
## Profile the ./myexe ## Profile the ./myexe
```LD_PRELOAD=/usr/lib/libprofiler.so CPUPROFILE=prof ./myexe``` ```LD_PRELOAD=/usr/lib/libprofiler.so CPUPROFILE=prof ./myexe```
... ...
......