[llvm] [libsycl] Add liboffload context handler to default context (PR #213249)

Kseniya Tikhomirova via llvm-commits llvm-commits at lists.llvm.org
Fri Jul 31 06:33:35 PDT 2026


================
@@ -13,15 +13,46 @@ _LIBSYCL_BEGIN_NAMESPACE_SYCL
 
 namespace detail {
 
+ContextImpl::ContextImpl(std::vector<DeviceImpl *> &&DeviceList,
+                         const async_handler &AsyncHandler,
+                         const property_list &PropList, Private)
+    : MAsyncHandler(AsyncHandler), MDevices(DeviceList) {
+  (void)PropList;
+
+  assert(!MDevices.empty() && "Device list must not be empty");
----------------
KseniyaTikhomirova wrote:

I plan to add exception to the public context ctor. Now contexy has only private ctor and device list is guaranteed to be not empty 

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


More information about the llvm-commits mailing list