title: What is the GOMAXPROCS default value?
body: <p>Is it guaranteed that GOMAXPROCS is set to 1 when the environment variable of the same name is not set?</p>
  
  <p>This code shows the value:</p>
  
  <pre><code>package main
  
  import (
      "runtime"
      "fmt"
  )
  
  func getGOMAXPROCS() int {
      return runtime.GOMAXPROCS(0)
  }
  
  func main() {
      fmt.Printf("GOMAXPROCS is %d\n", getGOMAXPROCS())
  }
  </code></pre>
  
  <p>and running it like this:</p>
  
  <pre><code>$ GOMAXPROCS= go run max.go 
  GOMAXPROCS is 1
  </code></pre>
  
  <p>shows that it is 1 in this case, but I am looking for some confirmation here.</p>