- Sort Score
- Result 10 results
- Languages All
Results 1 - 2 of 2 for SplitStoredHashIndex (0.27 sec)
-
src/cmd/vendor/golang.org/x/mod/sumdb/tlog/tlog.go
i := int64(0) for ; n > 0; n >>= 1 { i += n } return i + int64(level) } // SplitStoredHashIndex is the inverse of [StoredHashIndex]. // That is, SplitStoredHashIndex(StoredHashIndex(level, n)) == level, n. func SplitStoredHashIndex(index int64) (level int, n int64) { // Determine level 0 record before index. // StoredHashIndex(0, n) < 2*n,
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Jul 12 20:38:21 UTC 2023 - 17.9K bytes - Viewed (0) -
src/cmd/vendor/golang.org/x/mod/sumdb/tlog/tile.go
// tileForIndex returns the tile of height h ≥ 1 // storing the given hash index, which can be // reconstructed using tileHash(data[start:end]). func tileForIndex(h int, index int64) (t Tile, start, end int) { level, n := SplitStoredHashIndex(index) t.H = h t.L = level / h level -= t.L * h // now level within tile t.N = n << uint(level) >> uint(t.H) n -= t.N << uint(t.H) >> uint(level) // now n within tile at level
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri May 03 02:38:00 UTC 2024 - 13K bytes - Viewed (0)