Enable 32bit cpointers by default if the given heap size is greater than 512KB
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik
@@ -55,6 +55,12 @@ if(FEATURE_SYSTEM_ALLOCATOR)
set(FEATURE_CPOINTER_32_BIT_MESSAGE " (FORCED BY SYSTEM ALLOCATOR)")
endif()
+if (MEM_HEAP_SIZE_KB GREATER 512)
+ set(FEATURE_CPOINTER_32_BIT ON)
+
+ set(FEATURE_CPOINTER_32_BIT_MESSAGE " (FORCED BY HEAP SIZE)")
+endif()
+
if(NOT FEATURE_JS_PARSER)
set(FEATURE_SNAPSHOT_EXEC ON)
set(FEATURE_PARSER_DUMP OFF)
