This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TDA4VM: Where do it allocate from when using c++ new operator?

Part Number: TDA4VM
Other Parts Discussed in Thread: SYSBIOS

Hi experts,

I'm working on psdk7.00 version. I want to use c++ new operator in rtos, but the new operator seems not allocate memory from DDR_MCUx_x_LOCAL_HEAP. So could you kindly tell me where do the new operator allocate memory from? And, is the c api malloc allocate from same place ? Is there a way redirect it to DDR_MCUx_x_LOCAL_HEAP?

Below is the link.cmd file of mcu3_1

/* linker options */
--fill_value=0
--stack_size=0x2000
--heap_size=0x1000

#define ATCM_START 0x00000000

-e __VECS_ENTRY_POINT

SECTIONS
{
    .vecs       : {
        __VECS_ENTRY_POINT = .;
    } palign(8) > R5F_TCMA
    .init_text  : {
                     boot.*(.text)
                     *(.text:ti_sysbios_family_arm_MPU_*)
                     *(.text:ti_sysbios_family_arm_v7r_Cache_*)
                  }  > R5F_TCMA
    .text:xdc_runtime_Startup_reset__I     : {} palign(8) > R5F_TCMA
    .text       : {} palign(8)   > DDR_MCU3_1
    .cinit      : {} palign(8)   > DDR_MCU3_1
    .bss        : {} align(8)    > DDR_MCU3_1
    .const      : {} palign(8)   > DDR_MCU3_1
    .data       : {} palign(128) > DDR_MCU3_1
    .sysmem     : {} align(8)    > DDR_MCU3_1
    .stack      : {} align(4)    > DDR_MCU3_1
    .bss:taskStackSection > DDR_MCU3_1
    .init_array           > DDR_MCU3_1  /* C++ initializations */

    .resource_table : {
        __RESOURCE_TABLE = .;
    } > DDR_MCU3_1_RESOURCE_TABLE

    .bss:ddr_shared_mem     (NOLOAD) : {} > DDR_MCU3_1_LOCAL_HEAP
    .bss:app_log_mem        (NOLOAD) : {} > APP_LOG_MEM
    .bss:tiovx_obj_desc_mem (NOLOAD) : {} > TIOVX_OBJ_DESC_MEM
    .bss:ipc_vring_mem      (NOLOAD) : {} > IPC_VRING_MEM
}

Regards.