Skip to content

Incorporation of SpecTec into the phase advancement process #1868

@conrad-watt

Description

@conrad-watt

If (or after?) we publish the 3.0 specification using SpecTec (#1844 (comment)), we should explicitly codify what expectations we have about completeness of SpecTec support for features in the phase advancement process. Intuitively, I think this means that our current phase 4 requirement - "the spec document has been fully updated in the forked repo" should be changed to explicitly call out that some version of SpecTec should fully support the new feature (since otherwise the spec document can't be generated in the first place). I'm assuming that, in the event that the 3.0 spec is based on SpecTec, we'll be keeping a stable version of SpecTec and associated .spectec files under https://github.com/WebAssembly/spec.

Some immediate questions:

  • if an extended fork of SpecTec is necessary to support the feature, where should that fork live?
  • alternatively, should we require that the main branch of SpecTec be updated with feature support by phase 4?
  • do we want to include any requirements that the executable meta-interpreter or test generation from SpecTec function correctly, or will we still allow a separate interpreter and test suite to satisfy the process?

A possible set of new phase 4 and 5 requirements, in the hope of invoking Cunningham's Law:
Phase 4 entry:

  • A complete set of .spectec files implementing the new feature should exist
  • Some version of SpecTec (possibly a fork) should successfully consume the .spectec files to produce full prose and formal specifications for the whole language with this feature

Phase 4 during:

  • The .spectec files (and any relevant fork of SpecTec) are prepared for merging with the main branch under the WebAssembly github organisation

Phase 5:

  • The feature (including SpecTec extensions and .spectec files) is ready for merging

Practical point - threads is the feature that will stress this transition the most. We'll need to update SpecTec to...

  • handle configurations with multiple threads
  • handle reduction rules with relaxed memory effects
  • handle the relaxed memory model

If this is just about prose and formal specification generation, I think this could be done fairly quickly. If we also require as part of the phase process that the meta-interpreter or test generator work, then there will be extra engineering needed - so it's worth hashing out these choices fairly soon.

cc @rossberg

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions