compact8.go ×2

Frontier kind: Code frontier

unlabeled · c_a7ce27438339

17 tests · 16 LOC · 1 file · introduces 0 tests · 14 LOC · 1 file

Introduces — evidence that enters the hierarchy at this concept

Code
2 ranges14 lines · 1 files
Tests
0 tests

Contains — complete concept membership

All code (extent)
3 ranges16 lines · 1 file · Browse complete extent
All tests (intent)
17 testsBrowse complete intent

Neighbourhood graph

The orange circle is the focus. Violet and green circles are every ancestor and descendant, broader and narrower, at any distance; blue squares and pink diamonds are the introduced files and exact introduced tests of every visible concept, not only the focus's. Arrows point from broader to narrower concepts and bridge only concepts omitted from this view. Undirected links show source or test introduction. Concept and file size follows LOC; exact test nodes use test-count units.

Introduced files, introduced tests, and structurally relevant concept specialization

In the embedded map, ordinary wheel input scrolls the page; use the visible controls to zoom and drag to pan. Open the full-screen map for canvas navigation: wheel pans, Ctrl/Command plus wheel zooms, and arrow keys pan when this region is focused. On touch screens, open the full-screen map to pan or pinch. If JavaScript or WebGL is unavailable, use the native relationship evidence on this page.

