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-Q1: Access Host memory from DSP

Part Number: TDA4VM-Q1

Dear Sir,

I have 4 LUTs of size 5MB each for processing custom kernel running on A72.

But, I would like to run the custom Kernel on C66.

I would like to know, if Is it possible to access the host memory from C66.

if yes , then how I can access the host memory from a custom kernel running on C66?

Currently, I am using the below snippet to load LUTs to the host memory

                   vx_image mesh_img_in_arg_left;
	                    mesh_img_in_arg_left = (vx_image)vxGetObjectArrayItem(vcObj->lut_arr, 0);
	                    status = vxCopyImagePatch(mesh_img_in_arg_left,
	                         &rect, 0,
	                         &image_addr,
	                         (vx_uint32*)lutTable_left,
	                         VX_WRITE_ONLY,
	                         VX_MEMORY_TYPE_HOST);

If No, Please suggest me a way to do so or an alternative.

Thanks and Regards,

Vyom Mishra

  • Hi Vyom,

    The memory allocated for lut_arr from the host A72 is in the DDR_SHARED_REGION. Hence, it can be accessed from the C66 kernel implementation.

    On the target implementation of your kernel, inside either create or process function, you could see that the function parameter has obj_desc which is an array of obj_descriptors. 

    This would contain the memory pointer to that data object which is part of that node parameter.

    You could use the API tivxMemShared2TargetPtr() to get the physical address on C66x. 

    You could refer any target implementation of the node for the same.

    Regards,

    Nikhil

  • Dear Sir,

    Thanks for the response!

    I have followed the suggestion and it works for me(validation will be taken later on)

    But I can see the core utilization is 99%.

    I would like to know if it is possible to split the Node with replicate on multiple cores ( DSP 1 and DSP 2 ).

    Thanks and Regards,

    Vyom Mishra

  • Hi,

    I would like to know if it is possible to split the Node with replicate on multiple cores ( DSP 1 and DSP 2 ).

    Replicated nodes would be run on the same Core. It cannot be split.

    If you want to run on separate cores, you would have to create the node twice and set target to each DSP manually in the code.

    Regards,

    Nikhil