JuliaDiff / JuliaDiff/FiniteDiff.jl
Remove `allowed_getindex` when possible, for faster GPU operations
Nobody has claimed this yet.
- Dominant language
- Julia
- Stars
- 304
- Forks
- 42
- Avg merge
- 24m
- Merged PRs (30d)
- 2
Description
Hello,
I'm able to use this package with CUDA Arrays, since the allowed_getindex (for example used here) does not handle the indexing error of the CuArrays. However this slow down the computation, since this process would be transfered and than executed on the CPU.
Is it possible, for example in that for loop I linked, to avoid using the allowed_getindex function? It would be a very good improvement, not only for GPU calculations.
Contributor guide
No contributing guide indexed for this repository
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
Start with src/jacobians.jl around the linked loop and trace how allowed_getindex handles indexing errors. Compare that path with CUDA Arrays behavior and identify a supported way to avoid unnecessary CPU execution while preserving current indexing safeguards. Done means the relevant Jacobian operations no longer incur the reported slowdown without breaking existing behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- julia
- Domain
- performance
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100