---
title: "Easy Profiling Go Benchmark Tests with Bash"
url: https://daily.dev/posts/easy-profiling-go-benchmark-tests-with-bash-zzjk1ry9i
source_url: https://blainsmith.com/articles/easy-profiling-go-benchmark-tests-with-bash
type: article
source: "Blain Smith"
published: 2026-05-24T07:43:41.107Z
updated: 2026-05-24T07:44:16.412Z
tags: ["golang", "bash"]
reading_time: 4
upvotes: 0
comments: 0
language: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Easy Profiling Go Benchmark Tests with Bash

**[Blain Smith](https://daily.dev/sources/blainsmith)** · 4 min read · 0 upvotes · 0 comments

## Summary

Two short bash scripts (bench.sh and trace.sh) simplify running Go benchmark tests with CPU/memory profiling and trace visualization. The scripts wrap `go test -bench` with pprof or trace flags, write output files to disk, and automatically open the visualizer in a browser on port 6060. A sample project layout and example output are provided. The author later turned the idea into a standalone tool at pprof.sh.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://blainsmith.com/articles/easy-profiling-go-benchmark-tests-with-bash>

## Similar posts on daily.dev

- [Part 1: pprof Quick Start - Get Profiling in 10 Minutes](https://daily.dev/posts/part-1-pprof-quick-start---get-profiling-in-10-minutes-60bzn1m6e) · Developer 2.0 · 0 upvotes · 0 comments
- [A Practical Guide to Profiling in Go](https://daily.dev/posts/a-practical-guide-to-profiling-in-go-fvzkksvyy) · JetBrains · 16 upvotes · 1 comments

---

Tags: [#golang](https://daily.dev/tags/golang), [#bash](https://daily.dev/tags/bash)

[View this post on daily.dev](https://daily.dev/posts/easy-profiling-go-benchmark-tests-with-bash-zzjk1ry9i)
