question: can self-dlopen() be eliminated
- Dominant language
- C
- Stars
- 140
- Forks
- 92
- Avg merge
- 8h 2m
- Merged PRs (30d)
- 7
Description
As highlighted in #60, opencl-clang dlopen() itself to get some symbol addresses via dlsym(). Can this be avoided? Why we can't get address at compile/linkage time?
dlopen() is called here:
https://github.com/intel/opencl-clang/blob/325cbb581b239f1c109f56c55292563eaefc3ac0/pch_mgr.cpp#L170
Library name to load is set here:
https://github.com/intel/opencl-clang/blob/325cbb581b239f1c109f56c55292563eaefc3ac0/CMakeLists.txt#L147
Contributor guide
Research direction
Start with the dlopen() call in pch_mgr.cpp at line 170 and the library-name configuration in CMakeLists.txt at line 147. Trace how the symbols are obtained and how the library is linked, then determine whether compile- or link-time resolution can replace the current approach. Done means documenting the conclusion and, if replacement is feasible, updating the affected implementation and build configuration.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c, cmake
- Domain
- build-system, compilers
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100