Regen linux_x86_64 for Python 3.10 am: 3128e81257 am: 9512a1d5c4 am: e4e88a2087

Original change: https://android-review.googlesource.com/c/platform/external/python/cpython3/+/2037672

Change-Id: Idfb0c26e669bdf4240159bd91bdce2e7f5d68525
diff --git a/Android-bionic.bp b/Android-bionic.bp
index 3068173..690f831 100644
--- a/Android-bionic.bp
+++ b/Android-bionic.bp
@@ -54,8 +54,6 @@
         "Modules/_multiprocessing/semaphore.c",
         "Modules/_opcode.c",
         "Modules/_operator.c",
-        "Modules/parsermodule.c",
-        "Modules/_peg_parser.c",
         "Modules/_pickle.c",
         "Modules/posixmodule.c",
         "Modules/_posixsubprocess.c",
diff --git a/Android-linux_x86_64.bp b/Android-linux_x86_64.bp
index 55ed076..234b38d 100644
--- a/Android-linux_x86_64.bp
+++ b/Android-linux_x86_64.bp
@@ -56,8 +56,6 @@
         "Modules/_multiprocessing/semaphore.c",
         "Modules/_opcode.c",
         "Modules/_operator.c",
-        "Modules/parsermodule.c",
-        "Modules/_peg_parser.c",
         "Modules/_pickle.c",
         "Modules/posixmodule.c",
         "Modules/_posixsubprocess.c",
diff --git a/android/bionic/config.c b/android/bionic/config.c
index 393913d..8cdc768 100644
--- a/android/bionic/config.c
+++ b/android/bionic/config.c
@@ -34,7 +34,6 @@
 extern PyObject* PyInit__bisect(void);
 extern PyObject* PyInit__heapq(void);
 extern PyObject* PyInit__pickle(void);
-extern PyObject* PyInit_atexit(void);
 extern PyObject* PyInit__json(void);
 extern PyObject* PyInit__lsprof(void);
 extern PyObject* PyInit_unicodedata(void);
@@ -47,7 +46,6 @@
 extern PyObject* PyInit_pwd(void);
 extern PyObject* PyInit_grp(void);
 extern PyObject* PyInit_select(void);
-extern PyObject* PyInit_parser(void);
 extern PyObject* PyInit_mmap(void);
 extern PyObject* PyInit_syslog(void);
 extern PyObject* PyInit__xxsubinterpreters(void);
@@ -95,7 +93,6 @@
 extern PyObject* PyInit__io(void);
 extern PyObject* PyInit_faulthandler(void);
 extern PyObject* PyInit__tracemalloc(void);
-extern PyObject* PyInit__peg_parser(void);
 extern PyObject* PyInit__symtable(void);
 extern PyObject* PyInit_xxsubtype(void);
 
@@ -121,7 +118,6 @@
     {"_bisect", PyInit__bisect},
     {"_heapq", PyInit__heapq},
     {"_pickle", PyInit__pickle},
-    {"atexit", PyInit_atexit},
     {"_json", PyInit__json},
     {"_lsprof", PyInit__lsprof},
     {"unicodedata", PyInit_unicodedata},
@@ -134,7 +130,6 @@
     {"pwd", PyInit_pwd},
     {"grp", PyInit_grp},
     {"select", PyInit_select},
-    {"parser", PyInit_parser},
     {"mmap", PyInit_mmap},
     {"syslog", PyInit_syslog},
     {"_xxsubinterpreters", PyInit__xxsubinterpreters},
@@ -182,7 +177,6 @@
     {"_io", PyInit__io},
     {"faulthandler", PyInit_faulthandler},
     {"_tracemalloc", PyInit__tracemalloc},
-    {"_peg_parser", PyInit__peg_parser},
     {"_symtable", PyInit__symtable},
     {"xxsubtype", PyInit_xxsubtype},
 
diff --git a/android/bionic/pyconfig/pyconfig.h b/android/bionic/pyconfig/pyconfig.h
index 8974547..7e51e76 100644
--- a/android/bionic/pyconfig/pyconfig.h
+++ b/android/bionic/pyconfig/pyconfig.h
@@ -17,6 +17,12 @@
    support for AIX C++ shared extension modules. */
 /* #undef AIX_GENUINE_CPLUSPLUS */
 
