[compiler-rt] [compiler-rt] Adds builtins support for xros. (PR #83484)
via llvm-commits
llvm-commits at lists.llvm.org
Wed Mar 6 14:24:48 PST 2024
https://github.com/rohit-rao updated https://github.com/llvm/llvm-project/pull/83484
>From 852cd2791100fc9ddb86f7fe58d802df20738ad6 Mon Sep 17 00:00:00 2001
From: Rohit Rao <rohitrao at google.com>
Date: Thu, 29 Feb 2024 16:16:24 -0500
Subject: [PATCH 1/2] [compiler-rt] Adds builtins support for xros.
---
compiler-rt/cmake/builtin-config-ix.cmake | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/compiler-rt/cmake/builtin-config-ix.cmake b/compiler-rt/cmake/builtin-config-ix.cmake
index b17c43bf6a68b8..7cd286f1c3ee8b 100644
--- a/compiler-rt/cmake/builtin-config-ix.cmake
+++ b/compiler-rt/cmake/builtin-config-ix.cmake
@@ -92,6 +92,8 @@ if(APPLE)
find_darwin_sdk_dir(DARWIN_watchos_SYSROOT watchos)
find_darwin_sdk_dir(DARWIN_tvossim_SYSROOT appletvsimulator)
find_darwin_sdk_dir(DARWIN_tvos_SYSROOT appletvos)
+ find_darwin_sdk_dir(DARWIN_xrossim_SYSROOT xrsimulator)
+ find_darwin_sdk_dir(DARWIN_xros_SYSROOT xros)
# Get supported architecture from SDKSettings.
function(sdk_has_arch_support sdk_path os arch has_support)
@@ -162,6 +164,11 @@ if(APPLE)
list(APPEND DARWIN_tvossim_BUILTIN_ALL_POSSIBLE_ARCHS arm64)
endif()
endif()
+ if(COMPILER_RT_ENABLE_XROS)
+ list(APPEND DARWIN_EMBEDDED_PLATFORMS xros)
+ set(DARWIN_xros_BUILTIN_ALL_POSSIBLE_ARCHS arm64)
+ set(DARWIN_xrossim_BUILTIN_ALL_POSSIBLE_ARCHS ${X86_64} arm64)
+ endif()
set(BUILTIN_SUPPORTED_OS osx)
>From c738fe8cfa584765af0da22a7b473b76a31c4617 Mon Sep 17 00:00:00 2001
From: Rohit Rao <rohitrao at google.com>
Date: Wed, 6 Mar 2024 17:13:29 -0500
Subject: [PATCH 2/2] Review
---
compiler-rt/cmake/base-config-ix.cmake | 1 +
compiler-rt/cmake/builtin-config-ix.cmake | 4 ++--
2 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/compiler-rt/cmake/base-config-ix.cmake b/compiler-rt/cmake/base-config-ix.cmake
index 908c8a40278cf0..1e3317de80ac3a 100644
--- a/compiler-rt/cmake/base-config-ix.cmake
+++ b/compiler-rt/cmake/base-config-ix.cmake
@@ -156,6 +156,7 @@ if(APPLE)
option(COMPILER_RT_ENABLE_WATCHOS "Enable building for watchOS - Experimental" Off)
option(COMPILER_RT_ENABLE_TVOS "Enable building for tvOS - Experimental" Off)
+ option(COMPILER_RT_ENABLE_XROS "Enable building for xrOS - Experimental" Off)
else()
option(COMPILER_RT_DEFAULT_TARGET_ONLY "Build builtins only for the default target" Off)
diff --git a/compiler-rt/cmake/builtin-config-ix.cmake b/compiler-rt/cmake/builtin-config-ix.cmake
index 7cd286f1c3ee8b..d10222b7530a81 100644
--- a/compiler-rt/cmake/builtin-config-ix.cmake
+++ b/compiler-rt/cmake/builtin-config-ix.cmake
@@ -166,8 +166,8 @@ if(APPLE)
endif()
if(COMPILER_RT_ENABLE_XROS)
list(APPEND DARWIN_EMBEDDED_PLATFORMS xros)
- set(DARWIN_xros_BUILTIN_ALL_POSSIBLE_ARCHS arm64)
- set(DARWIN_xrossim_BUILTIN_ALL_POSSIBLE_ARCHS ${X86_64} arm64)
+ set(DARWIN_xros_BUILTIN_ALL_POSSIBLE_ARCHS ${ARM64} ${ARM32})
+ set(DARWIN_xrossim_BUILTIN_ALL_POSSIBLE_ARCHS arm64)
endif()
set(BUILTIN_SUPPORTED_OS osx)
More information about the llvm-commits
mailing list