Page 2 - Important Benchmarks for Video Applications; Frame rate
SPRAA56 2 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application Figures Figure 1. Basic Data Flow of the Video Application...................................................................... 4 Figure 2. Detailed Application Data Flow Showing Memory Buffers ...................
Page 3 - Base Application Overview; xDAIS-compliant algorithms
SPRAA56 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application 3 Quantization is the process of dividing a continuous range of input values into a finite number of subranges. Each subrange is assigned a specific output value. The Q factor, or quantization factor, describes th...
Page 4 - Figure 1. Basic Data Flow of the Video Application; Developer’s Guide; tskVideoProcess; tskInput
SPRAA56 4 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application Figure 1 shows a simplified view of the sequential flow of capture, processing, and display tasks in the application. Figure 1. Basic Data Flow of the Video Application Before video data reaches the first stage,...
Page 7 - Requirements for Viewing RTA Benchmarks; Modifications to the Base Example
SPRAA56 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application 7 2.2 Requirements for Viewing RTA Benchmarks In order for any of the DSP/BIOS-based RTA tools to be visible, the DSP/BIOS components in Code Composer Studio version 2.30 or earlier and version 3.0 require that th...
Page 8 - Figure 2. Detailed Application Data Flow Showing Memory Buffers; Splitting the Encode and Decode CELLs
SPRAA56 8 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application D e v ic e D rive rB u ffe r 3 fra m e s D e v ic e D rive rB u ffe r 3 fra m e s D e vic e D riv e rB u ffe r 3 fra m e s Y A fte r4 2 0 4 1 4 K B C r A fte r 4 2 0 Y u v 4 2 2 t o 4 2 0 C b A f te r4 2 0 Y u v...
Page 9 - ts k P r o c e s s; ts k In p u t; Querying the H.263 Encoder for Status
SPRAA56 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application 9 if(controlVideoProc.frameRateChanged) { txMsg.cmd = FRAMERATECHANGED; txMsg.arg1 = chanNum; txMsg.arg2 = controlVideoProc.frameRateTarget; controlVideoProc.frameRateChanged = FALSE; MBX_post( &mbxProcess, &a...
Page 10 - Controlling the Frame Rate
SPRAA56 10 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application This call returns a status structure of type IH263ENC_Status that contains the number of bits sent to the encoder, the frame type, and other data. The features implemented in the control API can vary widely fro...
Page 11 - RTA Techniques for Performance Measurement; Measuring Function Execution Time with the UTL Module; “sts” + task pseudonym + function benchmarked
SPRAA56 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application 11 4 RTA Techniques for Performance Measurement The RTA techniques described in this section are largely application-specific calls to DSP/BIOS RTA services via APIs in the run-time code. These API calls can be ad...
Page 12 - Measuring Task Scheduling Latencies; Scheduling latency
SPRAA56 12 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application 4.2 Measuring Task Scheduling Latencies Scheduling latency is defined as the time between a wakeup signal (semaphore post) to a pending task and the actual start of that task's execution. DSP/BIOS provides a me...
Page 13 - Measuring the Frame Rate
SPRAA56 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application 13 The low-resolution CLK_getltime API is used instead of the high-resolution CLK_gethtime because the range of the latency is known to be on the order of one or more frame times, where a frame time is 33.33 ms in...
Page 14 - Programmatic Measurement of Total CPU Load
SPRAA56 14 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application last30frame.current = CLK_getltime(); // check to see if we dropped any frames benchVid.framesDropped.current = last30frame.current - last30frame.previous; benchVid.framesDropped.current -= 1000*(frameCnt / DIS...
Page 15 - Figure 4. CPU Load Measurement at Run-Time; To use the LOAD module in a project, follow these steps:; Memory Bus Utilization; memory bus
SPRAA56 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application 15 Window = 500ms (default) t0 t1 t0 t1 ‘minloop’ (in units of ~ cycles) ‘count’ is # hits of LOAD_idlefxn in the window cpuload = (100 - ((100 * (count * minloop)) / total)) IDL load 100 – IDLload gives App CPU L...
Page 16 - internal L2; Cb; Cb; scratch
SPRAA56 16 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application In video applications that handle the full resolution of 720x480, each from contains about 675 KB of data. Such applications must constantly move video frames from internal working memory buffers to external fr...
Page 17 - Bitrate and Frame Type; Bitrate
SPRAA56 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application 17 These estimates are fairly accurate for the color conversion functions in the input and display tasks, but the estimates are less accurate for the encoder and decoder algorithms in the processing task. Ideally,...
Page 18 - Methods for Transmitting Measured Performance Data
SPRAA56 18 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application Most current encoders use three primary frame types: Intracoded frames, Predicted frames, and Bidirectional predicted frames. These are referred to as I, P, and B frames. The H.263 encoder supplied with the exa...
Page 19 - Application-Specific Control via GEL Scripts in CCStudio; Viewing Benchmarks in the Instrumented Application; DM642 EVM and Board Support Package
SPRAA56 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application 19 The benchmarking routines send out selected benchmark data at a prescribed interval: every 30 th frame, every I (Intracoded) frame, or only on a dropped frame. The interval can be selected by controlling the .r...
Page 20 - Running the Application
SPRAA56 20 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application The application supplied with this note references board support software and libraries installed with the DM642 EVM. The project options assume this software is installed in $TI_DIR$\boards\evmdm642. The proje...
Page 22 - Figure 6. Workspace Including RTA Windows; Interpreting the Benchmarks
SPRAA56 22 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application Figure 6. Workspace Including RTA Windows 5.3 Interpreting the Benchmarks There are a total of 20 statistics measured by the application: 16 application-specific STS objects and 4 objects created automatically ...
Page 23 - Figure 7. Statistics View Showing Benchmark Measurements; Expected Values for the STS Objects
SPRAA56 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application 23 Figure 7. Statistics View Showing Benchmark Measurements Look at both the average values and the maximum values to see how the application benchmarks are performing. Note that STS objects hold 32-bit values on ...
Page 24 - Expected and Measured STS Benchmarks
SPRAA56 24 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application In the input and output tasks, Cell0 is the color conversion routine. In the processing task, Cell0 is the encoder and Cell1 is the decoder. The expected values for color conversion routines are given as 2-5 ms...
Page 25 - Expected Values Delivered to the Message Log; Expected and Measured Logged Benchmarks; Controlling the Run-Time Parameters Dynamically; passthroughReference.; Mode
SPRAA56 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application 25 5.3.2 Expected Values Delivered to the Message Log CPU load, latency, time to process 30 frames, and bitrate are all sent to the Message Log rather than the Statistics View window. Table 2 shows the expected an...
Page 26 - Capture and Display Task Benchmarking; References; Reference Frameworks for eXpressDSP Software: API Reference
SPRAA56 26 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application The value of N, which is used by modes 2 and 3, is 30 frames by default. As a result, RTA data is logged every 1 second in NTSC applications. This value can be changed using the GEL → rtaWindow slider. This sli...
Page 27 - Appendix A. Performance Impact; A.1 Overhead of Performance Measurement Techniques; Measured Performance of Benchmarking Techniques; A.2 RTA Effects on CPU Load
SPRAA56 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application 27 Appendix A. Performance Impact A.1 Overhead of Performance Measurement Techniques Because most of the benchmarking APIs are called once every 30 frames, the additional CPU load expected after adding the instrum...
Page 28 - A.3 Memory Footprint; Requirements; Memory Footprint Details
SPRAA56 28 DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application A.3 Memory Footprint The total additional code size added to the application for the debugging features was 29 KB of external memory. This was calculated from the size of the .out file with benchmarking added (...