[llvm] [libsycl] Implement USM fill & memset queue API (PR #217933)

Kseniya Tikhomirova via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 11 06:55:59 PDT 2026


================
@@ -172,6 +173,32 @@ QueueImpl::memcpy(void *Dest, const void *Src, std::size_t NumBytes,
   return createEvent();
 }
 
+EventImplPtr QueueImpl::fill(void *Ptr, const void *Pattern,
+                             std::size_t PatternSize, std::size_t Count,
+                             const std::vector<EventImplPtr> &DepEvents) {
+  assert(PatternSize > 0 && "Pattern size has to be greater than zero");
+  checkEventsPlatformMatch(DepEvents, MDevice.getPlatformImpl());
+  if (Count == 0) {
+    handleEventDependencies(DepEvents);
+    return createEvent();
+  }
+
+  if (!Ptr) {
----------------
KseniyaTikhomirova wrote:

https://llvm.org/docs/CodingStandards.html#don-t-use-braces-on-simple-single-statement-bodies-of-if-else-loop-statements

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


More information about the llvm-commits mailing list