Skip to content

Commit

Permalink
[SYCL][ESIMD][EMU] Disable esimd_emulator build by default (#5366)
Browse files Browse the repository at this point in the history
- Enabled by '--enable-esimd-emulator'
  • Loading branch information
dongkyunahn-intel authored Jan 24, 2022
1 parent 0280558 commit ddbcbb1
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 31 deletions.
8 changes: 4 additions & 4 deletions buildbot/configure.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def do_configure(args):
libclc_targets_to_build = ''
libclc_gen_remangled_variants = 'OFF'
sycl_build_pi_cuda = 'OFF'
sycl_build_pi_esimd_emulator = 'ON'
sycl_build_pi_esimd_emulator = 'OFF'
sycl_build_pi_hip = 'OFF'
sycl_build_pi_hip_platform = 'AMD'
sycl_clang_extra_flags = ''
Expand All @@ -50,8 +50,8 @@ def do_configure(args):
if args.arm:
llvm_targets_to_build = 'ARM;AArch64'

if args.disable_esimd_emulator:
sycl_build_pi_esimd_emulator = 'OFF'
if args.enable_esimd_emulator:
sycl_build_pi_esimd_emulator = 'ON'

if args.cuda or args.hip:
llvm_enable_projects += ';libclc'
Expand Down Expand Up @@ -213,7 +213,7 @@ def main():
parser.add_argument("--hip-platform", type=str, choices=['AMD', 'NVIDIA'], default='AMD', help="choose hardware platform for HIP backend")
parser.add_argument("--hip-amd-arch", type=str, help="Sets AMD gpu architecture for llvm lit tests, this is only needed for the HIP backend and AMD platform")
parser.add_argument("--arm", action='store_true', help="build ARM support rather than x86")
parser.add_argument("--disable-esimd-emulator", action='store_true', help="exclude ESIMD_EMULATOR support")
parser.add_argument("--enable-esimd-emulator", action='store_true', help="build with ESIMD emulation support")
parser.add_argument("--no-assertions", action='store_true', help="build without assertions")
parser.add_argument("--docs", action='store_true', help="build Doxygen documentation")
parser.add_argument("--no-werror", action='store_true', help="Don't treat warnings as errors")
Expand Down
12 changes: 7 additions & 5 deletions sycl/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -336,11 +336,13 @@ if(SYCL_BUILD_PI_HIP)
list(APPEND SYCL_TOOLCHAIN_DEPLOY_COMPONENTS libspirv-builtins pi_hip)
endif()

list(APPEND SYCL_TOOLCHAIN_DEPLOY_COMPONENTS pi_esimd_emulator libcmrt-headers)
if (MSVC)
list(APPEND SYCL_TOOLCHAIN_DEPLOY_COMPONENTS libcmrt-libs libcmrt-dlls)
else()
list(APPEND SYCL_TOOLCHAIN_DEPLOY_COMPONENTS libcmrt-sos)
if(SYCL_BUILD_PI_ESIMD_EMULATOR)
list(APPEND SYCL_TOOLCHAIN_DEPLOY_COMPONENTS pi_esimd_emulator libcmrt-headers)
if (MSVC)
list(APPEND SYCL_TOOLCHAIN_DEPLOY_COMPONENTS libcmrt-libs libcmrt-dlls)
else()
list(APPEND SYCL_TOOLCHAIN_DEPLOY_COMPONENTS libcmrt-sos)
endif()
endif()

# Use it as fake dependency in order to force another command(s) to execute.
Expand Down
30 changes: 8 additions & 22 deletions sycl/doc/GetStartedGuide.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ and a wide range of compute accelerators such as GPU and FPGA.
- [Build DPC++ toolchain with support for NVIDIA CUDA](#build-dpc-toolchain-with-support-for-nvidia-cuda)
- [Build DPC++ toolchain with support for HIP AMD](#build-dpc-toolchain-with-support-for-hip-amd)
- [Build DPC++ toolchain with support for HIP NVIDIA](#build-dpc-toolchain-with-support-for-hip-nvidia)
- [Build DPC++ toolchain with support for ESIMD CPU Emulation](#build-dpc-toolchain-with-support-for-esimd-cpu)
- [Build DPC++ toolchain with support for ESIMD CPU Emulation](#build-dpc-toolchain-with-support-for-esimd-emulator)
- [Build Doxygen documentation](#build-doxygen-documentation)
- [Deployment](#deployment)
- [Use DPC++ toolchain](#use-dpc-toolchain)
Expand Down Expand Up @@ -121,7 +121,7 @@ flags can be found by launching the script with `--help`):
* `--cuda` -> use the cuda backend (see [Nvidia CUDA](#build-dpc-toolchain-with-support-for-nvidia-cuda))
* `--hip` -> use the HIP backend (see [HIP](#build-dpc-toolchain-with-support-for-hip-amd))
* `--hip-platform` -> select the platform used by the hip backend, `AMD` or `NVIDIA` (see [HIP AMD](#build-dpc-toolchain-with-support-for-hip-amd) or see [HIP NVIDIA](#build-dpc-toolchain-with-support-for-hip-nvidia))
* '--enable-esimd-cpu-emulation' -> enable ESIMD CPU emulation (see [ESIMD CPU emulation](#build-dpc-toolchain-with-support-for-esimd-cpu))
* '--enable-esimd-emulator' -> enable ESIMD CPU emulation (see [ESIMD CPU emulation](#build-dpc-toolchain-with-support-for-esimd-cpu))
* `--shared-libs` -> Build shared libraries
* `-t` -> Build type (debug or release)
* `-o` -> Path to build directory
Expand Down Expand Up @@ -261,37 +261,23 @@ CUDA 11, and using a GeForce 1060 device.
There is experimental support for DPC++ for using ESIMD CPU Emulation

This feature supports ESIMD CPU Emulation using CM_EMU library [CM
Emulation
project](https://github.com/intel/cm-cpu-emulation). Pre-built library
package will be downloaded and installed in your deploy directory
during toolchain build.
Emulation project](https://github.com/intel/cm-cpu-emulation). The
library package will be generated from source codes downloaded from
its open source project and installed in your deploy directory during
toolchain build.

To enable support for ESIMD CPU emulation, follow the instructions for
the Linux DPC++ toolchain, but add the `--enable-esimd-cpu-emulation'.
the Linux DPC++ toolchain, but add the `--enable-esimd-emulator'.

Enabling this flag requires following packages installed.

* Ubuntu 20.04
* libva-dev / 2.7.0-2
* libva-drm2 / 2.7.0-2
* libva-glx2 / 2.7.0-2
* libva-wayland2 / 2.7.0-2
* libva-x11-2 / 2.7.0-2
* libva2 / focal 2.7.0-2
* libffi-dev / 3.3-4
* libffi7 / 3.3-4
* libdrm-amdgpu1
* libdrm-common
* libdrm-dev
* libdrm-intel1
* libdrm-nouveau2
* libdrm-radeon1
* libdrm2
* libtool
* RHEL 8.*
* libffi
* libffi-devel
* libdrm
* libdrm-devel
* libva
* libva-devel

Expand Down

0 comments on commit ddbcbb1

Please sign in to comment.