Handle field and array-element outputs accepted in statement assembly
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 53/100
Direzione di ricerca
Start at llvm/src/statement/asm.rs, especially the statement asm output-place lowering near line 259, and trace how semantic checking accepts field and index lvalues. Compare the struct-field and array-element repros with the plain variable control, then inspect existing asm tests for output storage and evaluation order. Done means supported outputs reach IR and store to the selected place with single, source-ordered address evaluation, or unsupported forms receive a source diagnostic.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Problem
Statement-form assembly accepts assignable struct fields and array elements as outputs during semantic checking, but LLVM lowering only handles a variable or a dereferenced variable. Validated programs reach E9001 instead of supported output lowering or a source diagnostic.
Starting point: statement asm output-place lowering.
Reproduction
Audited canonical master e1f8effd195b6339c3979b1e091e63c25f1da983 on Linux amd64 with checkout-built Wave 0.0.1-alpha-dev, matching std, Rust 1.89.0, Cargo jobs=2 and LLVM 21.1.8. The master SHA was rechecked before registration.
Save either example as repro.wave:
struct S { x: i64; }
fun main() {
var s: S = S { x: 0 };
asm {
"mov rax, 7"
out("rax") s.x
clobber("nostack")
};
}
Array variant:
fun main() {
var a: array<i64, 1> = [0];
asm {
"mov rax, 7"
out("rax") a[0]
clobber("nostack")
};
}
target/debug/wavec --std-root "$PWD/std" check repro.wave
target/debug/wavec --std-root "$PWD/std" --error-format=json build repro.wave --emit=ir --out-dir .tmp/asm-output-repro
Semantic checking accepts the output. IR generation exits 1 with E9001 and:
out(...) target must be variable or deref var for now: IndexAccess { ... }
compiler panic location: llvm/src/statement/asm.rs:303:18
The field variant reaches the same restricted output-place path. A plain variable output is the control case. This report establishes semantic-check/IR behavior; it does not claim execution on another architecture.
Scope
Lower the typed addresses of supported field/index output lvalues with correct storage width, source order and single evaluation. Reject any deliberately unsupported output form during semantic checking with a source diagnostic rather than an internal error. Preserve constant/mutability checks, constraints and clobbers.
Related: #512 concerns typed asm input expressions, #397 malformed asm syntax and #409 the general backend diagnostic channel. This issue is specifically the accepted output-address shape.
Completion criteria
- Both examples build through IR/object generation without E9001, or receive an intentional source diagnostic if a documented output restriction applies.
- Supported cases store the output in the selected field/element at execution.
- Side-effecting index/address computations run once in source order.
- Plain variables, supported pointer outputs, mutability checks and architecture feature gating retain coverage.
- Lingua principale
- Rust
- Stelle
- 56
- Fork
- 21
- Merge medio
- 22h 57m
- PR unite (30g)
- 46
Preparare l'ambiente
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 wavefnd/Wave
-
Reject unrepresentable POSIX listener descriptors before Unix-domain acceptForse già presa @ShahadatTest l’ha presa 2 giorni fa. Apertabug good first issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
wavefnd/Wave#1082 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
bug help wanted
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
I maintainer di solito rispondono entro 1 giorno
-
bug build help wanted
Difficoltà 4/5 3-5 giorni Idoneità per principianti 56/100
I maintainer di solito rispondono entro 1 giorno
-
bug ci help wanted
Difficoltà 4/5 3-5 giorni Idoneità per principianti 48/100
I maintainer di solito rispondono entro 1 giorno
-
Prevent compiler stack overflow on long acyclic forward type-alias chainsForse già presa @hiyouwhatsapp l’ha presa 3 giorni fa. Apertabug
Difficoltà 4/5 3-5 giorni Idoneità per principianti 35/100
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di wavefnd/Wave
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
higress-group/HiRoute#405 ·
I maintainer di solito rispondono entro 1 giorno
-
rust_analyzer flycheck: no CLI way to enable clippy from `check.overrideCommand`Forse già presa @TrapsterDK l’ha presa oggi. Apertaneeds-triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 77/100
bazelbuild/rules_rust#4392 ·
I maintainer di solito rispondono entro 2 giorni
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 73/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
I maintainer di solito rispondono entro 1 giorno
-
🐞 bug 🧩 bevy_gantz_egui
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
nannou-org/gantz#500 ·
I maintainer di solito rispondono entro 1 giorno