[all-commits] [llvm/llvm-project] 1e5fe6: [Libomptarget] Make the references to 'malloc' and...
Joseph Huber via All-commits
all-commits at lists.llvm.org
Wed Oct 18 09:50:36 PDT 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 1e5fe67e70d4b9612c2f64ad44a836c920894046
https://github.com/llvm/llvm-project/commit/1e5fe67e70d4b9612c2f64ad44a836c920894046
Author: Joseph Huber <35342157+jhuber6 at users.noreply.github.com>
Date: 2023-10-18 (Wed, 18 Oct 2023)
Changed paths:
M openmp/libomptarget/DeviceRTL/src/State.cpp
M openmp/libomptarget/DeviceRTL/src/exports
Log Message:
-----------
[Libomptarget] Make the references to 'malloc' and 'free' weak. (#69356)
Summary:
We use `malloc` internally in the DeviceRTL to handle data
globalization. If this is undefined it will map to the Nvidia
implementation of `malloc` for NVPTX and return `nullptr` for AMDGPU.
This is somewhat problematic, because when using this as a shared
library it causes us to always extract the GPU libc implementation,
which uses RPC and thus requires an RPC server. Making this `weak`
allows us to implement this internally without worrying about binding to
the GPU `libc` implementation.
More information about the All-commits
mailing list