Visible to Intel only — GUID: GUID-B664B2ED-D16F-4B64-8B8B-24E6CAF21AAC
Example GPU Commands
The examples below illustrate how to create and use static libraries with device code on Linux.
NOTE:
Linking with a dynamic library is not supported.
Produce a fat object with device code:
icpx -fsycl -c static_lib.cpp
Create a fat static library out of it using the ar tool:
ar cr libstlib.a static_lib.o
Compile application sources:
icpx -fsycl -c a.cpp
Link the application with the static library:
icpx -fsycl -foffload-static-lib=libstlib.a a.o -o a.exe