Skip to content

Conversation

@AGindinson
Copy link
Contributor

FPGA compilations have a common use case of linking an object file against
an arhive that contains a pre-compiled device image. If the archive was
comprised without pulling in the object file in question, the presence
of any device kernel in the object file would signal incomplete device code
compilation/linkage.

Within the SYCL flow, a check for this case is performed by the
llvm-no-spir-kernel tool, so as to achieve a compile-time failure instead
of an obscure runtime failure due to a missing kernel.

This patch extends the Clang driver with the infrastructure to enhance
error messages upon receiving specific error codes from external tools.
The functionality is then used to enhance the diagnostic yielded by
llvm-no-spir-kernel in the aforementioned case.

Signed-off-by: Artem Gindinson artem.gindinson@intel.com

FPGA compilations have a common use case of linking an object file against
an arhive that contains a pre-compiled device image. If the archive was
comprised without pulling in the object file in question, the presence
of any device kernel in the object file would signal incomplete device code
compilation/linkage.

Within the SYCL flow, a check for this case is performed by the
llvm-no-spir-kernel tool, so as to achieve a compile-time failure instead
of an obscure runtime failure due to a missing kernel.

This patch extends the Clang driver with the infrastructure to enhance
error messages upon receiving specific error codes from external tools.
The functionality is then used to enhance the diagnostic yielded by
llvm-no-spir-kernel in the aforementioned case.

Signed-off-by: Artem Gindinson <artem.gindinson@intel.com>
@AGindinson AGindinson force-pushed the private/agindins/fpga-link-err branch 2 times, most recently from 77c96a7 to d476f8a Compare February 3, 2020 10:12
Signed-off-by: Artem Gindinson <artem.gindinson@intel.com>
@bader bader merged commit 6431be6 into intel:sycl Feb 6, 2020
@AGindinson AGindinson deleted the private/agindins/fpga-link-err branch February 21, 2020 10:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants