[compiler-rt] [compiler-rt] Fixed Android 8.1 `getauxval(AT_PAGESZ)` crashes if called from `.preinit_array`. (#113427) (PR #116121)

Florian Mayer via llvm-commits llvm-commits at lists.llvm.org
Fri Nov 22 14:36:04 PST 2024


================
@@ -1237,6 +1242,12 @@ uptr GetPageSize() {
   CHECK_EQ(rv, 0);
   return (uptr)pz;
 #    elif SANITIZER_USE_GETAUXVAL
+
+#      if SANITIZER_ANDROID && __ANDROID_API__ < 35
+  if (!strerrorname_np)
----------------
fmayer wrote:

Leave comment about the API level this was introduced by, and also add the fact that before that API level, the page size was always 4096

https://github.com/llvm/llvm-project/pull/116121


More information about the llvm-commits mailing list