[SYCL] Limit allocation size in atomic_memory_order_seq_cst test to a safe maximum size
The atomic_memory_order_seq_cst.cpp test only checks info::device::max_mem_alloc_size to limit the maximum allocation. It does not check the actual available on device. This lead to allocating exceeding amount of memory that I caught while running the test on Nvidia GTX 1650 sm_75, because the test does not check of amount of memory on the device that is free according to the OS. This commit makes it consider ext::intel::info::device::free_memory when selecting the number of iterations to perform. While that is still an intel extension, it is currently implemented on the relevant backend target for this test.
@intel/llvm-reviewers-runtime / @sergey-semenov Hi, is it possible to have a look at this. I've forgotten it's been up for while. It's not a prio, just that the test fails on some (Nvidia) GPUs.
The result of info::device::max_mem_alloc_size is not guaranteed to be exactly available on the physical hardware at the time of the allocation request, hence checking info::device::free_memory which accurately returns the currently available size in bytes free for allocation.
@intel/llvm-gatekeepers This one looks good to merge now. Thanks!