[SYCL] Reuse root device build for sub-sub-devices (#20126)
This is a cherry-pick of intel/llvm#20051
Current root device ascent logic lead to reuse only for sub-devices, but
we want reuse to happen for sub-sub-devices as well, this PR fixes that.
Patch-by: Artur Gainullin <artur.gainullin@intel.com>