Hi dear forum members,
I am using the C674x DSP of DM8127 in the IPNC Camera of APPRO (EVM).
The module comes with vlib 1.0 and I moved to vlib 2.2 as in version 1.0 there were many issues (bugs...).
i would like to understand / query 3 main things:
1. Performance of dilate / erode and pyramid build functions (VLIB_imagePyramid8, VLIB_gauss5x5PyramidKernel_8, VLIB_erode_bin_square,...).
When we run the functions in x86 ref we get some valid results (quality-wise). Then, we run them on the DSP and we get results like:
- Dilate: 500 usec (micro) and sometimes for the same image size 64x124 (but in a different flow) 20 usec.
- VLIB_gauss5x5PyramidKernel_8 on 640x480 image (following the x86 as is which performs 3x(img_height) calls): 160509 usec.
- VLIB_imagePyramid8 on 640x480 image (single call like in the ref code examples): 18069 usec.
I ran the flow at least 5 times and I always get this different results. I'm allocating all the test memory via Utils_memAlloc (can't see in utils_mem.c any difference from Utils_memAlloc_cached) and I use Utils_getCurTimeInUsec to measure the execution time (I presumed that even if this function isn't atomic my intervals are wide enough so it won't affect my measurement validity).
What can cause such a performance penalty? In the VLIB 2.2 papers I would expect, for example, for VLIB_gauss5x5PyramidKernel_8 "The compute-only performance with all buffers in L1 is 4.9 cycles per output value" i.e. for my 500 Mhz DSP and a 640x480 image something around (640x480x4.9/500e6)*1e6 =~ 3000 usec and not 18000 !!!
Can it be that I'm missing something with cache optimizations, shared memory and such... ?
2. Atomic / valid profiling - can I count on the result of Utils_getCurTimeInUsec (i.e. is it with locked ISR)?
I'm asking because I can't understand how come dilate give such a different results (consistently) in different flows on the same image dimensions.
3. Listing the disassembly of the vlib file (like with objdump).
I would like to know what is the command line (and what tool to use...) to examine the c64/67 IS of some object file (specifically *.lib in my case using DWARF/ELF format).
I tried to look into appro_dev/Source/ti_tools/cgt6x_7_3_5 and its docs but found non valid.
Thanks in advance for any help,
Regards,
Roei