Skip to content

Commit

Permalink
libuv:add threadpool DEF_THREADPOOL_PRIORITY
Browse files Browse the repository at this point in the history
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
  • Loading branch information
Gary-Hobson authored and GUIDINGLI committed Oct 15, 2024
1 parent be85fab commit 9c51919
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
6 changes: 4 additions & 2 deletions system/libuv/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,10 @@ if(CONFIG_LIBUV)
# Flags
# ############################################################################

set(CFLAGS -Wno-shadow -DDEF_THREADPOOL_SIZE=CONFIG_LIBUV_THREADPOOL_SIZE
-DDEF_THREADPOOL_STACKSIZE=CONFIG_LIBUV_THREAD_STACKSIZE)
set(CFLAGS
-Wno-shadow -DDEF_THREADPOOL_SIZE=CONFIG_LIBUV_THREADPOOL_SIZE
-DDEF_THREADPOOL_STACKSIZE=CONFIG_LIBUV_THREAD_STACKSIZE
-DDEF_THREADPOOL_PRIORITY=CONFIG_LIBUV_THREADPOOL_PRIORITY)

if(GCCVER EQUAL 12)
list(APPEND CFLAGS -Wno-dangling-pointer)
Expand Down
4 changes: 4 additions & 0 deletions system/libuv/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ config LIBUV_THREAD_STACKSIZE
int "libuv worker thread stack size"
default PTHREAD_STACK_DEFAULT

config LIBUV_THREADPOOL_PRIORITY
int "libuv default thread pool priority"
default 100

config LIBUV_BACKEND_EPOLL
bool "Using epoll backend in libuv"
default y
Expand Down

0 comments on commit 9c51919

Please sign in to comment.