aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/MachineOperand.cpp
diff options
context:
space:
mode:
authorShilei Tian <tianshilei1992@gmail.com>2021-01-11 21:33:25 -0500
committerShilei Tian <tianshilei1992@gmail.com>2021-01-11 21:33:42 -0500
commit0871d6d51648dd2a8009ddff59936ea9e3fe871b (patch)
tree6c92a5a0f620366badcbd30dad21fdebd04a5f83 /llvm/lib/CodeGen/MachineOperand.cpp
parent905623b64df0c865d4dddc4a60aff9751fbaa0e0 (diff)
downloadllvm-0871d6d51648dd2a8009ddff59936ea9e3fe871b.zip
llvm-0871d6d51648dd2a8009ddff59936ea9e3fe871b.tar.gz
llvm-0871d6d51648dd2a8009ddff59936ea9e3fe871b.tar.bz2
[OpenMP] Move memory manager to plugin and make it a common interface
The lifetime of `libomptarget` and its opened plugins are not aligned and it's hard for `libomptarget` to determine when the plugins are destroyed. As a result, some issues (see D94256 for details) occur on some platforms. Actually, if we take target memory as target resources, same as other resources, such as CUDA streams, in each plugin, then the memory manager should also be in the plugin. Also considering some platforms may want to opt out the feature, it makes sense to move the memory manager to plugin, make it a common interface, and let plguin developers determine whether they need it. This is what this patch does. CUDA plugin is taken as example to show how to integrate it. In this way, we can also get a bonus that different thresholds can be set for different platforms. Reviewed By: jdoerfert, JonChesterfield Differential Revision: https://reviews.llvm.org/D94379
Diffstat (limited to 'llvm/lib/CodeGen/MachineOperand.cpp')
0 files changed, 0 insertions, 0 deletions