IntelLLVM: Use compiler driver as linker for MODULE libraries too
Since !6866 (merged) we default to the compiler driver as linker for executables, shared libraries, and static libraries. Not doing so for shared modules was an oversight. Copying the shared library command line for shared modules fixes the problem (and also is what we do for MSVC).
The MSVC linker is fine for many cases, however it does not support GPU offload code generated by the IntelLLVM compilers. Using the compiler driver as linker, or at least a linker that understands the object format, is required for linking shared modules that use GPU offload (e.g., with SYCL or OpenMP).
Signed-off-by: William R. Dieter william.r.dieter@intel.com
Edited by Brad King