设置并发执行时CPU的使用数目

runtime.GOMAXPROCS(n int)
//设置并发执行时使用的CPU的数目 2个核心
runtime.GOMAXPROCS(2)

results matching ""

    No results matching ""