mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-27 15:16:43 +00:00
Add : mutex pprof profile (#731)
* add : mutex pprof profile * rm : remove trace from default pprof profiles
This commit is contained in:
parent
53fd1fe912
commit
87deea068a
2 changed files with 6 additions and 2 deletions
|
|
@ -129,8 +129,9 @@ func (d *DebugPprofCommand) Run(args []string) int {
|
|||
|
||||
// Only take cpu and heap profiles by default
|
||||
profiles := map[string]string{
|
||||
"heap": "heap",
|
||||
"cpu": "cpu",
|
||||
"heap": "heap",
|
||||
"cpu": "cpu",
|
||||
"mutex": "mutex",
|
||||
}
|
||||
|
||||
if !d.skiptrace {
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@ import (
|
|||
"net"
|
||||
"net/http"
|
||||
"os"
|
||||
"runtime"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
|
|
@ -96,6 +97,8 @@ func VerbosityStringToInt(loglevel string) int {
|
|||
|
||||
//nolint:gocognit
|
||||
func NewServer(config *Config, opts ...serverOption) (*Server, error) {
|
||||
runtime.SetMutexProfileFraction(5)
|
||||
|
||||
srv := &Server{
|
||||
config: config,
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue