@@ -58,7 +58,7 @@ class kernel_bundle_impl {
58
58
59
59
using SpecConstMapT = std::map<std::string, std::vector<unsigned char >>;
60
60
61
- void common_ctor_checks (bundle_state State) {
61
+ void common_ctor_checks () const {
62
62
const bool AllDevicesInTheContext =
63
63
checkAllDevicesAreInContext (MDevices, MContext);
64
64
if (MDevices.empty () || !AllDevicesInTheContext)
@@ -67,12 +67,12 @@ class kernel_bundle_impl {
67
67
" Not all devices are associated with the context or "
68
68
" vector of devices is empty" );
69
69
70
- if (bundle_state::input == State &&
70
+ if (bundle_state::input == MState &&
71
71
!checkAllDevicesHaveAspect (MDevices, aspect::online_compiler))
72
72
throw sycl::exception (make_error_code (errc::invalid),
73
73
" Not all devices have aspect::online_compiler" );
74
74
75
- if (bundle_state::object == State &&
75
+ if (bundle_state::object == MState &&
76
76
!checkAllDevicesHaveAspect (MDevices, aspect::online_linker))
77
77
throw sycl::exception (make_error_code (errc::invalid),
78
78
" Not all devices have aspect::online_linker" );
@@ -82,7 +82,7 @@ class kernel_bundle_impl {
82
82
kernel_bundle_impl (context Ctx, std::vector<device> Devs, bundle_state State)
83
83
: MContext(std::move(Ctx)), MDevices(std::move(Devs)), MState(State) {
84
84
85
- common_ctor_checks (State );
85
+ common_ctor_checks ();
86
86
87
87
MDeviceImages = detail::ProgramManager::getInstance ().getSYCLDeviceImages (
88
88
MContext, MDevices, State);
@@ -267,7 +267,7 @@ class kernel_bundle_impl {
267
267
bundle_state State)
268
268
: MContext(std::move(Ctx)), MDevices(std::move(Devs)), MState(State) {
269
269
270
- common_ctor_checks (State );
270
+ common_ctor_checks ();
271
271
272
272
MDeviceImages = detail::ProgramManager::getInstance ().getSYCLDeviceImages (
273
273
MContext, MDevices, KernelIDs, State);
@@ -278,7 +278,7 @@ class kernel_bundle_impl {
278
278
const DevImgSelectorImpl &Selector, bundle_state State)
279
279
: MContext(std::move(Ctx)), MDevices(std::move(Devs)), MState(State) {
280
280
281
- common_ctor_checks (State );
281
+ common_ctor_checks ();
282
282
283
283
MDeviceImages = detail::ProgramManager::getInstance ().getSYCLDeviceImages (
284
284
MContext, MDevices, Selector, State);
0 commit comments