samples: basic: hash_map: fix libc heap size setting
The malloc arena/heap size setting can be adjusted using different Kconfig options, depending on the libc implementation. This means prj.conf can't be used to set this value on projects that can be built for multiple libcs without generating a Kconfig warning. Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
This commit is contained in:
parent
47515f4d7b
commit
7ef8911e8c
|
@ -6,8 +6,6 @@ CONFIG_BOOT_BANNER=n
|
|||
CONFIG_LOG=y
|
||||
|
||||
CONFIG_TEST_RANDOM_GENERATOR=y
|
||||
CONFIG_COMMON_LIBC_MALLOC_ARENA_SIZE=8192
|
||||
CONFIG_NEWLIB_LIBC_MIN_REQUIRED_HEAP_SIZE=8192
|
||||
|
||||
CONFIG_SYS_HASH_FUNC32=y
|
||||
CONFIG_SYS_HASH_MAP=y
|
||||
|
|
|
@ -25,11 +25,13 @@ tests:
|
|||
libraries.hash_map.minimal.separate_chaining.djb2:
|
||||
extra_configs:
|
||||
- CONFIG_MINIMAL_LIBC=y
|
||||
- CONFIG_COMMON_LIBC_MALLOC_ARENA_SIZE=8192
|
||||
- CONFIG_SYS_HASH_MAP_CHOICE_SC=y
|
||||
- CONFIG_SYS_HASH_FUNC32_CHOICE_DJB2=y
|
||||
libraries.hash_map.minimal.open_addressing.djb2:
|
||||
extra_configs:
|
||||
- CONFIG_MINIMAL_LIBC=y
|
||||
- CONFIG_COMMON_LIBC_MALLOC_ARENA_SIZE=8192
|
||||
- CONFIG_SYS_HASH_MAP_CHOICE_OA_LP=y
|
||||
- CONFIG_SYS_HASH_FUNC32_CHOICE_DJB2=y
|
||||
# Newlib
|
||||
|
@ -37,18 +39,21 @@ tests:
|
|||
filter: TOOLCHAIN_HAS_NEWLIB == 1
|
||||
extra_configs:
|
||||
- CONFIG_NEWLIB_LIBC=y
|
||||
- CONFIG_NEWLIB_LIBC_MIN_REQUIRED_HEAP_SIZE=8192
|
||||
- CONFIG_SYS_HASH_MAP_CHOICE_SC=y
|
||||
- CONFIG_SYS_HASH_FUNC32_CHOICE_DJB2=y
|
||||
libraries.hash_map.newlib.open_addressing.djb2:
|
||||
filter: TOOLCHAIN_HAS_NEWLIB == 1
|
||||
extra_configs:
|
||||
- CONFIG_NEWLIB_LIBC=y
|
||||
- CONFIG_NEWLIB_LIBC_MIN_REQUIRED_HEAP_SIZE=8192
|
||||
- CONFIG_SYS_HASH_MAP_CHOICE_OA_LP=y
|
||||
- CONFIG_SYS_HASH_FUNC32_CHOICE_DJB2=y
|
||||
libraries.hash_map.newlib.cxx_unordered_map.djb2:
|
||||
filter: TOOLCHAIN_HAS_NEWLIB == 1
|
||||
extra_configs:
|
||||
- CONFIG_NEWLIB_LIBC=y
|
||||
- CONFIG_NEWLIB_LIBC_MIN_REQUIRED_HEAP_SIZE=8192
|
||||
- CONFIG_SYS_HASH_MAP_CHOICE_CXX=y
|
||||
- CONFIG_SYS_HASH_FUNC32_CHOICE_DJB2=y
|
||||
- CONFIG_MAIN_STACK_SIZE=2048
|
||||
|
@ -56,10 +61,12 @@ tests:
|
|||
libraries.hash_map.picolibc.separate_chaining.djb2:
|
||||
extra_configs:
|
||||
- CONFIG_PICOLIBC=y
|
||||
- CONFIG_COMMON_LIBC_MALLOC_ARENA_SIZE=8192
|
||||
- CONFIG_SYS_HASH_MAP_CHOICE_SC=y
|
||||
- CONFIG_SYS_HASH_FUNC32_CHOICE_DJB2=y
|
||||
libraries.hash_map.picolibc.open_addressing.djb2:
|
||||
extra_configs:
|
||||
- CONFIG_PICOLIBC=y
|
||||
- CONFIG_COMMON_LIBC_MALLOC_ARENA_SIZE=8192
|
||||
- CONFIG_SYS_HASH_MAP_CHOICE_OA_LP=y
|
||||
- CONFIG_SYS_HASH_FUNC32_CHOICE_DJB2=y
|
||||
|
|
Loading…
Reference in a new issue