platform_bionic/libc/bionic
Nick Desaulniers ceed466d60 libc: remove __size_mul_overflow
We should just be able to use __builtin_umull_overflow now, which expects
unsigned long parameters. We don't need __builtin_umul_overflow (which expects
unsigned ints) because Bionic is LP64 or ILP32, so for ILP32
sizeof(size_t) == sizeof(unsigned long),
so __builtin_umull_overflow will work for either ILP32 or LP64.

Test: mm
Change-Id: I872491731bca05e561767f8bfeda4c6704e10ccb
Signed-off-by: Nick Desaulniers <ndesaulniers@google.com>
2024-04-17 14:54:57 -07:00
..
__bionic_get_shell_path.cpp __bionic_get_shell_path(): explanatory comment. 2024-02-26 23:08:06 +00:00
__cmsg_nxthdr.cpp
__cxa_guard.cpp
__cxa_pure_virtual.cpp
__cxa_thread_atexit_impl.cpp
__errno.cpp
__gnu_basename.cpp
__libc_current_sigrtmax.cpp Remove <signal.h> inlines for obsolete API levels. 2023-02-24 00:28:20 +00:00
__libc_current_sigrtmin.cpp
__libc_init_main_thread.cpp Revert "Linker support for MTE globals." 2023-12-06 19:01:46 +00:00
__set_errno.cpp
__stack_chk_fail.cpp
abort.cpp
accept.cpp
access.cpp
android_crash_detail.cpp header and android_crash_detail prefix for crash_detail API 2024-02-20 23:41:38 +00:00
android_profiling_dynamic.cpp Consistently use %m rather than strerror() in logging. 2023-07-12 21:16:31 +00:00
android_set_abort_message.cpp header and android_crash_detail prefix for crash_detail API 2024-02-20 23:41:38 +00:00
android_unsafe_frame_pointer_chase.cpp Stop fp unwinding if the pc is 0. 2023-10-31 14:14:28 -07:00
arpa_inet.cpp
assert.cpp
atexit.cpp Consistently use %m rather than strerror() in logging. 2023-07-12 21:16:31 +00:00
atexit.h
atof.cpp
bionic_allocator.cpp Consistently use %m rather than strerror() in logging. 2023-07-12 21:16:31 +00:00
bionic_arc4random.cpp
bionic_call_ifunc_resolver.cpp Merge changes from topic "revert-2709995-VVPYYBKIHY" into main 2023-12-07 01:36:49 +00:00
bionic_elf_tls.cpp Fix StaticTlsLayout for atypical alignment values 2024-03-20 17:01:35 -07:00
bionic_futex.cpp bionic: fix pthread_mutex_timedlock for PI mutexes 2023-12-13 12:10:50 -08:00
bionic_netlink.cpp
bionic_netlink.h
bionic_systrace.cpp Fix recursive deadlock inside bionic_systrace 2022-01-25 20:50:12 +00:00
bionic_time_conversions.cpp bionic: fix pthread_mutex_timedlock for PI mutexes 2023-12-13 12:10:50 -08:00
brk.cpp
c16rtomb.cpp Optimize the mbs fast path slightly. 2021-11-16 11:03:19 -08:00
c32rtomb.cpp Make multibyte result constants public. 2023-08-04 19:48:35 +00:00
chmod.cpp
chown.cpp
clearenv.cpp
clock.cpp
clock_getcpuclockid.cpp
clock_nanosleep.cpp
clone.cpp
ctype.cpp Remove <ctype.h> cruft. 2023-10-06 15:06:17 +00:00
dirent.cpp
dl_iterate_phdr_static.cpp
dup.cpp
elf_note.cpp bionic: Refactor __get_elf_note() 2024-02-06 17:58:40 -08:00
empty_android_ids.h
environ.cpp
error.cpp
eventfd.cpp
exec.cpp Make fork equivalent to vfork when HWASan or MTE stack tagging is enabled. 2023-05-08 15:26:00 -07:00
execinfo.cpp Add execinfo functionality. 2021-10-20 21:53:07 +00:00
exit.cpp Make fork equivalent to vfork when HWASan or MTE stack tagging is enabled. 2023-05-08 15:26:00 -07:00
faccessat.cpp Document more clearly that we don't plan on using faccessat2(2). 2021-06-25 09:16:18 -07:00
fchmod.cpp
fchmodat.cpp
fcntl.cpp Clarify the fcntl() "that's not how F_SETFD works" error. 2023-10-12 16:04:14 +00:00
fdsan.cpp Merge "Consistently use %m rather than strerror() in logging." into main am: a4b7949aca am: f681964728 am: 12fd33dfe4 am: ea65516304 am: 42071860a1 am: d591bee9e1 2023-07-13 22:50:59 +00:00
fdtrack.cpp Disable fdtrack post-fork. 2021-04-07 19:00:45 -07:00
ffs.cpp
fgetxattr.cpp Improve <sys/xattr.h> coverage. 2021-03-08 14:09:43 -08:00
flistxattr.cpp Improve <sys/xattr.h> coverage. 2021-03-08 14:09:43 -08:00
fork.cpp Add _Fork(). 2024-02-29 20:50:58 +00:00
fortify.cpp libc: remove __size_mul_overflow 2024-04-17 14:54:57 -07:00
fpclassify.cpp
fsetxattr.cpp
ftruncate.cpp
fts.c Export fts as a static library for use with musl 2021-09-08 15:53:10 -07:00
ftw.cpp
futimens.cpp
get_device_api_level.cpp
getauxval.cpp
getcwd.cpp
getdomainname.cpp
getentropy.cpp
gethostname.cpp
getloadavg.cpp
getpagesize.cpp Remove PAGE_SIZE call sites. 2023-06-12 10:59:39 -07:00
getpgrp.cpp
getpid.cpp
getpriority.cpp
gettid.cpp
grp_pwd.cpp Simplify our trivial initgroups(), and add a test. 2024-02-14 17:19:14 -08:00
grp_pwd_file.cpp
grp_pwd_file.h
gwp_asan_wrappers.cpp [GWP-ASan] Use recoverable everywhere 2024-04-09 12:35:31 +02:00
gwp_asan_wrappers.h [GWP-ASan] Provide runtime configuration through an env var + sysprop. 2022-04-20 11:26:00 -07:00
heap_tagging.cpp Disable USE_SCUDO branches for HWASan 2024-04-04 20:07:04 +00:00
heap_tagging.h Allow init to upgrade MTE to sync. 2022-08-10 10:11:08 -07:00
heap_zero_init.cpp
heap_zero_init.h
iconv.cpp Make multibyte result constants public. 2023-08-04 19:48:35 +00:00
icu.cpp
icu_static.cpp
icu_wrappers.cpp
ifaddrs.cpp Consistently use %m rather than strerror() in logging. 2023-07-12 21:16:31 +00:00
inotify_init.cpp
ioctl.cpp
isatty.cpp Move three legacy .c files to .cpp. 2024-02-13 16:36:11 -08:00
jemalloc.h
jemalloc_wrapper.cpp Add new mallopt M_LOG_STATS. 2023-06-17 00:00:02 +00:00
killpg.cpp
langinfo.cpp
lchown.cpp
legacy_32_bit_support.cpp Add preadv2/pwritev2 wrappers. 2021-10-18 12:58:47 -07:00
lfs64_support.cpp
libc_init_common.cpp Disable USE_SCUDO branches for HWASan 2024-04-04 20:07:04 +00:00
libc_init_common.h Let executables not rely on sentinels in preinit_array/init_array/fini_array 2023-09-01 10:17:05 -07:00
libc_init_dynamic.cpp Reland^2 "[MTE] remap stacks with PROT_MTE when requested by dlopened library" 2024-02-15 17:47:19 -08:00
libc_init_static.cpp Fix StaticTlsLayout for atypical alignment values 2024-03-20 17:01:35 -07:00
libgen.cpp
link.cpp
locale.cpp Avoid using new/delete in locale.cpp 2022-06-13 17:39:32 -07:00
lockf.cpp
lstat.cpp
malloc_common.cpp Move memtag_stack out of libc_globals 2024-03-12 12:42:23 -07:00
malloc_common.h
malloc_common_dynamic.cpp Disable USE_SCUDO branches for HWASan 2024-04-04 20:07:04 +00:00
malloc_common_dynamic.h
malloc_heapprofd.cpp malloc_heapprofd: Avoid a spurious error log 2021-10-07 17:25:00 +01:00
malloc_heapprofd.h
malloc_limit.cpp Increase time to set allocation limit. 2023-08-04 13:10:48 -07:00
malloc_limit.h
malloc_tagged_pointers.h
mblen.cpp
mbrtoc16.cpp Fix mismatched return types for surrogate pairs. 2023-08-04 19:48:35 +00:00
mbrtoc32.cpp Fix result for zero-length non-null conversion. 2023-08-04 19:48:56 +00:00
mempcpy.cpp
memset_explicit.cpp Add C23's memset_explicit(). 2022-08-10 23:36:16 +00:00
mkdir.cpp
mkfifo.cpp
mknod.cpp
mmap.cpp Remove PAGE_SIZE call sites. 2023-06-12 10:59:39 -07:00
mntent.cpp
mremap.cpp Remove PAGE_SIZE call sites. 2023-06-12 10:59:39 -07:00
ndk_cruft.cpp
ndk_cruft_data.cpp
net_if.cpp
netdb.cpp
NetdClient.cpp
NetdClientDispatch.cpp
netinet_ether.cpp Clean up the <netinet/ether.h> implementation. 2024-02-16 01:23:46 +00:00
netinet_in.cpp
new.cpp
nl_types.cpp
open.cpp
pathconf.cpp Clarify _PC_REC_INCR_XFER_SIZE and _PC_REC_MAX_XFER_SIZE. 2024-02-21 19:18:09 +00:00
pause.cpp
pidfd.cpp Add wrappers for pidfd_{open,getfd,send_signal}. 2021-02-25 13:55:12 -08:00
pipe.cpp
poll.cpp De-pessimize SigSetConverter usage. 2023-07-19 12:20:07 -07:00
posix_fadvise.cpp
posix_fallocate.cpp
posix_madvise.cpp
posix_timers.cpp
preadv_pwritev.cpp Add preadv2/pwritev2 wrappers. 2021-10-18 12:58:47 -07:00
pthread_atfork.cpp
pthread_attr.cpp Reland^2 "[MTE] remap stacks with PROT_MTE when requested by dlopened library" 2024-02-15 17:47:19 -08:00
pthread_barrier.cpp
pthread_cond.cpp Remove <pthread.h> cruft. 2023-02-27 21:31:11 +00:00
pthread_create.cpp Move memtag_stack out of libc_globals 2024-03-12 12:42:23 -07:00
pthread_detach.cpp
pthread_equal.cpp
pthread_exit.cpp riscv64 SCS support. 2023-02-23 01:21:07 +00:00
pthread_getcpuclockid.cpp
pthread_getschedparam.cpp
pthread_gettid_np.cpp
pthread_internal.cpp Move memtag_stack out of libc_globals 2024-03-12 12:42:23 -07:00
pthread_internal.h Reland^2 "[MTE] remap stacks with PROT_MTE when requested by dlopened library" 2024-02-15 17:47:19 -08:00
pthread_join.cpp
pthread_key.cpp
pthread_kill.cpp
pthread_mutex.cpp Remove <pthread.h> cruft. 2023-02-27 21:31:11 +00:00
pthread_once.cpp
pthread_rwlock.cpp Clean up __always_inline 2024-04-17 10:50:41 -07:00
pthread_self.cpp
pthread_setname_np.cpp
pthread_setschedparam.cpp
pthread_sigqueue.cpp
pthread_spinlock.cpp
ptrace.cpp
pty.cpp
raise.cpp
rand.cpp
readlink.cpp
realpath.cpp
reboot.cpp
recv.cpp
recvmsg.cpp
rename.cpp Rewrite renameat(). 2022-10-04 20:13:49 +00:00
rmdir.cpp
scandir.cpp scandir: clarity improvements. 2023-03-28 22:35:24 +00:00
sched_cpualloc.cpp Move three legacy .c files to .cpp. 2024-02-13 16:36:11 -08:00
sched_cpucount.cpp Move three legacy .c files to .cpp. 2024-02-13 16:36:11 -08:00
sched_getaffinity.cpp
sched_getcpu.cpp
scudo.h
semaphore.cpp
send.cpp
setegid.cpp
seteuid.cpp
setjmp_cookie.cpp
setpgrp.cpp
sigaction.cpp Clarify which architectures do/don't need sa_restorer. 2024-01-24 14:25:00 -08:00
signal.cpp De-pessimize SigSetConverter usage. 2023-07-19 12:20:07 -07:00
sigprocmask.cpp De-pessimize SigSetConverter usage. 2023-07-19 12:20:07 -07:00
sleep.cpp
socketpair.cpp
spawn.cpp De-pessimize SigSetConverter usage. 2023-07-19 12:20:07 -07:00
stat.cpp
stdlib_l.cpp
strchr.cpp
strchrnul.cpp
strerror.cpp Add strerrordesc_np() and strerrorname_np(). 2023-09-27 11:21:12 -07:00
string_l.cpp
strings_l.cpp
strnlen.cpp string/memory functions: avoid qemu bugs/performance issues. 2023-11-15 15:49:57 -08:00
strrchr.cpp
strsignal.cpp Add strerrordesc_np() and strerrorname_np(). 2023-09-27 11:21:12 -07:00
strtol.cpp Microoptimize the strtol() family. 2023-12-13 10:46:42 -08:00
strtold.cpp Remove __RENAME_LDBL. 2023-06-07 17:20:53 +00:00
swab.cpp
symlink.cpp
sync_file_range.cpp
sys_epoll.cpp Add epoll_pwait2(). 2023-08-23 15:59:12 -07:00
sys_msg.cpp
sys_sem.cpp
sys_shm.cpp
sys_signalfd.cpp De-pessimize SigSetConverter usage. 2023-07-19 12:20:07 -07:00
sys_statfs.cpp
sys_statvfs.cpp Use inline keyword without underscores consistently 2024-04-17 10:51:09 -07:00
sys_thread_properties.cpp
sys_time.cpp
sysconf.cpp sysconf()/getpagesize() documentation. 2024-03-27 21:23:42 +00:00
sysinfo.cpp Remove PAGE_SIZE call sites. 2023-06-12 10:59:39 -07:00
syslog.cpp syslog.h: implement LOG_PERROR. 2023-05-03 14:19:40 -07:00
sysprop_helpers.cpp Revert "Add debug logging for memtag level" 2023-05-18 01:27:52 +00:00
sysprop_helpers.h Revert "Add debug logging for memtag level" 2023-05-18 01:27:52 +00:00
system.cpp Add the missing '--' to shell invocations. 2021-11-04 17:29:35 -07:00
system_property_api.cpp Move __system_properties_reload to LIBC from LIBC_PLATFORM 2023-10-25 17:41:33 -07:00
system_property_set.cpp Merge Android U (ab/10368041) 2023-08-23 14:43:14 -07:00
tdestroy.cpp
termios.cpp <termios.h>: add two new POSIX functions. 2023-08-29 09:33:04 -07:00
thread_private.cpp
threads.cpp
time.cpp <time.h>: change the new C23 TIME_ constants. 2023-05-03 15:37:46 -07:00
time64.c Bump tzcode from 2016g to 2022a*. 2022-06-07 09:59:16 +01:00
time64_config.h
time_l.cpp Sync strptime.c with upstream. 2022-12-12 20:56:12 +00:00
tmpfile.cpp Make tmpfile() respect $TMPDIR. 2023-04-18 17:11:06 -07:00
umount.cpp
unlink.cpp
usleep.cpp
utmp.cpp
vdso.cpp Microoptimize vdso lookup. 2023-12-12 15:13:03 -08:00
wait.cpp
wchar.cpp Make multibyte result constants public. 2023-08-04 19:48:35 +00:00
wchar_l.cpp Expose tzalloc()/localtime_rz()/mktime_z()/tzfree(). 2023-06-16 08:10:47 -07:00
wcstod.cpp Remove __RENAME_LDBL. 2023-06-07 17:20:53 +00:00
wctype.cpp
wcwidth.cpp
wmempcpy.cpp