[llvm] [libsycl] USM Aligned allocation functions (PR #213468)

Kseniya Tikhomirova via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 18 06:46:18 PDT 2026


================
@@ -0,0 +1,183 @@
+#include <mock/helpers.hpp>
+
+#include <sycl/__impl/device.hpp>
+#include <sycl/__impl/queue.hpp>
+#include <sycl/__impl/usm_functions.hpp>
+
+#include <detail/device_impl.hpp>
+#include <detail/queue_impl.hpp>
+
+#include <cstddef>
+#include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
+using namespace sycl;
+using namespace ::testing;
+
+TEST(USMFunctions, DeviceAllocation) {
+  constexpr size_t NumBytes = 1024;
----------------
KseniyaTikhomirova wrote:

I replied here https://github.com/llvm/llvm-project/pull/213468#discussion_r3804607662 about limitations of alignment values and  I agree with Dmitry that cases "Alignment == 0" and "Alignment is greater than zero" are different and we should check that runtime don't bring any handling on top of liboffload here.

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


More information about the llvm-commits mailing list