[clang] [llvm] [Offload] Change unregister library to use `atexit` instead of destructor (PR #86830)

Joseph Huber via cfe-commits cfe-commits at lists.llvm.org
Wed Mar 27 10:51:09 PDT 2024


================
@@ -186,57 +186,60 @@ GlobalVariable *createBinDesc(Module &M, ArrayRef<ArrayRef<char>> Bufs,
                             ".omp_offloading.descriptor" + Suffix);
 }
 
-void createRegisterFunction(Module &M, GlobalVariable *BinDesc,
-                            StringRef Suffix) {
+Function *createUnregisterFunction(Module &M, GlobalVariable *BinDesc,
----------------
jhuber6 wrote:

No, since I need to call this function from `createRegisterFunction` now. I could forward declare it but I don't think there's a point given it's inside an anonymous namespace.

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


More information about the cfe-commits mailing list