- Sort Score
- Result 10 results
- Languages All
Results 21 - 30 of 538 for alignUp (1.13 sec)
-
src/runtime/stack.go
} if n&(n-1) != 0 { throw("stack size not a power of 2") } if stackDebug >= 1 { print("stackalloc ", n, "\n") } if debug.efence != 0 || stackFromSystem != 0 { n = uint32(alignUp(uintptr(n), physPageSize)) v := sysAlloc(uintptr(n), &memstats.stacks_sys) if v == nil { throw("out of memory (stackalloc)") } return stack{uintptr(v), uintptr(v) + uintptr(n)} }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 22 22:31:00 UTC 2024 - 41.1K bytes - Viewed (0) -
src/crypto/subtle/xor_test.go
for n := 1; n <= 1024; n++ { if n > 16 && testing.Short() { n += n >> 3 } for alignP := 0; alignP < 8; alignP++ { for alignQ := 0; alignQ < 8; alignQ++ { for alignD := 0; alignD < 8; alignD++ { p := make([]byte, alignP+n, alignP+n+10)[alignP:] q := make([]byte, alignQ+n, alignQ+n+10)[alignQ:] if n&1 != 0 { p = p[:n] } else { q = q[:n] }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Feb 16 15:51:19 UTC 2024 - 2.4K bytes - Viewed (0) -
src/go/types/sizes.go
} // stdSizes is used if Config.Sizes == nil. var stdSizes = SizesFor("gc", "amd64") func (conf *Config) alignof(T Type) int64 { f := stdSizes.Alignof if conf.Sizes != nil { f = conf.Sizes.Alignof } if a := f(T); a >= 1 { return a } panic("implementation of alignof returned an alignment < 1") } func (conf *Config) offsetsof(T *Struct) []int64 { var offsets []int64
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Apr 03 18:48:38 UTC 2024 - 8.9K bytes - Viewed (0) -
src/cmd/compile/internal/types2/sizes.go
} // stdSizes is used if Config.Sizes == nil. var stdSizes = SizesFor("gc", "amd64") func (conf *Config) alignof(T Type) int64 { f := stdSizes.Alignof if conf.Sizes != nil { f = conf.Sizes.Alignof } if a := f(T); a >= 1 { return a } panic("implementation of alignof returned an alignment < 1") } func (conf *Config) offsetsof(T *Struct) []int64 { var offsets []int64
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Mar 25 19:53:03 UTC 2024 - 8.8K bytes - Viewed (0) -
src/cmd/compile/internal/types2/gcsizes.go
} func (s *gcSizes) Alignof(T Type) (result int64) { defer func() { assert(result >= 1) }() // For arrays and structs, alignment is defined in terms // of alignment of the elements and fields, respectively. switch t := under(T).(type) { case *Array: // spec: "For a variable x of array type: unsafe.Alignof(x) // is the same as unsafe.Alignof(x[0]), but at least 1." return s.Alignof(t.elem)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Feb 22 19:32:17 UTC 2024 - 4.2K bytes - Viewed (0) -
src/go/types/gcsizes.go
} func (s *gcSizes) Alignof(T Type) (result int64) { defer func() { assert(result >= 1) }() // For arrays and structs, alignment is defined in terms // of alignment of the elements and fields, respectively. switch t := under(T).(type) { case *Array: // spec: "For a variable x of array type: unsafe.Alignof(x) // is the same as unsafe.Alignof(x[0]), but at least 1." return s.Alignof(t.elem)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Apr 03 18:48:38 UTC 2024 - 4.4K bytes - Viewed (0) -
src/hash/crc32/crc32_amd64.s
CMPQ CX, $8 JL less_than_8 MOVQ SI, BX ANDQ $7, BX JZ aligned // Process the first few bytes to 8-byte align the input. // BX = 8 - BX. We need to process this many bytes to align. SUBQ $1, BX XORQ $7, BX BTQ $0, BX JNC align_2 CRC32B (SI), AX DECQ CX INCQ SI align_2: BTQ $1, BX JNC align_4 CRC32W (SI), AX SUBQ $2, CX ADDQ $2, SI align_4:
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Jun 01 21:52:00 UTC 2018 - 5.4K bytes - Viewed (0) -
src/runtime/traceback.go
frame.fp = 0 // On link register architectures, sighandler saves the LR on stack // before faking a call. if usesLR && injectedCall { x := *(*uintptr)(unsafe.Pointer(frame.sp)) frame.sp += alignUp(sys.MinFrameSize, sys.StackAlign) f = findfunc(frame.pc) frame.fn = f if !f.valid() { frame.pc = x } else if funcspdelta(f, frame.pc) == 0 { frame.lr = x } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 29 16:25:21 UTC 2024 - 55.1K bytes - Viewed (0) -
src/hash/crc32/crc32_ppc64le.go
if len(p) >= 4*vecMinLen { // If not aligned then process the initial unaligned bytes if uint64(uintptr(unsafe.Pointer(&p[0])))&uint64(vecAlignMask) != 0 { align := uint64(uintptr(unsafe.Pointer(&p[0]))) & uint64(vecAlignMask) newlen := vecMinLen - align crc = ppc64SlicingUpdateBy8(crc, archCastagnoliTable8, p[:newlen]) p = p[newlen:] } // p should be aligned now aligned := len(p) & ^vecAlignMask
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Nov 18 17:59:44 UTC 2022 - 2.2K bytes - Viewed (0) -
test/typeparam/issue47716.go
panic(fmt.Sprintf("got %d, want %d", got, want)) } if got, want := align(v1), unsafe.Alignof(v1); got != want { panic(fmt.Sprintf("got %d, want %d", got, want)) } v2 := "abc" if got, want := size(v2), unsafe.Sizeof(v2); got != want { panic(fmt.Sprintf("got %d, want %d", got, want)) } if got, want := align(v2), unsafe.Alignof(v2); got != want { panic(fmt.Sprintf("got %d, want %d", got, want)) }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Mar 01 19:45:34 UTC 2022 - 1.6K bytes - Viewed (0)