]> git.proxmox.com Git - wasi-libc.git/commit
Use constructor functions for optional init routines. (#142)
authorDan Gohman <sunfish@mozilla.com>
Mon, 25 Nov 2019 22:04:45 +0000 (14:04 -0800)
committerGitHub <noreply@github.com>
Mon, 25 Nov 2019 22:04:45 +0000 (14:04 -0800)
commit410c66070a2ca1724531558048f78851cc9d43fe
tree84792cfc419a3d7e049b21f98e85fdee91ab5bac
parentfe130532ae0d7c416f24f5a71c808820f42d005f
Use constructor functions for optional init routines. (#142)

* Use constructor functions for optional init routines.

Instead of using weak symbols, use constructor function attributes for the
environment and preopen initialization routines. This is simpler, uses
less code, and is more LTO-friendly.

* Change the constructor priorities to start at 50.

We don't currently have specific plans for other levels in the reserved
range (0-100), so leave room for both lower and higher priorities.
expected/wasm32-wasi/defined-symbols.txt
libc-bottom-half/crt/crt1.c
libc-bottom-half/headers/private/wasi/libc-internal.h [deleted file]
libc-bottom-half/libpreopen/libpreopen.c
libc-bottom-half/sources/__environ.c