feat(newlib): add picolibc support

This commit is contained in:
Alexey Lapshin
2024-09-26 13:13:20 +07:00
parent 22a38779fb
commit 888b5f7e8d
171 changed files with 8438 additions and 1016 deletions

View File

@@ -11,6 +11,7 @@
extern "C" {
#endif
#include <stdint.h>
#include <stdlib.h>
#include <stdbool.h>

View File

@@ -1,3 +1,8 @@
/*
* SPDX-FileCopyrightText: 2024 Espressif Systems (Shanghai) CO LTD
*
* SPDX-License-Identifier: Apache-2.0
*/
/**
* These are the newlib functions present in ESP32-S2 ROM.
* See also esp32s2.rom.newlib-data.ld for the list of .data/.bss symbols used by these functions.
@@ -8,24 +13,10 @@
*/
abs = 0x40000618;
__ascii_mbtowc = 0x40007a04;
__ascii_wctomb = 0x400018d0;
PROVIDE ( __assert = 0x4001a430 );
PROVIDE ( __assert_func = 0x4001a408 );
bzero = 0x400078c8;
_cleanup_r = 0x4001a480;
creat = 0x4000788c;
div = 0x40000620;
fclose = 0x4001a804;
_fclose_r = 0x4001a714;
fflush = 0x40001bb8;
_fflush_r = 0x40001b30;
__fp_unlock_all = 0x4001a64c;
__fputwc = 0x40001770;
fputwc = 0x40001864;
_fputwc_r = 0x400017f8;
_fwalk = 0x4001bcec;
_fwalk_reent = 0x4001bd24;
isalnum = 0x400078d8;
isalpha = 0x400078e8;
isascii = 0x4001aaec;
@@ -40,11 +31,7 @@ isspace = 0x400079ac;
isupper = 0x400079c4;
labs = 0x40000648;
ldiv = 0x40000650;
__locale_ctype_ptr = 0x40001c2c;
__locale_ctype_ptr_l = 0x40001c24;
__locale_mb_cur_max = 0x40001c0c;
longjmp = 0x400005a4;
_mbtowc_r = 0x400079e0;
memccpy = 0x4001ab00;
memchr = 0x4001ab24;
memcmp = 0x4001ab40;
@@ -52,35 +39,14 @@ memcpy = 0x4001aba8;
memmove = 0x4001acb0;
memrchr = 0x4001acec;
memset = 0x4001ad3c;
open = 0x400080c4;
qsort = 0x400006f4;
rand_r = 0x40007af4;
__sclose = 0x4001a700;
__seofread = 0x4001a690;
setjmp = 0x40000540;
setlocale = 0x40001c44;
_setlocale_r = 0x40001bdc;
__sflush_r = 0x400019dc;
__sfmoreglue = 0x4001a4c8;
__sfp = 0x4001a590;
__sfp_lock_acquire = 0x4001a508;
__sfp_lock_release = 0x4001a514;
__sinit = 0x4001a538;
__sinit_lock_acquire = 0x4001a520;
__sinit_lock_release = 0x4001a52c;
srand = 0x40007a24;
__sread = 0x4001a660;
__sseek = 0x4001a6cc;
strcasecmp = 0x40007b38;
strcasestr = 0x40007b7c;
strcat = 0x4001ad90;
strchr = 0x4001adb0;
strcmp = 0x40007be4;
strcoll = 0x40007ce8;
strcpy = 0x40007cfc;
strcspn = 0x4001adcc;
strdup = 0x40007d84;
_strdup_r = 0x40007d98;
strlcat = 0x40007db8;
strlcpy = 0x4001adf8;
strlen = 0x40007e08;
@@ -89,8 +55,6 @@ strncasecmp = 0x40007e94;
strncat = 0x4001ae34;
strncmp = 0x4001ae64;
strncpy = 0x40007f20;
strndup = 0x40007fe8;
_strndup_r = 0x40007ffc;
strnlen = 0x4001ae9c;
strrchr = 0x40008040;
strsep = 0x4000806c;
@@ -99,12 +63,6 @@ strstr = 0x4001aee8;
__strtok_r = 0x4001af18;
strtok_r = 0x4001af7c;
strupr = 0x40008084;
__swbuf = 0x4000167c;
__swbuf_r = 0x400015bc;
__swrite = 0x4001a698;
toascii = 0x4001af90;
tolower = 0x40008158;
toupper = 0x40008174;
wcrtomb = 0x400012f4;
_wcrtomb_r = 0x400012a0;
_wctomb_r = 0x400018ac;

View File

@@ -0,0 +1,52 @@
/*
* SPDX-FileCopyrightText: 2023-2024 Espressif Systems (Shanghai) CO LTD
*
* SPDX-License-Identifier: Apache-2.0
*/
_cleanup_r = 0x4001a480;
creat = 0x4000788c;
open = 0x400080c4;
fclose = 0x4001a804;
_fclose_r = 0x4001a714;
fflush = 0x40001bb8;
_fflush_r = 0x40001b30;
__fp_unlock_all = 0x4001a64c;
__fputwc = 0x40001770;
fputwc = 0x40001864;
_fputwc_r = 0x400017f8;
_fwalk = 0x4001bcec;
_fwalk_reent = 0x4001bd24;
__sflush_r = 0x400019dc;
__swbuf = 0x4000167c;
__swbuf_r = 0x400015bc;
__swrite = 0x4001a698;
__sread = 0x4001a660;
__sseek = 0x4001a6cc;
srand = 0x40007a24;
__ascii_mbtowc = 0x40007a04;
__ascii_wctomb = 0x400018d0;
_mbtowc_r = 0x400079e0;
rand_r = 0x40007af4;
__sclose = 0x4001a700;
__seofread = 0x4001a690;
setlocale = 0x40001c44;
_setlocale_r = 0x40001bdc;
__sfmoreglue = 0x4001a4c8;
__sfp = 0x4001a590;
__sfp_lock_acquire = 0x4001a508;
__sfp_lock_release = 0x4001a514;
__sinit = 0x4001a538;
__sinit_lock_acquire = 0x4001a520;
__sinit_lock_release = 0x4001a52c;
strndup = 0x40007fe8;
_strndup_r = 0x40007ffc;
wcrtomb = 0x400012f4;
_wcrtomb_r = 0x400012a0;
_wctomb_r = 0x400018ac;
strdup = 0x40007d84;
_strdup_r = 0x40007d98;
__locale_ctype_ptr = 0x40001c2c;
__locale_ctype_ptr_l = 0x40001c24;
__locale_mb_cur_max = 0x40001c0c;
strcasecmp = 0x40007b38;
strcasestr = 0x40007b7c;