[llvm] [openmp] [clang] [OpenMP] Remove `register_requires` global constructor (PR #80460)

Joseph Huber via cfe-commits cfe-commits at lists.llvm.org
Fri Feb 2 13:34:37 PST 2024


================
@@ -199,7 +199,7 @@ static int initLibrary(DeviceTy &Device) {
                                         Entry.size) != OFFLOAD_SUCCESS)
               REPORT("Failed to write symbol for USM %s\n", Entry.name);
           }
-        } else {
+        } else if (Entry.addr) {
----------------
jhuber6 wrote:

This is just hacking around the offloading entires. I wanted to use the same struct and handling for convenience, but right now there's no basic flag for what the kind of the thing is. Previously we just had functions and globals, if the size is zero it's a global. I added a third thing which can also be checked if the address is nullptr currently. I want to overhaul this in the future but I'm hoping to get this stuff working first.

https://github.com/llvm/llvm-project/pull/80460


More information about the cfe-commits mailing list