Make ICVs work across the board
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
openmp/libomptarget/deviceRTLs/common/include/ThreadState.h | ||
---|---|---|
53 | I think we want a per warp array as we can reasonably synchronize then. The first draft did not have a preallocated array at all but it is hard to create it properly at runtime if you have no idea what threads are running. | |
openmp/libomptarget/deviceRTLs/common/src/ICVs.cpp | ||
100 | This is a scheme that needs to be generalized for other "setters". | |
openmp/libomptarget/deviceRTLs/common/src/parallel.cu | ||
260 | conceptually this should be the other way around, omp_get_thread_num calls this function. However, we should make the names actually match, so the impl. of omp_XXX is in __kmpc_XXX. |
openmp/libomptarget/deviceRTLs/common/include/ThreadState.h | ||
---|---|---|
53 | If we can get rid of static allocation here (basically the array) and use a dynamic one, it can help us a lot in terms of separating common part and target dependent part. |
@tianshilei1992 would you mind taking over the patch?
openmp/libomptarget/deviceRTLs/common/include/ThreadState.h | ||
---|---|---|
53 | I would prefer a dynamic one yes. potentially even one per warp. The elements would be WarpStateTy which is WARP_SIZE*ThreadStateTy. |
I think we want a per warp array as we can reasonably synchronize then. The first draft did not have a preallocated array at all but it is hard to create it properly at runtime if you have no idea what threads are running.