---
source: https://iinventedlight.com/library/notes/go-runtime.md
title: "Go runtime: goroutines, GC, and process controls"
license: CC-BY-4.0
license_url: https://creativecommons.org/licenses/by/4.0/
source_license: "BSD-3-Clause (The Go Authors); BSD-3-Clause (The Go Authors); prose restates cited source lines in own words"
license_family: mixed-green
attribution: "Summary by iinventedlight (AI-assisted). Sources: The Go Authors, runtime; The Go Authors, runtime source. BSD-3-Clause (https://go.dev/LICENSE). Copyright The Go Authors."
author: "iinventedlight (synthesis of cited sources); text drafted with AI assistance"
date: 2026-11-25
status: published
approved_by: "Cole Withington, 2026-11-27 14:30 PT: \"Yes, publish all of that now\""
checked_on: 2026-11-25
as_of: 2026-11-25
confidence: medium
untested: "Not reproduced (2026-11-25). Official docs and source files were read; no test suite, server, or API call was run for this note."
category: coding-references
topic_area: "code-systems: go-runtime"
tags: [go, runtime, goroutines, garbage-collection, gogc]
client: Librarian
sources:
  - id: S1
    title: "runtime"
    publisher: The Go Authors
    url: https://pkg.go.dev/runtime
    accessed: 2026-11-25
    license: "BSD-3-Clause"
  - id: S2
    title: "runtime source"
    publisher: The Go Authors
    url: https://go.dev/src/runtime/extern.go
    accessed: 2026-11-25
    license: "BSD-3-Clause"
---
# Go runtime: goroutines, GC, and process controls
**Answer:** The runtime package contains operations that interact with Go's runtime system.

## Goroutines and types

Those operations include functions to control goroutines.

The package also includes the low-level type information used by the reflect package.

## GOGC and memory limits

The GOGC variable sets the initial garbage collection target percentage.

The default is GOGC=100.

Setting GOGC=off disables the garbage collector entirely.

The GOMEMLIMIT variable sets a soft memory limit for the runtime.

## See also

- [go-goroutines](https://iinventedlight.com/library/notes/go-goroutines/)
- [go-reflect](https://iinventedlight.com/library/notes/go-reflect/)
- [go-metrics](https://iinventedlight.com/library/notes/go-metrics/)

## Claims

- id: C1
  claim: The package interacts with Go's runtime system, including goroutine controls.
  source: S1
  evidence: "Package runtime contains operations that interact with Go's runtime system"

- id: C2
  claim: The default garbage-collection target is GOGC=100.
  source: S1
  evidence: "The default is GOGC=100."

- id: C3
  claim: The package interacts with Go's runtime system, including goroutine controls.
  source: S2
  evidence: "Package runtime contains operations that interact with Go's runtime system"

- id: C4
  claim: Setting GOGC=off turns the garbage collector off entirely.
  source: S2
  evidence: "Setting GOGC=off disables the garbage collector entirely."

## Sources

- [S1] runtime. The Go Authors. https://pkg.go.dev/runtime . License: BSD-3-Clause. Accessed 2026-11-25.

- [S2] runtime source. The Go Authors. https://go.dev/src/runtime/extern.go . License: BSD-3-Clause. Accessed 2026-11-25.

License: this note is CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Summary by iinventedlight (AI-assisted). Sources: The Go Authors, runtime; The Go Authors, runtime source. BSD-3-Clause (https://go.dev/LICENSE). Copyright The Go Authors. Text was condensed and changed from the originals.

---

Agents: [/agents.md](/agents.md) | [/.well-known/agent-library.json](/.well-known/agent-library.json).
