3 Star 1 Fork 13

heppen/dsoftbus

forked from src-openEuler/dsoftbus 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
0002-increase-the-pthread-stack-size-of-x86-and-other-env-dsoftbus.patch 1.78 KB
一键复制 编辑 原始数据 按行查看 历史
zxstty 提交于 2023-12-06 16:01 +08:00 . change by zjq
From f22b729a9ea46420fc31fd630e7182120decd721 Mon Sep 17 00:00:00 2001
From: heppen <hepeng68@huawei.com>
Date: Tue, 27 Jun 2023 17:11:34 +0800
Subject: [PATCH] increase the pthread stack size of x86 and other env
---
adapter/common/kernel/posix/softbus_adapter_thread.c | 3 ++-
core/common/message_handler/message_handler.c | 8 --------
2 files changed, 2 insertions(+), 9 deletions(-)
diff --git a/adapter/common/kernel/posix/softbus_adapter_thread.c b/adapter/common/kernel/posix/softbus_adapter_thread.c
index f6c65e856..33eeaa922 100644
--- a/adapter/common/kernel/posix/softbus_adapter_thread.c
+++ b/adapter/common/kernel/posix/softbus_adapter_thread.c
@@ -273,7 +273,8 @@ static int32_t SoftBusConfTransPthreadAttr(SoftBusThreadAttr *threadAttr, pthrea
if (stackSize != 0) {
ret = pthread_attr_setstacksize(attr, stackSize);
if (ret != 0) {
- HILOG_ERROR(SOFTBUS_HILOG_ID, "pthread_attr_setstacksize failed, ret[%{public}d]", ret);
+ HILOG_ERROR(SOFTBUS_HILOG_ID, "pthread_attr_setstacksize failed, stacksize[%{public}lu], ret[%{public}d]",
+ stackSize, ret);
return SOFTBUS_ERR;
}
}
diff --git a/core/common/message_handler/message_handler.c b/core/common/message_handler/message_handler.c
index d83ca3e89..12a2be117 100644
--- a/core/common/message_handler/message_handler.c
+++ b/core/common/message_handler/message_handler.c
@@ -196,15 +196,7 @@ static void *LoopTask(void *arg)
static int StartNewLooperThread(SoftBusLooper *looper)
{
-#ifdef __aarch64__
#define MAINLOOP_STACK_SIZE (2 * 1024 * 1024)
-#else
-#ifdef ASAN_BUILD
-#define MAINLOOP_STACK_SIZE 10240
-#else
-#define MAINLOOP_STACK_SIZE 8192
-#endif
-#endif
int ret;
SoftBusThreadAttr threadAttr;
SoftBusThread tid;
--
2.33.0
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/heppen/dsoftbus.git
git@gitee.com:heppen/dsoftbus.git
heppen
dsoftbus
dsoftbus
master

搜索帮助