[newlib-cygwin/main] Cygwin: profiler: port to AArch64
Corinna Vinschen
corinna@sourceware.org
Mon Jul 14 11:49:54 GMT 2025
https://sourceware.org/git/gitweb.cgi?p=newlib-cygwin.git;h=9bc62f10a2004e39784164468d57b85a97e1f986
commit 9bc62f10a2004e39784164468d57b85a97e1f986
Author: Radek Bartoň <radek.barton@microsoft.com>
AuthorDate: Tue Jun 10 17:11:20 2025 +0200
Commit: Corinna Vinschen <corinna@vinschen.de>
CommitDate: Mon Jul 14 13:48:15 2025 +0200
Cygwin: profiler: port to AArch64
This patch allows to build winsup/utils/profiler.cc for AArch64 by handling
target architecture condition in find_text_section function implementation.
Signed-off-by: Radek Bartoň <radek.barton@microsoft.com>
Diff:
---
winsup/utils/profiler.cc | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/winsup/utils/profiler.cc b/winsup/utils/profiler.cc
index b5ce16cf2254..4fe900b7fe67 100644
--- a/winsup/utils/profiler.cc
+++ b/winsup/utils/profiler.cc
@@ -503,8 +503,10 @@ find_text_section (LPVOID base, HANDLE h)
read_child ((void *) &machine, sizeof (machine),
&inth->FileHeader.Machine, h);
-#ifdef __x86_64__
+#if defined(__x86_64__)
if (machine != IMAGE_FILE_MACHINE_AMD64)
+#elif defined(__aarch64__)
+ if (machine != IMAGE_FILE_MACHINE_ARM64)
#else
#error unimplemented for this target
#endif
More information about the Cygwin-cvs
mailing list