Spec interpreter/implementation discrepancy - a local with an invalid type and 0 count
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 35/100
- Tipo di issue
- Bug
- Chiarezza
- Da chiarire
- Stato di attività
- Attiva
- Stack tecnologico
- wasm
- Ambito
- compilers
Direzione di ricerca
Start with the linked code-section specification and the reference interpreter, then reproduce the behavior using foo.wasm and compare it with V8, SpiderMonkey, and Wasmtime. Determine whether a zero-count local's type should be validated or discarded, and document the agreed specification or implementation outcome.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
My understanding of the definition of the code section in the online specification is that if an entry in locals has n=0 count that it's discarded and not represented in the AST of a module. This means that the corresponding local's type is parsed, but not validated. The reference interpreter implements this behavior and for this input:
(module binary
"\00asm\01\00\00\00"
"\01\04\01\60\00\00" ;; Type section: 1 type
"\03\02\01\00" ;; Function section: 1 function
"\0a\07" ;; code section, 7 bytes
"\01" ;; 1 function body
"\05" ;; body size, 5 bytes
"\01" ;; 1 locals entry
"\00" ;; count: 0
"\63\01" ;; type: (ref null 1) -- not a valid type index
"\0b" ;; end
)
the spec interpreter passes. This same module (foo.wasm) does not validate in V8, SpiderMonkey, or Wasmtime, however. These engines all validate the local's type and reject the module saying that it's out-of-bounds.
I wanted to raise this as an issue to see if others have thoughts about this. I don't have a preference for how exactly to go here myself.
- Lingua principale
- WebAssembly
- Stelle
- 3.5k
- Fork
- 539
- Merge medio
- 10h 24m
- PR unite (30g)
- 11
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di WebAssembly/spec
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 54/100
WebAssembly/spec#2265 ·
I maintainer di solito rispondono entro 1 giorno
-
[js-api] A mutable global import allocates a const global before LinkErrorForse già presa @chicoxyzzy l’ha presa 1 giorno fa. Aperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 58/100
WebAssembly/spec#2253 ·
I maintainer di solito rispondono entro 1 giorno
-
[spectec] Wasm 1.0: `$instantiate` missing premisesForse già presa @rossberg l’ha presa 27 giorni fa. Aperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 68/100
WebAssembly/spec#2245 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 45/100
WebAssembly/spec#2235 · 9 commenti ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 35/100
WebAssembly/spec#2196 ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di WebAssembly/spec
Issue simili
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
I maintainer di solito rispondono entro 1 giorno
-
I-prioritize needs-triage regression-from-stable-to-beta T-lang
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
rust-lang/rust#163830 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Swift route tables omit digit constraints from generated main and testsForse già presa @dchuk l’ha presa 1 giorno fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
rubys/roundhouse#444 ·
I maintainer di solito rispondono entro 1 giorno
-
IntrinsicLowering::LowerCTPOP runs into assertion with LLVM 23Forse già presa Una pull request collegata a questa issue è aperta o già unita. Apertacrash llvm:codegen
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
llvm/llvm-project#229064 ·
I maintainer di solito rispondono entro 1 giorno
-
area:lowering kind:bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
I maintainer di solito rispondono entro 1 giorno