+/* The normal alignment of `long', in bytes. */
+#define ALIGNOF_LONG 8
+
+/* The normal alignment of `size_t', in bytes. */
+#define ALIGNOF_SIZE_T 8
+
 /* Alternative SOABI used in debug build to load C extensions built in release
    mode */
 /* #undef ALT_SOABI */
@@ -39,6 +45,9 @@
 /* Define if --enable-ipv6 is specified */
 #define ENABLE_IPV6 1
 
+/* Better isolate subinterpreters, experimental build mode. */
+/* #undef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS */
+
 /* Define to 1 if your system stores words within floats with the most
    significant word first */
 /* #undef FLOAT_WORDS_BIGENDIAN */
@@ -113,7 +122,7 @@
 /* Define if `unsetenv` does not return an int. */
 /* #undef HAVE_BROKEN_UNSETENV */
 
-/* Has builtin atomics */
+/* Has builtin __atomic_load_n() and __atomic_store_n() functions */
 #define HAVE_BUILTIN_ATOMIC 1
 
 /* Define to 1 if you have the 'chflags' function. */
@@ -137,6 +146,9 @@
 /* Define to 1 if you have the `clock_settime' function. */
 #define HAVE_CLOCK_SETTIME 1
 
+/* Define to 1 if you have the `close_range' function. */
+/* #undef HAVE_CLOSE_RANGE */
+
 /* Define if the C compiler supports computed gotos. */
 #define HAVE_COMPUTED_GOTOS 1
 
@@ -282,6 +294,9 @@
 /* Define to 1 if you have the `dup3' function. */
 #define HAVE_DUP3 1
 
+/* Define if you have the '_dyld_shared_cache_contains_path' function. */
+/* #undef HAVE_DYLD_SHARED_CACHE_CONTAINS_PATH */
+
 /* Defined when any dynamic module loading is enabled. */
 #define HAVE_DYNAMIC_LOADING 1
 
@@ -303,6 +318,9 @@
 /* Define to 1 if you have the <errno.h> header file. */
 #define HAVE_ERRNO_H 1
 
+/* Define if you have the 'eventfd' function. */
+#define HAVE_EVENTFD 1
+
 /* Define to 1 if you have the `execv' function. */
 #define HAVE_EXECV 1
 
@@ -601,7 +619,7 @@
 /* Define to 1 if you have the <libintl.h> header file. */
 /* #undef HAVE_LIBINTL_H */
 
-/* Define if you have the readline library (-lreadline). */
+/* Define to build the readline module. */
 /* #undef HAVE_LIBREADLINE */
 
 /* Define to 1 if you have the `resolv' library (-lresolv). */
@@ -613,12 +631,18 @@
 /* Define to 1 if you have the <libutil.h> header file. */
 /* #undef HAVE_LIBUTIL_H */
 
+/* Define to 1 if you have the `uuid' library (-luuid). */
+/* #undef HAVE_LIBUUID */
+
 /* Define if you have the 'link' function. */
 #define HAVE_LINK 1
 
 /* Define to 1 if you have the `linkat' function. */
 #define HAVE_LINKAT 1
 
+/* Define to 1 if you have the <linux/auxvec.h> header file. */
+#define HAVE_LINUX_AUXVEC_H 1
+
 /* Define to 1 if you have the <linux/can/bcm.h> header file. */
 #define HAVE_LINUX_CAN_BCM_H 1
 
@@ -733,6 +757,10 @@
 /* Define to 1 if you have the `nice' function. */
 #define HAVE_NICE 1
 
+/* Define if the internal form of wchar_t in non-Unicode locales is not
+   Unicode. */
+/* #undef HAVE_NON_UNICODE_WCHAR_T_REPRESENTATION */
+
 /* Define to 1 if you have the `openat' function. */
 #define HAVE_OPENAT 1
 
@@ -781,9 +809,6 @@
 /* Define if you have the 'prlimit' functions. */
 #define HAVE_PRLIMIT 1
 
-/* Define if you have the '_dyld_shared_cache_contains_path' function. */
-/* #undef HAVE_DYLD_SHARED_CACHE_CONTAINS_PATH */
-
 /* Define to 1 if you have the <process.h> header file. */
 /* #undef HAVE_PROCESS_H */
 
