[llvm] [OFFLOAD][L0] Implement Event APIs (PR #201306)

Nick Sarnie via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 3 08:06:22 PDT 2026


================
@@ -0,0 +1,124 @@
+//===--- Level Zero Target RTL Implementation -----------------------------===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+//
+//===----------------------------------------------------------------------===//
+//
+// Level Zero Event and Event Pool abstractions.
+//
+//===----------------------------------------------------------------------===//
+
+#ifndef OPENMP_LIBOMPTARGET_PLUGINS_NEXTGEN_LEVEL_ZERO_L0EVENT_H
+#define OPENMP_LIBOMPTARGET_PLUGINS_NEXTGEN_LEVEL_ZERO_L0EVENT_H
+
+#include <level_zero/ze_api.h>
+#include <memory>
+#include <mutex>
+
+#include "L0Defs.h"
+#include "L0Trace.h"
+
+namespace llvm::omp::target::plugin {
+
+class L0QueueTy;
+
+class L0EventTy {
+  ze_event_handle_t ZeEvent;
----------------
sarnex wrote:

should we init `ZeEvent` to nullptr too?

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


More information about the llvm-commits mailing list