@@ -879,22 +879,39 @@ namespace detail {
879879
880880 std::string expected_warning_message;
881881
882- SECTION (" in device kernels" ) {
882+ SECTION (" in device kernels, pure consumer mode " ) {
883883 q.submit ([&](handler& cgh) {
884884 accessor acc (buf, cgh, celerity::access::all (), celerity::read_only);
885885 cgh.parallel_for (range (1 ), [=](item<1 >) { (void )acc; });
886886 });
887- expected_warning_message = " Device kernel T1 declares a reading access on uninitialized B0 {[0,0,0] - [1,1,1]}. Make sure to construct the "
888- " accessor with no_init if possible." ;
887+ expected_warning_message = " Device kernel T1 declares a reading access on uninitialized B0 {[0,0,0] - [1,1,1]}." ;
889888 }
890889
891- SECTION (" in host tasks" ) {
890+ SECTION (" in device kernels, producer mode" ) {
891+ q.submit ([&](handler& cgh) {
892+ accessor acc (buf, cgh, celerity::access::all (), celerity::write_only);
893+ cgh.parallel_for (range (1 ), [=](item<1 >) { (void )acc; });
894+ });
895+ expected_warning_message = " Device kernel T1 declares a consuming access on uninitialized B0 {[0,0,0] - [1,1,1]}. Make sure to construct the "
896+ " accessor with no_init if this was unintentional." ;
897+ }
898+
899+ SECTION (" in host tasks, pure consumer mode" ) {
892900 q.submit ([&](handler& cgh) {
893901 accessor acc (buf, cgh, celerity::access::all (), celerity::read_only_host_task);
894902 cgh.host_task (on_master_node, [=] { (void )acc; });
895903 });
896- expected_warning_message = " Master-node host task T1 declares a reading access on uninitialized B0 {[0,0,0] - [1,1,1]}. Make sure to construct the "
897- " accessor with no_init if possible." ;
904+ expected_warning_message = " Master-node host task T1 declares a reading access on uninitialized B0 {[0,0,0] - [1,1,1]}." ;
905+ }
906+
907+ SECTION (" in host tasks, producer mode" ) {
908+ q.submit ([&](handler& cgh) {
909+ accessor acc (buf, cgh, celerity::access::all (), celerity::write_only_host_task);
910+ cgh.host_task (on_master_node, [=] { (void )acc; });
911+ });
912+ expected_warning_message =
913+ " Master-node host task T1 declares a consuming access on uninitialized B0 {[0,0,0] - [1,1,1]}. Make sure to construct the "
914+ " accessor with no_init if this was unintentional." ;
898915 }
899916
900917 q.wait ();
0 commit comments