Skip to main content

GB10 device exception for the L2 capacity sweep near capacity: registration

Registered by decision of the lead, for review by 6 and 5 before any implementation. It widens one registered device exception for one mode on one device; it changes no rule, statistic or other exception. The mechanism is not pursued further and stays an open question.

Scope​

  • Device and field. NVIDIA GB10 only, the l2 mode's capacity_sweep (l2_capacity_sweep in microbench/capture_exceptions.py).
  • Band. Working sets of 0.75 to 2.0 times l2_size_bytes. On GB10 these are the 18, 20, 22, 25, 28, 36 and 48 MiB points. Today the sweep is covered by bistable_band from 0.75 to 1.25 times.
  • Rule. Rule 3 only. Rules 1 and 2 still judge every point.
  • Implementation. The sweep leaves bistable_band and gets its own entry, l2_near_capacity_unstable, rules (3,), per_l2, bounds 0.75 to 2.0. So no point carries both flags, and the evidence of each entry stays its own.
  • Unchanged. l2-rescan (l2_rescan_hit_rate_by_working_set) keeps bistable_band at 0.75 to 1.25 times. No other device gets the exception.

Evidence​

There are two gated, recorded observations on GB10, so the condition for a device exception (a recorded observation on that device) holds.

  • The first 0.23.0 capture (42e039d), five valid rounds. The 36 MiB point (1.5 times L2) had round medians of 1475, 882, 1167, 891 and 1150 GB/s, three discrete levels and a 52% span; 48 MiB (2.0 times) spanned 21%. Each round was steady within itself (IQR 4% to 7%, 15% once). The whole near-capacity part of the curve moved with the process; the recorded order, clock and host telemetry did not explain the shift. Source: v0.3-gb10-first-capture-l2-diagnosis.md, section 1.
  • The registered buffer experiment (94138c7), five valid processes. A single-buffer replica of the sweep reproduced the span (34% at 36 MiB). In one process, six separate buffers differed by 33% to 58%, and about half of their 36 MiB lists were unsteady. Source: the same document, sections 7 and 8.

What a covered point records​

This follows the format of low_in_flight_unstable.

  • In the merged raw (long_capture.py reduce), each covered sweep point carries exceptions: ["l2_near_capacity_unstable"] and round_median_range_ns, the minimum and maximum of its round medians. mark_exceptions already writes both for every registered exception.
  • In the profile. The sweep points are not profile values (NOT_IN_PROFILE in profile_launch.py). The profile value they feed is l2_effective_capacity_bytes, and it changes as follows:
    • The knee is computed by estimate_l2_knee from each valid round's sweep, as well as from the merged one. A round whose sweep has no 85% crossing (too few points, a failed plateau check, or no crossing) gets the function's fallback of 0.85 times L2; such a round is not an observed knee, is left out of the spread and is counted in the capture record.
    • Its rel_uncertainty becomes the larger of today's value and max over the other rounds of |knee(round) - knee(merged)| / knee(merged). It covers the observed spread up to the existing 0.5 cap.
    • When either point of the bracket of the merged sweep's uncapped 85% crossing is covered, the value carries "l2_near_capacity_unstable": true. A merged sweep without a crossing (fallback) is not flagged.
    • The flag is set where the knee is computed, in collect_profile.py, not through profile_launch.FLAG: the sweep points are in NOT_IN_PROFILE, and l2_effective_capacity_bytes is a bare MeasuredValue with no point object around it. schemas/gpu_profile.schema.json gains the optional boolean on MeasuredValue, which has additionalProperties: false. (Corrected after 6's review, before implementation.)

Consumers, and what the exception means for predictions​

  • collect_profile.py. It reads the sweep only in estimate_l2_knee:

    • The L2 plateau is the median of the first two points (2 and 6 MiB), and the DRAM level the median of the last two (48 and 60 MiB). The 48 MiB point is covered, but it enters only this plausibility check (plateau above 1.1 times DRAM).
    • The knee is where the bandwidth first falls below 85% of the plateau, interpolated and capped at l2_size_bytes.
    • rel_uncertainty is the bracketing step over twice the knee, clamped to 0.10 to 0.50. perturb_group is None.
  • The core. It reads l2_effective_capacity_bytes in three places:

    • the cross-wave reuse capacity of the L2 model (forward re-reads hit per K slice under LRU at that capacity, design 6.4);
    • the L2 fit of spill traffic;
    • the DRAM overflow share of a working set (sim.rs).

    The value is perturbed in every draw: draw 0 is unperturbed, and draws 1 to 32 scale it uniformly within plus or minus rel_uncertainty as a dimension of its own. A wider uncertainty changes the sampling range for draws 1 to 32; draw 0 keeps the merged knee. A wider input range does not guarantee that a given prediction changes.

  • In the first capture.

    • Every round's knee is capped at 24 MiB, the physical L2. The crossings themselves lie at 26.2 to 31.3 MiB, 29.6 MiB from the merged sweep.
    • rel_uncertainty is 0.10 (rounds 2 and 4, crossing between 25 and 28 MiB) or 0.167 (rounds 1, 3 and 5, and the merged sweep, crossing between 28 and 36 MiB). The widening adds nothing here, since every knee is 24 MiB.
    • So on this evidence the exception does not move the value the core uses. It records the instability on the value. Under the proposed rule the l2 mode would pass rule 3 in this capture; the capture as a whole still failed, for the other reasons in its report.
  • The core's limit, stated for design.md 9.3. The sweep's steady repeated scans retain much more than the core assumes. At 1.5 times L2 they show hit fractions of 0.79 to 0.94. The core's cross-wave form, the rescan's one pass and the wave-rescan forward re-reads all agree on about 0 to 0.09 there.

    • A kernel that re-reads a 1.25 to 2 times L2 working set many times in a row is therefore likely to be predicted with too few L2 hits, by an amount that also varies between processes on GB10.
    • This is to be added to design.md 9.3 as a known limit, next to the band of 0.75 to 1.25 times. It does not change the model.

Offline replay on the first capture (42e039d)​

The l2 mode's five valid rounds were replayed with long_capture.rule_three and rules_one_two, unchanged, under three exception tables:

ExceptionsRule 3Rule 1 per round (flags / allowed)Rule 2 per round
nonefailed, 3 of 29 points (1 allowed)0/1, 0/1, 1/1, 1/1, 0/10/4 in every round
current (bistable_band to 1.25)failed, 2 of 24 (1 allowed), as in the capture reportas aboveas above
proposed (l2_near_capacity_unstable to 2.0)passed, 0 of 22 (1 allowed)as aboveas above

The rule 1 flags are the 12 MiB point in round 3 and the 36 MiB point in round 4. Both are within the allowance of one, and the exception does not touch them.

Limits​

  • The mechanism is not known. Three explanations are excluded by the registered buffer experiment (94138c7):

    • placement of a process's physical pages: buffers keep no level;
    • session state set once per process: buffers in one process differ by 33% to 58%;
    • compression of the constant fill: random data are retained equally, with a hit fraction of 0.87.

    Source: the diagnosis document, section 8.

  • The retention above 24 MiB is unexplained. A hit fraction of up to 0.94 at 1.5 times L2 implies about 34 MiB of inferred bytes served from cache.

  • The exception does not cover rule 1. The 36 MiB point, unsteady in about half of the experiment's lists, may fail rule 1 in a later capture, and that would void the round. The capture judges that, not this registration.

  • It covers the sweep's points only. It says nothing about kernels whose working set lies in the band; for those, see the known limit above.

Wording and the fallback rounds revised after 5's review, after the first implementation (f0e743e) and before merge.