LinuxCommandLibrary

go-tool

Run Go toolchain programs

TLDR

List available tools

$ go tool
copy
Run pprof
$ go tool pprof [profile.pb.gz]
copy
Run trace
$ go tool trace [trace.out]
copy
Run compile
$ go tool compile [file.go]
copy
Run objdump
$ go tool objdump [binary]
copy

SYNOPSIS

go tool [tool] [arguments]

DESCRIPTION

go tool runs Go toolchain programs that underlie the standard go commands. It provides access to low-level tools like the compiler, linker, profiler, and tracer.
The command is used for advanced debugging, profiling, and understanding compiler behavior. Each tool has its own options and usage patterns.

PARAMETERS

TOOL

Tool name to run.
ARGUMENTS
Tool-specific arguments.
pprof
Profile viewer.
trace
Execution tracer.
compile
Go compiler.
link
Go linker.
objdump
Object file disassembler.
--help
Display help information.

CAVEATS

Low-level tools. May change between versions. For advanced users.

HISTORY

go tool provides access to Go toolchain internals, supporting debugging and optimization workflows.

SEE ALSO

go(1), go-build(1)

> TERMINAL_GEAR

Curated for the Linux community

Copied to clipboard

> TERMINAL_GEAR

Curated for the Linux community