Update a few comments.
Test: N/A
Change-Id: Id5e21eaff9bc43256b8f54e708dfc862ee7e763a
diff --git a/libc/bionic/libc_init_dynamic.cpp b/libc/bionic/libc_init_dynamic.cpp
index 4eaf37a..c9da02e 100644
--- a/libc/bionic/libc_init_dynamic.cpp
+++ b/libc/bionic/libc_init_dynamic.cpp
@@ -27,8 +27,6 @@
*/
/*
- * libc_init_dynamic.c
- *
* This source files provides two important functions for dynamic
* executables:
*
@@ -38,10 +36,7 @@
* shared libraries the program depends on).
*
* - a program launch function (__libc_init), which is called after
- * all dynamic linking has been performed. Technically, it is called
- * from arch-$ARCH/bionic/crtbegin_dynamic.S which is itself called
- * by the dynamic linker after all libraries have been loaded and
- * initialized.
+ * all dynamic linking has been performed.
*/
#include <stddef.h>
diff --git a/libc/bionic/libc_init_static.cpp b/libc/bionic/libc_init_static.cpp
index 1ac4750..cf5423e 100644
--- a/libc/bionic/libc_init_static.cpp
+++ b/libc/bionic/libc_init_static.cpp
@@ -157,13 +157,6 @@
layout.finish_layout();
}
-// The program startup function __libc_init() defined here is
-// used for static executables only (i.e. those that don't depend
-// on shared libraries). It is called from arch-$ARCH/bionic/crtbegin_static.S
-// which is directly invoked by the kernel when the program is launched.
-//
-// The 'structors' parameter contains pointers to various initializer
-// arrays that must be run before the program's 'main' routine is launched.
__noreturn static void __real_libc_init(void *raw_args,
void (*onexit)(void) __unused,
int (*slingshot)(int, char**, char**),
@@ -204,6 +197,10 @@
extern "C" void __hwasan_init_static();
+// This __libc_init() is only used for static executables, and is called from crtbegin.c.
+//
+// The 'structors' parameter contains pointers to various initializer
+// arrays that must be run before the program's 'main' routine is launched.
__attribute__((no_sanitize("hwaddress")))
__noreturn void __libc_init(void* raw_args,
void (*onexit)(void) __unused,