microsoft / microsoft/OpenCLOn12
Resource migration tasks need more graceful handling of resource allocation failure
Open
Nobody has claimed this yet.
bug
- Dominant language
- C++
- Stars
- 130
- Forks
- 19
- Avg merge
- 11d 23h
- Merged PRs (30d)
- 2
Description
If a resource migration task fails, it can throw an exception. There may not be a handler for this exception, if this is happening from the task thread, which results in an abort. There's 2 things we should fix here:
- Ensure there's a handler so this doesn't tear down the entire app.
- Ensure future accesses to that resource can deal with having a null active resource from allocation failure, to avoid nullptr accesses from just crashing the app later on.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Trace resource migration tasks from the task thread and follow how allocation failures propagate into resource access. Check the failure path for exception handling and the later handling of a null active resource. Done means migration failure no longer aborts the application and subsequent accesses avoid null-pointer crashes.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100