[all-commits] [llvm/llvm-project] fd059e: [libc] Simplify enabling the GPU build for libc

Joseph Huber via All-commits all-commits at lists.llvm.org
Mon Mar 27 11:22:44 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: fd059ea7ec044198fd75bb2b3aa30734bcace33e
      https://github.com/llvm/llvm-project/commit/fd059ea7ec044198fd75bb2b3aa30734bcace33e
  Author: Joseph Huber <jhuber6 at vols.utk.edu>
  Date:   2023-03-27 (Mon, 27 Mar 2023)

  Changed paths:
    M libc/CMakeLists.txt
    M libc/cmake/modules/LLVMLibCArchitectures.cmake
    M libc/cmake/modules/prepare_libc_gpu_build.cmake
    M llvm/runtimes/CMakeLists.txt

  Log Message:
  -----------
  [libc] Simplify enabling the GPU build for libc

Currently the GPU build requires the `LLVM_LIBC_FULL_BUILD` option to be
set. This patch changes the logic so that it is always enabled when
targeting the GPU. Also, this patch allows `LIBC_GPU_BUILD` and
`LIBC_GPU_ARCHITECTURES` to both enable a GPU build. Now, enabling the
GPU support should only require the following CMake:

```
  -DLLVM_ENABLE_RUNTIMES=libc -DLIBC_GPU_ARCHITECTURES=gfx1030
```

Reviewed By: jdoerfert, sivachandra

Differential Revision: https://reviews.llvm.org/D146979




More information about the All-commits mailing list