Introduced files, introduced tests, and structurally relevant concept specializationTestDrainClearsBacklogBits · 0 introduced LOCTestDrainClearsBacklogBi…TestBacklogCountUpdateInMemoryOnly · 0 introduced LOCTestBacklogCountUpdateIn…message.pb.go ×1 · 2 introduced LOCmessage.pb.go ×1TestNoWriteWhenBacklogUnchanged · 0 introduced LOCTestNoWriteWhenBacklogUn…TestSameTargetAndCapSkipsWrite · 0 introduced LOCTestSameTargetAndCapSkip…tasks.pb.go ×1 · 8 introduced LOCtasks.pb.go ×1simple_partition_scaler.go ×1 · 1 introduced LOCsimple_partition_scaler.…simple_partition_scaler.go ×1 · 2 introduced LOCsimple_partition_scaler.…simple_partition_scaler.go ×4 · 9 introduced LOCsimple_partition_scaler.…TestRoundDown · 0 introduced LOCTestRoundDownTestRoundtrip · 0 introduced LOCTestRoundtripTestUpdateZeroBoundary · 0 introduced LOCTestUpdateZeroBoundarycompact8.go ×1 · 1 introduced LOCcompact8.go ×1compact8.go ×1 · 2 introduced LOCcompact8.go ×1compact8.go ×2 · 10 introduced LOCcompact8.go ×2compact8.go ×1 · 2 introduced LOCcompact8.go ×1TestEncodeRoundsDown · 0 introduced LOCTestEncodeRoundsDownTestUpdateSameBucket · 0 introduced LOCTestUpdateSameBucketcompact8.go ×3 · 4 introduced LOCcompact8.go ×3compact8.go ×2 · 4 introduced LOCcompact8.go ×2compact8.go ×1 · 2 introduced LOCcompact8.go ×1TestOperatorServiceMetadata, TestWorkflowServiceMetadata · 0 introduced LOCTestOperatorServiceMetad…go.temporal.io/server/api/persistence/v1/tasks.pb.go · 870 LOCv1/tasks.pb.gogo.temporal.io/server/api/taskqueue/v1/message.pb.go · 1363 LOCv1/message.pb.gogo.temporal.io/server/common/number/compact8.go · 98 LOCnumber/compact8.gogo.temporal.io/server/service/matching/simple_partition_scaler.go · 181 LOCmatching/simple_partitio…TestOperatorServiceMetadata · introduced test · go.temporal.io/server/common/api/TestOperatorServiceMetadataTestOperatorServiceMetad…TestWorkflowServiceMetadata · introduced test · go.temporal.io/server/common/api/TestWorkflowServiceMetadataTestWorkflowServiceMetad…TestEncodeKnownValues · introduced test · go.temporal.io/server/common/number/TestCompact8Suite/TestEncodeKnownValuesTestEncodeKnownValuesTestEncodeRoundsDown · introduced test · go.temporal.io/server/common/number/TestCompact8Suite/TestEncodeRoundsDownTestEncodeRoundsDownTestRoundDown · introduced test · go.temporal.io/server/common/number/TestCompact8Suite/TestRoundDownTestRoundDownTestRoundtrip · introduced test · go.temporal.io/server/common/number/TestCompact8Suite/TestRoundtripTestRoundtripTestUpdateHysteresis · introduced test · go.temporal.io/server/common/number/TestCompact8Suite/TestUpdateHysteresisTestUpdateHysteresisTestUpdateLargeJump · introduced test · go.temporal.io/server/common/number/TestCompact8Suite/TestUpdateLargeJumpTestUpdateLargeJumpTestUpdateSameBucket · introduced test · go.temporal.io/server/common/number/TestCompact8Suite/TestUpdateSameBucketTestUpdateSameBucketTestUpdateZeroBoundary · introduced test · go.temporal.io/server/common/number/TestCompact8Suite/TestUpdateZeroBoundaryTestUpdateZeroBoundaryTestOnTasksBacklogScalesUpAndDown · introduced test · go.temporal.io/server/service/matching/TestOnTasksBacklogScalesUpAndDownTestOnTasksBacklogScales…TestBacklogCapChangePersists · introduced test · go.temporal.io/server/service/matching/TestScaleManagerSuite/TestBacklogCapChangePersistsTestBacklogCapChangePers…TestBacklogCountUpdateInMemoryOnly · introduced test · go.temporal.io/server/service/matching/TestScaleManagerSuite/TestBacklogCountUpdateInMemoryOnlyTestBacklogCountUpdateIn…TestDrainClearsBacklogBits · introduced test · go.temporal.io/server/service/matching/TestScaleManagerSuite/TestDrainClearsBacklogBitsTestDrainClearsBacklogBi…TestNoWriteWhenBacklogUnchanged · introduced test · go.temporal.io/server/service/matching/TestScaleManagerSuite/TestNoWriteWhenBacklogUnchangedTestNoWriteWhenBacklogUn…TestSameTargetAndCapSkipsWrite · introduced test · go.temporal.io/server/service/matching/TestScaleManagerSuite/TestSameTargetAndCapSkipsWriteTestSameTargetAndCapSkip…TestUpdateBacklogTargetClearsBelowReset · introduced test · go.temporal.io/server/service/matching/TestUpdateBacklogTargetClearsBelowResetTestUpdateBacklogTargetC…TestUpdateBacklogTargetHysteresis · introduced test · go.temporal.io/server/service/matching/TestUpdateBacklogTargetHysteresisTestUpdateBacklogTargetH…TestUpdateBacklogTargetSetsBitsAboveBase · introduced test · go.temporal.io/server/service/matching/TestUpdateBacklogTargetSetsBitsAboveBaseTestUpdateBacklogTargetS…Focused concept · compact8.go ×2 · 14 introduced LOCcompact8.go ×2

Graph controls are ready.

Interactive rendering requires JavaScript and WebGL. Use the native relationship evidence on this page while the interactive map is unavailable.

Native relationship evidence

Every exact file and test below is linked only from the concept that introduces it.

Introduced tests

Every collected test enters the hierarchy at exactly one concept.

No tests are introduced at this concept. Its intent tests are introduced by other concepts.

Introduced code

Every collected source range enters the hierarchy at exactly one concept.

1 file ranked by introduced lines: 14 introduced LOC across 2 ranges. Expand a file to inspect source; the > gutter marks introduced lines.

go.temporal.io/server/common/number/compact8.go 14 introduced LOC · 2 ranges

Open complete file

39 }
40
41 > uval := uint64(value) compact8.go
42 > bitLen := bits.Len64(uval)
43 >
44 > // Find shift such that uval >> shift is in [12, 23].
45 > // This extracts the significand for the normalized representation.
46 > shift := max(bitLen-5, 0)
47 > sig := int(uval >> uint(shift))
48 > if sig >= 24 {
49 > shift++
50 > sig = int(uval >> uint(shift))
51 > }
52
53 > e := shift - compact8offset compact8.go
54 >
55 > if e >= 1 {
56 m := sig - 12
57 b := e*12 + m