Repository navigation
fix: correct cuTile source locations for generated constants - #1385
Arthur031221 wants to merge 5 commits into
Conversation
Use captured module spans for source locations and the current function definition for generated types, arrays and wrapper calls. Add regressions using the assertion kernel from NVIDIA#1379 and a helper in another file. Co-authored-by: Melih Elibol <1884921+elibol@users.noreply.github.com> Signed-off-by: Arthur031221 <levi74108520963@gmail.com>
|
@elibol, checking in on this one. Anything else you need from me? |
|
Reviewing this against the frontend portion of #1379 and the separate checklist in #1475. The function-definition fallback is a narrower guarantee than attributing every generated constant to its consuming statement, and that is a reasonable scope for this PR. For acceptance, please tighten the regression around that actual guarantee:
The actual assertion SIGTRAP and reopened GPU-coredump line/frames are a separate backend acceptance test. Passing source-breakpoint or frontend-location tests does not close that portion of #1379; please keep the issue open for it. #1480 owns wrapper signature locations, and #1528 owns the explicit short-circuit expression spans, so these should not become prerequisites for this targeted fix. |
Check the file, definition line, subprogram and caller chain of the generated constants in the assertion kernel and in a nested cross-file helper, in Line and Full, and that the same locations are present in the serialized bytecode. A user literal in the same kernel must keep its own line. An opt-in test checks the cubin line table with nvdisasm and DWARF. Signed-off-by: Arthur031221 <levi74108520963@gmail.com>
|
Tightened the regression in a new commit on top of the reviewed one. The assertion-kernel test now compares file, subprogram with its definition line, line and caller chain of every constant against a fixed set, so an unrelated later line fails. The generated tile size must sit exactly on the definition line of I added With On this commit |
Integrate the v0.5.0 main baseline and run the generated-constant cubin regression in the CPU/assembler CI suite. Preserve the distinct backend trap-attribution scope. Signed-off-by: Melih Elibol <1884921+elibol@users.noreply.github.com>
|
/ok to test 2794a67 |
|
Updated to Local CUDA 13.3: all 16 debug and six generated-source tests pass, including assembler/GPU/live CUDA-GDB; strict compiler Clippy and formatting pass. Blocker: the new regression fails in CUDA 13.4 CI. The 13.2 lane passes. I assembled identical bytecode with tileiras 13.3.36 and 13.4.92: 13.3 retains helper source lines in Line/Full; 13.4 substitutes generated Failing check: https://github.com/NVIDIA/cuda-rust/actions/runs/40389948453/job/121808098508. I retained the strict regression. This assembler/debug-info compatibility regression needs resolution before declaring the PR green. Actual assertion SIGTRAP/coredump attribution under #1379 remains separate. Release tracking: #1606. |
Signed-off-by: Melih Elibol <1884921+elibol@users.noreply.github.com>
|
/ok to test 933e221 |
@elibol, there was an error processing your request: See the following link for more information: https://docs.gha-runners.nvidia.com/cpr/e/2/ |
|
/ok to test 933e221 |
|
Updated to The assembler regression still runs in CI. Exact frontend/serialized origins, kernel source presence/ranges, surviving helper ranges and successful assembly remain required. Only the exact Validation: 12 CPU debug tests pass with 13.3 and 13.4; the nested-helper assembler regression passes in Line/Full with 13.2, 13.3 and 13.4.92. A test-only wrapper that changes the 13.4 assembler's reported version makes the same debug loss fail, confirming the exception does not cover future versions. This is not validation of CTK 13.5. Formatting, shell syntax and diff checks pass; self-review completed. Fresh CI is running. This fixes the CI handling, not tileiras itself. The assertion SIGTRAP/GPU-coredump attribution still open in #1379 is not closed by this PR. v0.5.0 scope remains CTK 13.5 or earlier; no dependency on an unreleased CUDA-GDB fix. Tracked in #1606. |
Signed-off-by: Melih Elibol <1884921+elibol@users.noreply.github.com>
|
/ok to test b25b4fe |
|
Updated to The known-limit handling now covers exactly 13.4.59 and 13.4.92, and the regression prints the actual assembler fingerprint. Unknown versions, including 13.5, keep the full assertions. Frontend/serialized origins, assembly success, kernel locations/ranges, and any surviving helper ranges remain strict. The backend debug-information loss itself is not fixed here. Validation:
Why the other PRs are green: this PR enables |
|
CI is now green at The CUDA 13.4 job ran the nested-helper assembler regression with the actual CI version, 13.4.59. Both Line and Full passed with explicit warnings about the existing backend debug-information loss. CUDA 13.2 passes without that exception. Exact frontend origins remain mandatory; removing the compiler fix still fails all six frontend regression tests. The same test-handling fix is now included in #1613 at |
Summary
cuTile users compiling with debug info get module-header locations for generated constants and wrapper call sites (#1379). Generated spans were resolved against the module's source base. This addresses the frontend part of #1379. Backend trap attribution remains unverified.
Changes
Resolve captured spans with their owning module and use the containing function definition for generated spans. The regression uses @elibol's assertion kernel from #1379.
Testing
Added line/full and cross-file regressions. From
cutile-rs,cargo +1.98.0 test -p cutile --locked --test debug_infopasses.just -f cuda-oxide/Justfile checkpasses (the local mirror of CI: fmt, clippy, tests, guards, docs)cargo oxide run <example>passes, orcuda-oxide/scripts/smoketest.sh -o '^<example>$'Checklist
git commit -s)Co-authored-by: Melih Elibol 1884921+elibol@users.noreply.github.com