@@ -842,10 +867,10 @@
 /* #undef HAVE_RL_APPEND_HISTORY */
 
 /* Define if you can turn off readline's signal handling. */
-#define HAVE_RL_CATCH_SIGNAL 1
+/* #undef HAVE_RL_CATCH_SIGNAL */
 
 /* Define if you have readline 2.2 */
-#define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
+/* #undef HAVE_RL_COMPLETION_APPEND_CHARACTER */
 
 /* Define if you have readline 4.0 */
 /* #undef HAVE_RL_COMPLETION_DISPLAY_MATCHES_HOOK */
@@ -854,7 +879,7 @@
 /* #undef HAVE_RL_COMPLETION_MATCHES */
 
 /* Define if you have rl_completion_suppress_append */
-#define HAVE_RL_COMPLETION_SUPPRESS_APPEND 1
+/* #undef HAVE_RL_COMPLETION_SUPPRESS_APPEND */
 
 /* Define if you have readline 4.0 */
 /* #undef HAVE_RL_PRE_INPUT_HOOK */
@@ -886,6 +911,9 @@
 /* Define to 1 if you have the `sched_setscheduler' function. */
 #define HAVE_SCHED_SETSCHEDULER 1
 
+/* Define to 1 if you have the `sem_clockwait' function. */
+/* #undef HAVE_SEM_CLOCKWAIT */
+
 /* Define to 1 if you have the `sem_getvalue' function. */
 #define HAVE_SEM_GETVALUE 1
 
@@ -1012,6 +1040,9 @@
 /* Define to 1 if you have the <spawn.h> header file. */
 #define HAVE_SPAWN_H 1
 
+/* Define to 1 if you have the `splice' function. */
+#define HAVE_SPLICE 1
+
 /* Define if your compiler provides ssize_t */
 #define HAVE_SSIZE_T 1
 
@@ -1037,9 +1068,6 @@
 /* Has stdatomic.h with atomic_int and atomic_uintptr_t */
 #define HAVE_STD_ATOMIC 1
 
-/* Define to 1 if you have the `strdup' function. */
-#define HAVE_STRDUP 1
-
 /* Define to 1 if you have the `strftime' function. */
 #define HAVE_STRFTIME 1
 
@@ -1119,6 +1147,9 @@
 /* Define to 1 if you have the <sys/epoll.h> header file. */
 #define HAVE_SYS_EPOLL_H 1
 
+/* Define to 1 if you have the <sys/eventfd.h> header file. */
+#define HAVE_SYS_EVENTFD_H 1
+
 /* Define to 1 if you have the <sys/event.h> header file. */
 /* #undef HAVE_SYS_EVENT_H */
 
@@ -1304,6 +1335,9 @@
 /* Define to 1 if you have the <uuid/uuid.h> header file. */
 /* #undef HAVE_UUID_UUID_H */
 
+/* Define to 1 if you have the `vfork' function. */
+#define HAVE_VFORK 1
+
 /* Define to 1 if you have the `wait3' function. */
 /* #undef HAVE_WAIT3 */
 
@@ -1338,9 +1372,6 @@
 /* Define to 1 if you have the `writev' function. */
 #define HAVE_WRITEV 1
 
-/* Define if libssl has X509_VERIFY_PARAM_set1_host and related function */
-/* #undef HAVE_X509_VERIFY_PARAM_SET1_HOST */
-
 /* Define if the zlib library has inflateCopy */
 #define HAVE_ZLIB_COPY 1
 
