We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c00fc84 commit 9025053Copy full SHA for 9025053
src/machine/machine_rp2_cores.go
@@ -2,6 +2,8 @@
2
3
package machine
4
5
+import "runtime"
6
+
7
const numCPU = 2 // RP2040 and RP2350 both have 2 cores
8
9
// LockCore sets the affinity for the current goroutine to the specified core.
@@ -35,6 +37,7 @@ func LockCore(core int) {
35
37
panic("machine: core out of range")
36
38
}
39
machineLockCore(core)
40
+ runtime.Gosched()
41
42
43
// UnlockCore unpins the calling goroutine, allowing it to run on any available core.
0 commit comments