Repository navigation
fix(mir-importer): preserve non-terminating drops - #1361
Open
YunusMutlu wants to merge 1 commit into
Open
YunusMutlu wants to merge 1 commit into
YunusMutlu wants to merge 1 commit into
Conversation
Signed-off-by: Yunus Mutlu <mutluyunus708@gmail.com>
YunusMutlu
force-pushed
the
fix/drop-noop-termination
branch
from
October 13, 2026 12:05
ccc6877 to
80c4568
Compare
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #1360
Summary
Make the device-side drop no-op proof account for non-returning control flow. Previously, effect-free CFG and recursive call cycles could pass the proof, erasing non-terminating destructors and allowing unreachable continuations to execute. The proof now conservatively rejects these cycles while retaining constant-branch pruning, empty-shim handling, and ordinary acyclic CFG reconvergence.
Changes
drop_glueexample: a looping destructor and a destructor calling an unconditionally recursive helper.The existing smoketest runner automatically discovers the shape-check script. No new example, dependency, or integration-test framework is introduced.
Testing
just checkpasses: formatting, clippy, tests, guards, intrinsic checks, and docs.scripts/smoketest.sh -o '^drop_glue$'passes.drop_glueexample is extended.Additional validation:
-D warnings.sm_80and the optimized shape check.drop_glueGPU runtime checks pass both normally and withCUDA_OXIDE_NO_OPT=1.array_for_loopGPU runtime regression passes.Commands run:
Compiler/example checks used an explicit
CUDA_OXIDE_BACKENDpointing to a snapshot byte-identical to the backend built from the patched working tree.The shape verifier was also checked against temporary PTX fixtures. It rejects:
ret;It accepts the patched output for both probes.
The divergent kernels were never launched. Their regression coverage is compile-only; GPU runtime results refer to the existing terminating kernels.
The complete
just checkfinished successfully with non-failing warnings from test fixtures and dependency checks. This PR does not change dependencies or lock files.Checklist
git commit -s).