0.6.6: follow-ups from the k_approx review (#257)

Aberta
#262 1 comentário 0 reações 0 responsáveis Ver no GitHub

Mantenedores costumam responder em até 1 dia

Ninguém assumiu esta issue ainda.

Avaliação

Dificuldade
5/5
Tempo estimado
Mais de uma semana
Facilidade para iniciantes
35/100
Tipo de issue
Bug
Clareza
Razoavelmente clara
Status de atividade
Ativa
Stack de tecnologia
cpp
Domínio
backend, testing

Direção de pesquisa

Start with the six follow-ups in this issue and inspect the named shader file, clean/k/dx12/hlsl/k_out.hlsli, plus the preparation, executor, mode-line, frame-note, and release-diagnostics code they refer to. First trace how selected variants are prepared and how runtime options reach Model K; then review each item’s tests and evidence requirements. Done means the six gaps are fixed or documented as requested, with focused tests or committed synthetic-data summaries for the relevant claims.

Escrita pelo modelo de indexação a partir do texto da issue.

Descrição

Follow-ups from the review rounds of #257 (Model K: the k_approx opt-in close approximations a1 and a2). They are tracked here for 0.6.6; none of them changes the default (nothing set) output.

1. Preparation of a selected form with an unsupported root signature

An otherwise valid manifest can declare a selected approximate form (for example k_out_pixel_c__a2) with a root signature the native device does not support. The loader accepts it, the create-time preflight checks only the name and code object, and preparation returns success without loading the shader, so create succeeds and the first launch fails. Make preparation fail for an unsupported signature or an unmatched variant, and test that malformed selected entry. (The same preparation gap is item 2 of #261.)

2. Non-vacuous selection tests

The approximation test never asserts the k_out_color__a2 launch: replacing only that selection with the exact colour kernel would still pass. The executor matrix reads back no output bytes. Assert every expected approximate launch and the absence of its exact counterpart, for buffer and direct frames and for each tag on its own. Compare direct-route frames byte for byte where an exact reference applies.

3. Mode line with a very long options variable

If the runtime options environment variable exceeds the interop parser's 4095-character limit, the front end reports that it ignored the value, while Model K reads the full variable independently and enables the approximation. The mode line can then say "exact". Derive the mode line from the runtime's effective selection, or use one options source, and test the long-value case.

4. Claims without committed records

A comment in clean/k/dx12/hlsl/k_out.hlsli states a one-ULP maximum and a difference rate for six seeds, and the PR description cites a shader-identity record and an executor negative-control record. Neither record is in the repository. Commit constructed-data summaries for these (synthetic inputs only), or qualify the claims.

5. Frame-note threading contract

wg_rt_take_frame_note hands over the same per-context note a frame can write, without synchronization. The executor calls it synchronously after a frame, which is safe, but the contract is not written down. Document that frame calls and note calls on one context must not run concurrently, or synchronize them.

6. The k_fill test option in release builds

The k_fill option fills Model K buffers with a test pattern and is accepted in release builds; it predates #257. Limit it to developer builds, as the other test hooks are, and add it to the release diagnostics check.

Linguagem predominante
C++
Estrelas
12
Forks
2
Merge médio
3h 10min
PRs com merge (30d)
171

Preparar o ambiente

Primeiros passos

  1. Leia a issue inteira e depois o guia de contribuição do projeto.
  2. Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
  3. Faça um fork do repositório e trabalhe em uma branch.
  4. Abra um pull request que referencie o número da issue.

Mais de phantoslayer21/wronggpu

Todas as issues de phantoslayer21/wronggpu

Issues semelhantes

Mais issues de C++

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.