Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 1 addition & 7 deletions eng/native/configureplatform.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -443,13 +443,7 @@ else()
endif(CLR_CMAKE_TARGET_UNIX)

# check if host & target os/arch combination are valid
if (CLR_CMAKE_TARGET_OS STREQUAL CLR_CMAKE_HOST_OS)
if(NOT(CLR_CMAKE_TARGET_ARCH STREQUAL CLR_CMAKE_HOST_ARCH))
if(NOT((CLR_CMAKE_HOST_ARCH_AMD64 AND CLR_CMAKE_TARGET_ARCH_ARM64) OR (CLR_CMAKE_HOST_ARCH_I386 AND CLR_CMAKE_TARGET_ARCH_ARM) OR (CLR_CMAKE_HOST_ARCH_AMD64 AND CLR_CMAKE_TARGET_ARCH_ARM) OR (CLR_CMAKE_HOST_ARCH_AMD64 AND CLR_CMAKE_TARGET_ARCH_I386)))
message(FATAL_ERROR "Invalid platform and target arch combination TARGET_ARCH=${CLR_CMAKE_TARGET_ARCH} HOST_ARCH=${CLR_CMAKE_HOST_ARCH}")
endif()
endif()
else()
if (NOT (CLR_CMAKE_TARGET_OS STREQUAL CLR_CMAKE_HOST_OS))
if(NOT (CLR_CMAKE_HOST_OS STREQUAL windows))
message(FATAL_ERROR "Invalid host and target os/arch combination. Host OS: ${CLR_CMAKE_HOST_OS}")
endif()
Expand Down
4 changes: 3 additions & 1 deletion src/coreclr/pal/inc/pal.h
Original file line number Diff line number Diff line change
Expand Up @@ -2623,7 +2623,7 @@ PALIMPORT BOOL PALAPI PAL_GetUnwindInfoSize(SIZE_T baseAddress, ULONG64 ehFrameH

#if defined(__APPLE__) && defined(__i386__)
#define PAL_CS_NATIVE_DATA_SIZE 76
#elif defined(__APPLE__) && defined(__x86_64__)
#elif defined(__APPLE__) && defined(HOST_AMD64)
#define PAL_CS_NATIVE_DATA_SIZE 120
#elif defined(__APPLE__) && defined(HOST_ARM64)
#define PAL_CS_NATIVE_DATA_SIZE 120
Expand Down Expand Up @@ -4530,12 +4530,14 @@ void _mm_setcsr(unsigned int i);

#ifdef __cplusplus

#if defined(HOST_ARM64) && defined(TARGET_ARM64)
class CORJIT_FLAGS;

PALIMPORT
VOID
PALAPI
PAL_GetJitCpuCapabilityFlags(CORJIT_FLAGS *flags);
#endif // HOST_ARM64 && TARGET_ARM64

#endif

Expand Down
4 changes: 2 additions & 2 deletions src/coreclr/pal/src/exception/seh-unwind.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ Module Name:

#endif // HOST_UNIX

#if defined(TARGET_OSX) && defined(TARGET_ARM64)
#if defined(TARGET_OSX) && defined(HOST_ARM64)
Comment thread
janvorli marked this conversation as resolved.
// MacOS uses ARM64 instead of AARCH64 to describe these registers
// Create aliases to reuse more code
enum
Expand Down Expand Up @@ -96,7 +96,7 @@ enum
UNW_AARCH64_V30 = UNW_ARM64_D30,
UNW_AARCH64_V31 = UNW_ARM64_D31
};
#endif // defined(TARGET_OSX) && defined(TARGET_ARM64)
#endif // defined(TARGET_OSX) && defined(HOST_ARM64)


//----------------------------------------------------------------------
Expand Down
9 changes: 2 additions & 7 deletions src/coreclr/pal/src/misc/jitsupport.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -148,14 +148,14 @@ static unsigned long GetCpuCapabilityFlagsFromCpuInfo()
}
#endif // defined(HOST_ARM64) && defined(__linux__)

#if defined(HOST_ARM64) && defined(TARGET_ARM64)
PALIMPORT
VOID
PALAPI
PAL_GetJitCpuCapabilityFlags(CORJIT_FLAGS *flags)
{
_ASSERTE(flags);

#if defined(HOST_ARM64)
#if HAVE_AUXV_HWCAP_H
unsigned long hwCap = getauxval(AT_HWCAP);

Expand Down Expand Up @@ -294,10 +294,5 @@ PAL_GetJitCpuCapabilityFlags(CORJIT_FLAGS *flags)
flags->Set(InstructionSet_AdvSimd);
// flags->Set(CORJIT_FLAGS::CORJIT_FLAG_HAS_ARM64_FP);
#endif // HAVE_AUXV_HWCAP_H
#elif defined(TARGET_ARM64)
// Enable ARM64 based flags by default so we always crossgen
// ARM64 intrinsics for Linux
flags->Set(InstructionSet_ArmBase);
flags->Set(InstructionSet_AdvSimd);
#endif // defined(HOST_ARM64)
}
#endif // HOST_ARM64 && TARGET_ARM64