[all-commits] [llvm/llvm-project] 158087: [Libomptarget] Remove bitcode image map used for J...
Joseph Huber via All-commits
all-commits at lists.llvm.org
Mon Dec 18 07:28:21 PST 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 1580877555f91c5ab7eed7926bb984b2f6b70bb4
https://github.com/llvm/llvm-project/commit/1580877555f91c5ab7eed7926bb984b2f6b70bb4
Author: Joseph Huber <huberjn at outlook.com>
Date: 2023-12-18 (Mon, 18 Dec 2023)
Changed paths:
M openmp/libomptarget/plugins-nextgen/common/src/JIT.cpp
Log Message:
-----------
[Libomptarget] Remove bitcode image map used for JIT processing (#75672)
Summary:
Libomptarget supports JIT by treating an LLVM-IR file as a regular input
image. The handling here used a global map to keep track of triples once
it was parsed. This was done to same time, however this created a global
constructor as well as an extra mutex to handle it. This patch removes
the use of this map.
Instead, we simply use the file magic to perform a quick check if the
input image is valid bitcode. If not, we then create a lazy module. This
should roughly equivalent to the old handling that create an IR symbol
table. Here we can prevent the module from materializing everything but
the single triple metadata we read in later.
More information about the All-commits
mailing list