MCPcopy Create free account
hub / github.com/facebook/time / clockDataCRC

Function clockDataCRC

fbclock/shmem_notlinux.go:112–120  ·  view source on GitHub ↗
(d *[40]byte)

Source from the content-addressed store, hash-verified

110}
111
112func clockDataCRC(d *[40]byte) uint64 {
113 ingress := binary.LittleEndian.Uint64(d[0:8])
114 errorBound := uint64(binary.LittleEndian.Uint32(d[8:12]))
115 holdover := uint64(binary.LittleEndian.Uint32(d[12:16]))
116 counter := uint64(0xFFFFFFFF) ^ ingress
117 counter ^= errorBound
118 counter ^= holdover
119 return counter ^ 0xFFFFFFFF
120}
121
122// StoreFBClockData writes fbclock data to shared memory via mmap
123func StoreFBClockData(fd uintptr, d Data) error {

Callers 2

StoreFBClockDataFunction · 0.85
ReadFBClockDataFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…