forked from dotnet/runtime
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuildstring.cpp
More file actions
54 lines (47 loc) · 1.81 KB
/
buildstring.cpp
File metadata and controls
54 lines (47 loc) · 1.81 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
#define STRINGIFY(L) #L
#define MAKESTRING(M, L) M(L)
#define STRINGIZE(X) MAKESTRING(STRINGIFY, X)
#if defined(__clang__)
#define BUILD_COMPILER \
"Clang " STRINGIZE(__clang_major__) "." STRINGIZE(__clang_minor__) "." STRINGIZE(__clang_patchlevel__)
#elif defined(_MSC_VER)
#define BUILD_COMPILER "MSVC " STRINGIZE(_MSC_FULL_VER)
#elif defined(__GNUC__)
#define BUILD_COMPILER "GCC " STRINGIZE(__GNUC__) "." STRINGIZE(__GNUC_MINOR__) "." STRINGIZE(__GNUC_PATCHLEVEL__)
#else
#define BUILD_COMPILER "Unknown"
#endif
#if defined(TARGET_X86)
#define TARGET_ARCH_STRING "x86"
#elif defined(TARGET_AMD64)
#define TARGET_ARCH_STRING "x64"
#elif defined(TARGET_ARM)
#define TARGET_ARCH_STRING "arm32"
#elif defined(TARGET_ARM64)
#define TARGET_ARCH_STRING "arm64"
#elif defined(TARGET_LOONGARCH64)
#define TARGET_ARCH_STRING "loongarch64"
#else
#define TARGET_ARCH_STRING "Unknown"
#endif
#if defined(UNIX_AMD64_ABI) || defined(UNIX_X86_ABI)
#define TARGET_OS_STRING "unix"
#elif defined(WINDOWS_AMD64_ABI) || defined(TARGET_X86)
#define TARGET_OS_STRING "win"
#else
#define TARGET_OS_STRING "universal"
#endif
#ifndef DLLEXPORT
#define DLLEXPORT
#endif
#ifdef WITH_NATIVE_PGO
#define WITH_NATIVE_PGO_MARKER "(with native PGO)"
#else
#define WITH_NATIVE_PGO_MARKER "(without native PGO)"
#endif
// This string is used by superpmi.py when measuring throughput impact of
// changes to validate that the baseline and diff JITs are comparable.
extern "C" DLLEXPORT const char jitBuildString[] =
"RyuJIT built by " BUILD_COMPILER " targeting " TARGET_OS_STRING "-" TARGET_ARCH_STRING " " WITH_NATIVE_PGO_MARKER;