7a441aef106826b8e94bf8f4f75e375091811845
Most of what hipify does is really just replacing CUDA idenitifers with HIP ones. CUDA function calls, preprocessor macro calls, enum references, types, etc. This is problematic: calls/types/enum-refs require name resolution for the AST matcher to work. This fails in the presence of code deleted by the preprocessor, and in two-pass template compilation. Instead, we can simply hook the lexer and have it rewrite the identifiers for us. This approach means identifier transformations will work correctly regardless of where they appear (and we get to delete lots of code) - Fixes #260 - Helps a bit with #207 - it will still fail to translate kernel calls in preprocessor-ignored code, but everything except kerel launches should translate correctly now, even in preprocessor-deleted code.
Περιγραφή
No description provided
Languages
C++
67.5%
C
20.6%
Python
6.6%
CMake
3.4%
Shell
0.6%
Άλλο
1.1%