You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by "anchao (via GitHub)" <gi...@apache.org> on 2023/03/13 05:05:33 UTC

[GitHub] [nuttx-apps] anchao commented on a diff in pull request #1638: wasm: increase WASM_INITIAL_MEMORY if stack size is great than initial memory

anchao commented on code in PR #1638:
URL: https://github.com/apache/nuttx-apps/pull/1638#discussion_r1133445718


##########
interpreters/Wasm.mk:
##########
@@ -25,6 +25,10 @@ WASM_INITIAL_MEMORY ?= 65536
 STACKSIZE           ?= $(CONFIG_DEFAULT_TASK_STACKSIZE)
 PRIORITY            ?= SCHED_PRIORITY_DEFAULT
 
+ifeq ($(shell test $(WASM_INITIAL_MEMORY) -lt $(STACKSIZE); echo $$?),0)
+  WASM_INITIAL_MEMORY := $(shell expr $(STACKSIZE) + $(WASM_INITIAL_MEMORY))
+endif

Review Comment:
   Done, I changed INITMEMORY to a selectable configuration



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org