@@ -1494,6 +1525,9 @@
    (which you can't on SCO ODT 3.0). */
 #define SYS_SELECT_WITH_SYS_TIME 1
 
+/* Custom thread stack size depending on chosen sanitizer runtimes. */
+/* #undef THREAD_STACK_SIZE */
+
 /* Library needed by timemodule.c: librt may be needed for clock_gettime() */
 /* #undef TIMEMODULE_LIB */
 
@@ -1546,6 +1580,9 @@
    Dyld is necessary to support frameworks. */
 /* #undef WITH_DYLD */
 
+/* Define to build the readline module against Editline. */
+/* #undef WITH_EDITLINE */
+
 /* Define to 1 if libintl is needed for locale functions. */
 /* #undef WITH_LIBINTL */
 
@@ -1629,11 +1666,6 @@
 /* Define on FreeBSD to activate all library features */
 #define __BSD_VISIBLE 1
 
-/* Define to 1 if type `char' is unsigned and you are not using gcc.  */
-#ifndef __CHAR_UNSIGNED__
-/* # undef __CHAR_UNSIGNED__ */
-#endif
-
 /* Define to 'long' if <time.h> doesn't define. */
 /* #undef clock_t */
 
diff --git a/android/linux_x86_64/config.c b/android/linux_x86_64/config.c
index be62f9a..7889efe 100644
--- a/android/linux_x86_64/config.c
+++ b/android/linux_x86_64/config.c
@@ -37,7 +37,6 @@
 extern PyObject* PyInit__bisect(void);
 extern PyObject* PyInit__heapq(void);
 extern PyObject* PyInit__pickle(void);
-extern PyObject* PyInit_atexit(void);
 extern PyObject* PyInit__json(void);
 extern PyObject* PyInit__lsprof(void);
 extern PyObject* PyInit_unicodedata(void);
@@ -50,7 +49,6 @@
 extern PyObject* PyInit_pwd(void);
 extern PyObject* PyInit_grp(void);
 extern PyObject* PyInit_select(void);
-extern PyObject* PyInit_parser(void);
 extern PyObject* PyInit_mmap(void);
 extern PyObject* PyInit_syslog(void);
 extern PyObject* PyInit__xxsubinterpreters(void);
@@ -98,7 +96,6 @@
 extern PyObject* PyInit__io(void);
 extern PyObject* PyInit_faulthandler(void);
 extern PyObject* PyInit__tracemalloc(void);
-extern PyObject* PyInit__peg_parser(void);
 extern PyObject* PyInit__symtable(void);
 extern PyObject* PyInit_xxsubtype(void);
 
@@ -127,7 +124,6 @@
     {"_bisect", PyInit__bisect},
     {"_heapq", PyInit__heapq},
     {"_pickle", PyInit__pickle},
-    {"atexit", PyInit_atexit},
     {"_json", PyInit__json},
     {"_lsprof", PyInit__lsprof},
     {"unicodedata", PyInit_unicodedata},
@@ -140,7 +136,6 @@
     {"pwd", PyInit_pwd},
     {"grp", PyInit_grp},
     {"select", PyInit_select},
-    {"parser", PyInit_parser},
     {"mmap", PyInit_mmap},
     {"syslog", PyInit_syslog},
     {"_xxsubinterpreters", PyInit__xxsubinterpreters},
@@ -188,7 +183,6 @@
     {"_io", PyInit__io},
     {"faulthandler", PyInit_faulthandler},
     {"_tracemalloc", PyInit__tracemalloc},
-    {"_peg_parser", PyInit__peg_parser},
     {"_symtable", PyInit__symtable},
     {"xxsubtype", PyInit_xxsubtype},
 
diff --git a/android/linux_x86_64/pyconfig/pyconfig.h b/android/linux_x86_64/pyconfig/pyconfig.h
index c97c280..9ea733b 100644
--- a/android/linux_x86_64/pyconfig/pyconfig.h
+++ b/android/linux_x86_64/pyconfig/pyconfig.h
@@ -17,6 +17,12 @@
    support for AIX C++ shared extension modules. */
 /* #undef AIX_GENUINE_CPLUSPLUS */
 
+/* The normal alignment of `long', in bytes. */
+#define ALIGNOF_LONG 8
+
+/* The normal alignment of `size_t', in bytes. */
+#define ALIGNOF_SIZE_T 8
+
 /* Alternative SOABI used in debug build to load C extensions built in release
    mode */
 /* #undef ALT_SOABI */
@@ -39,6 +45,9 @@
 /* Define if --enable-ipv6 is specified */
 #define ENABLE_IPV6 1
 
+/* Better isolate subinterpreters, experimental build mode. */
+/* #undef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS */
+
 /* Define to 1 if your system stores words within floats with the most
    significant word first */
 /* #undef FLOAT_WORDS_BIGENDIAN */
@@ -113,7 +122,7 @@
 /* Define if `unsetenv` does not return an int. */
 /* #undef HAVE_BROKEN_UNSETENV */
 
-/* Has builtin atomics */
+/* Has builtin __atomic_load_n() and __atomic_store_n() functions */
 #define HAVE_BUILTIN_ATOMIC 1
 
 /* Define to 1 if you have the 'chflags' function. */
@@ -137,6 +146,9 @@
 /* Define to 1 if you have the `clock_settime' function. */
 #define HAVE_CLOCK_SETTIME 1
 
+/* Define to 1 if you have the `close_range' function. */
+/* #undef HAVE_CLOSE_RANGE */
+
 /* Define if the C compiler supports computed gotos. */
 #define HAVE_COMPUTED_GOTOS 1
 
@@ -215,7 +227,6 @@
 /* Define to 1 if you have the declaration of `RTLD_DEEPBIND', and to 0 if you
    don't. */
 #ifdef __GLIBC__
-// musl doesn't have RTLD_DEEPBIND
 #define HAVE_DECL_RTLD_DEEPBIND 1
 #endif
 
@@ -285,6 +296,9 @@
 /* Define to 1 if you have the `dup3' function. */
 #define HAVE_DUP3 1
 
+/* Define if you have the '_dyld_shared_cache_contains_path' function. */
+/* #undef HAVE_DYLD_SHARED_CACHE_CONTAINS_PATH */
+
 /* Defined when any dynamic module loading is enabled. */
 #define HAVE_DYNAMIC_LOADING 1
 
@@ -306,6 +320,9 @@
 /* Define to 1 if you have the <errno.h> header file. */
 #define HAVE_ERRNO_H 1
 
+/* Define if you have the 'eventfd' function. */
+#define HAVE_EVENTFD 1
+
 /* Define to 1 if you have the `execv' function. */
 #define HAVE_EXECV 1
 
@@ -602,7 +619,7 @@
 /* Define to 1 if you have the <libintl.h> header file. */
 #define HAVE_LIBINTL_H 1
 
-/* Define if you have the readline library (-lreadline). */
+/* Define to build the readline module. */
 /* #undef HAVE_LIBREADLINE */
 
 /* Define to 1 if you have the `resolv' library (-lresolv). */
@@ -614,12 +631,18 @@
 /* Define to 1 if you have the <libutil.h> header file. */
 /* #undef HAVE_LIBUTIL_H */
 
+/* Define to 1 if you have the `uuid' library (-luuid). */
+/* #undef HAVE_LIBUUID */
+
 /* Define if you have the 'link' function. */
 #define HAVE_LINK 1
 
 /* Define to 1 if you have the `linkat' function. */
 #define HAVE_LINKAT 1
 
+/* Define to 1 if you have the <linux/auxvec.h> header file. */
+#define HAVE_LINUX_AUXVEC_H 1
+
 /* Define to 1 if you have the <linux/can/bcm.h> header file. */
 #define HAVE_LINUX_CAN_BCM_H 1
 
@@ -734,6 +757,10 @@
 /* Define to 1 if you have the `nice' function. */
 #define HAVE_NICE 1
 
+/* Define if the internal form of wchar_t in non-Unicode locales is not
+   Unicode. */
+/* #undef HAVE_NON_UNICODE_WCHAR_T_REPRESENTATION */
+
 /* Define to 1 if you have the `openat' function. */
 #define HAVE_OPENAT 1
 
@@ -782,9 +809,6 @@
 /* Define if you have the 'prlimit' functions. */
 #define HAVE_PRLIMIT 1
 
-/* Define if you have the '_dyld_shared_cache_contains_path' function. */
-/* #undef HAVE_DYLD_SHARED_CACHE_CONTAINS_PATH */
-
 /* Define to 1 if you have the <process.h> header file. */
 /* #undef HAVE_PROCESS_H */
 
@@ -843,10 +867,10 @@
 /* #undef HAVE_RL_APPEND_HISTORY */
 
 /* Define if you can turn off readline's signal handling. */
-#define HAVE_RL_CATCH_SIGNAL 1
+/* #undef HAVE_RL_CATCH_SIGNAL */
 
 /* Define if you have readline 2.2 */
-#define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
+/* #undef HAVE_RL_COMPLETION_APPEND_CHARACTER */
 
 /* Define if you have readline 4.0 */
 /* #undef HAVE_RL_COMPLETION_DISPLAY_MATCHES_HOOK */
@@ -855,7 +879,7 @@
 /* #undef HAVE_RL_COMPLETION_MATCHES */
 
 /* Define if you have rl_completion_suppress_append */
-#define HAVE_RL_COMPLETION_SUPPRESS_APPEND 1
+/* #undef HAVE_RL_COMPLETION_SUPPRESS_APPEND */
 
 /* Define if you have readline 4.0 */
 /* #undef HAVE_RL_PRE_INPUT_HOOK */
@@ -887,6 +911,9 @@
 /* Define to 1 if you have the `sched_setscheduler' function. */
 #define HAVE_SCHED_SETSCHEDULER 1
 
+/* Define to 1 if you have the `sem_clockwait' function. */
+/* #undef HAVE_SEM_CLOCKWAIT */
+
 /* Define to 1 if you have the `sem_getvalue' function. */
 #define HAVE_SEM_GETVALUE 1
 
@@ -1013,6 +1040,9 @@
 /* Define to 1 if you have the <spawn.h> header file. */
 #define HAVE_SPAWN_H 1
 
+/* Define to 1 if you have the `splice' function. */
+#define HAVE_SPLICE 1
+
 /* Define if your compiler provides ssize_t */
 #define HAVE_SSIZE_T 1
 
@@ -1038,9 +1068,6 @@
 /* Has stdatomic.h with atomic_int and atomic_uintptr_t */
 #define HAVE_STD_ATOMIC 1
 
-/* Define to 1 if you have the `strdup' function. */
-#define HAVE_STRDUP 1
-
 /* Define to 1 if you have the `strftime' function. */
 #define HAVE_STRFTIME 1
 
@@ -1120,6 +1147,9 @@
 /* Define to 1 if you have the <sys/epoll.h> header file. */
 #define HAVE_SYS_EPOLL_H 1
 
+/* Define to 1 if you have the <sys/eventfd.h> header file. */
+#define HAVE_SYS_EVENTFD_H 1
+
 /* Define to 1 if you have the <sys/event.h> header file. */
 /* #undef HAVE_SYS_EVENT_H */
 
@@ -1305,6 +1335,9 @@
 /* Define to 1 if you have the <uuid/uuid.h> header file. */
 /* #undef HAVE_UUID_UUID_H */
 
+/* Define to 1 if you have the `vfork' function. */
+#define HAVE_VFORK 1
+
 /* Define to 1 if you have the `wait3' function. */
 #define HAVE_WAIT3 1
 
@@ -1339,9 +1372,6 @@
 /* Define to 1 if you have the `writev' function. */
 #define HAVE_WRITEV 1
 
-/* Define if libssl has X509_VERIFY_PARAM_set1_host and related function */
-/* #undef HAVE_X509_VERIFY_PARAM_SET1_HOST */
-
 /* Define if the zlib library has inflateCopy */
 #define HAVE_ZLIB_COPY 1
 
@@ -1491,6 +1521,9 @@
    (which you can't on SCO ODT 3.0). */
 #define SYS_SELECT_WITH_SYS_TIME 1
 
+/* Custom thread stack size depending on chosen sanitizer runtimes. */
+/* #undef THREAD_STACK_SIZE */
+
 /* Library needed by timemodule.c: librt may be needed for clock_gettime() */
 /* #undef TIMEMODULE_LIB */
 
@@ -1543,6 +1576,9 @@
    Dyld is necessary to support frameworks. */
 /* #undef WITH_DYLD */
 
+/* Define to build the readline module against Editline. */
+/* #undef WITH_EDITLINE */
+
 /* Define to 1 if libintl is needed for locale functions. */
 /* #undef WITH_LIBINTL */
 
@@ -1626,11 +1662,6 @@
 /* Define on FreeBSD to activate all library features */
 #define __BSD_VISIBLE 1
 
-/* Define to 1 if type `char' is unsigned and you are not using gcc.  */
-#ifndef __CHAR_UNSIGNED__
-/* # undef __CHAR_UNSIGNED__ */
-#endif
-
 /* Define to 'long' if <time.h> doesn't define. */
 /* #undef clock_t */