compiler: move launch check injection to later in compilation pipeline#2903
compiler: move launch check injection to later in compilation pipeline#2903
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #2903 +/- ##
==========================================
- Coverage 83.46% 83.41% -0.05%
==========================================
Files 248 248
Lines 51570 51602 +32
Branches 4441 4447 +6
==========================================
+ Hits 43045 43046 +1
- Misses 7774 7804 +30
- Partials 751 752 +1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
|
||
| macro = [langbb['check-launch']] | ||
|
|
||
| _check_launch(graph, definition=definition, macro=macro, **kwargs) |
There was a problem hiding this comment.
Not sure this needs to be split in three functions. And if so the def/macro should be in the actual iet pass and this should just check the option
There was a problem hiding this comment.
It doesn't need to be three functions, but it is more readable that way imo. The def/macro is the same across all IETs so I don't see why it would need to go inside the IET pass itself?
There was a problem hiding this comment.
I don't think it's more readable to split a pass this small into three functions that don't have any reuse
There was a problem hiding this comment.
Pull request overview
This PR introduces an IET pass to inject a kernel-launch error check macro later in the compilation pipeline (gated by errctl), aiming to stop execution early when a device kernel launch fails.
Changes:
- Added a new
check_launchpass that wrapsKernelLaunchnodes found underIterationnodes with an additional “check launch” statement. - Added generation of a
CHECK_LAUNCHmacro definition (based onlangbberror-peeking support) and returns it via the passheadersbyproduct. - Exported
check_launchfromdevito.passes.iet.errors.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
9bfc00b to
85603ea
Compare
Other half in PRO