85 lines
2.5 KiB
Markdown
85 lines
2.5 KiB
Markdown
# PR-09.4 - Specs Refresh: ModuleId-Only + EntrypointRef Normative Alignment
|
|
|
|
## Briefing
|
|
|
|
Com a remocao estrutural de `moduleKey`, as specs normativas precisam refletir:
|
|
|
|
1. identidade de modulo densa (`ModuleId`),
|
|
2. entrypoint qualificado (`EntrypointRef`),
|
|
3. ausencia de fallback textual.
|
|
|
|
## Motivation
|
|
|
|
### Dor atual que esta PR resolve
|
|
|
|
1. Specs ainda descrevem partes name-only/text-based em pontos criticos.
|
|
2. Matriz pode afirmar `pass` sem refletir contratos mais estritos.
|
|
3. Risco de regressao por lacuna documento->implementacao.
|
|
|
|
## Target
|
|
|
|
Atualizar o baseline normativo para o modelo final:
|
|
|
|
1. `IRBackend` estrutural sem `moduleKey`,
|
|
2. `EntrypointRef(moduleId, callableName)` obrigatorio em handoff executavel,
|
|
3. ordenacao/lowering sem dependencias textuais.
|
|
|
|
## Dependencies
|
|
|
|
Prerequisitos diretos:
|
|
|
|
1. `PR-09.1`
|
|
2. `PR-09.2`
|
|
3. `PR-09.3`
|
|
|
|
## Scope
|
|
|
|
1. Revisar e atualizar specs:
|
|
- PBS 13 (Lowering IRBackend),
|
|
- General 20 (IRBackend -> IRVM),
|
|
- General 15 (Bytecode mapping entrypoint linkage),
|
|
- General 22 (matriz de conformidade).
|
|
2. Registrar decisao de corte definitivo (`moduleKey` removido).
|
|
|
|
## Non-Goals
|
|
|
|
1. Nao alterar implementação de runtime nesta PR.
|
|
2. Nao introduzir novo formato de arquivo para `program.pbx`.
|
|
|
|
## Method
|
|
|
|
### O que deve ser feito explicitamente
|
|
|
|
1. Em PBS13 e G20:
|
|
- trocar obrigacoes name-only por `EntrypointRef` qualificado,
|
|
- declarar `ModuleId` como identidade estrutural unica.
|
|
2. Em G15:
|
|
- manter `func_id=0` como entrypoint selecionado por `EntrypointRef`.
|
|
3. Em G22:
|
|
- adicionar/ajustar requirement rows para:
|
|
- no-moduleKey structural identity,
|
|
- strict qualified entrypoint,
|
|
- moduleid-only ordering.
|
|
|
|
## Acceptance Criteria
|
|
|
|
1. Nenhuma spec normativa relevante menciona `moduleKey` como identidade estrutural.
|
|
2. Matriz de conformidade cobre explicitamente obrigações novas.
|
|
3. `BackendConformanceMatrixSpecTest` e gate hard-policy permanecem verdes.
|
|
|
|
## Tests
|
|
|
|
1. `:prometeu-compiler:prometeu-build-pipeline:test --tests *BackendConformanceMatrixSpecTest*`
|
|
2. `:prometeu-compiler:prometeu-build-pipeline:test --tests *BackendClaimScopeSpecTest*`
|
|
|
|
## Affected Documents
|
|
|
|
1. `docs/pbs/specs/13. Lowering IRBackend Specification.md`
|
|
2. `docs/general/specs/20. IRBackend to IRVM Lowering Specification.md`
|
|
3. `docs/general/specs/15. Bytecode and PBX Mapping Specification.md`
|
|
4. `docs/general/specs/22. Backend Spec-to-Test Conformance Matrix.md`
|
|
|
|
## Open Questions
|
|
|
|
1. Nenhuma. Esta PR e de alinhamento normativo.
|