[libomptarget] Keep the Shadow Pointer Map up-to-date
authorGeorge Rokos <georgios.rokos@intel.com>
Tue, 13 Jul 2021 22:33:50 +0000 (15:33 -0700)
committerGeorge Rokos <georgios.rokos@intel.com>
Wed, 14 Jul 2021 22:19:58 +0000 (15:19 -0700)
commit0c7a4870c5b63935b7f0c7cbc380b497341dd203
tree3f61f51e11eec2fa4d35de307a1bbe98db8a7f33
parent58494c856a15f5b0e886c7baf5d505ac6c05dfe5
[libomptarget] Keep the Shadow Pointer Map up-to-date

D105812 introduced a regression where if a PTR_AND_OBJ entry was mapped on the device, then the OBJ was deallocated and then reallocated at a different address, the Shadow Pointer Map would still contain an entry for the PTR but pointing to the old address. This caused test `env/base_ptr_ref_count.c` to fail.

Differential Revision: https://reviews.llvm.org/D105947
openmp/libomptarget/src/omptarget.cpp