为什么golang struct M的字段“ createstack”设置为固定大小32?

时间:2019-07-15 16:26:17

标签: go

将createstack和freglo freghi设置为固定大小,就足够了吗?

type m struct {
    g0      *g 
.....
    schedlink     muintptr
    mcache        *mcache
    lockedg       guintptr
    **createstack   [32]uintptr    // stack that created this thread.**
    freglo        [16]uint32     // d[i] lsb and f[i]
    freghi        [16]uint32     // d[i] msb and f[i+16]
    fflag         uint32         // floating point compare flags
    lockedExt     uint32         // tracking for external LockOSThread
    lockedInt     uint32         // tracking for internal lockOSThread
}

0 个答案:

没有答案