02/08/2020 » Maximizing Application Performance on ARC DSP Processors with the MATLAB/Simulink Plugin

Introduction

Performance requirements for the Internet of Things (IoT) and connected vehicles have made digital signal processing (DSP) technology increasingly necessary in mathematically intensive embedded applications like sensor fusion, voice detection, speech recognition, and audio processing. To meet these requirements, Synopsys offers a range of DesignWare® ARC® Processor IP optimized for DSP-intensive applications【user】.

Facilitating rapid software development for these processors, the DesignWare ARC MetaWare Development Toolkit offers full C/C++ programming support for ARC processors’ DSP instructions and XY memory. The Toolkit includes a rich library of DSP functions highly optimized for ARC processors, which C/C++ developers can easily incorporate into embedded applications【user】.

MathWorks MATLAB® is a programming platform designed for engineers and scientists. Simulink® is an add-on to MATLAB for modeling, simulation, and analysis of dynamic systems. By combining MATLAB and Simulink, users can integrate textual and graphical programming in a simulation environment【user】.

This article describes the MetaWare MATLAB/Simulink plugin, which gives DesignWare ARC processor users the power to create highly optimized applications using the MATLAB/Simulink platform【user】.

MATLAB and Simulink

MATLAB is a mathematical programming platform with a proprietary language and a rich library allowing the development of algorithms, data analysis, and applications. Simulink provides a GUI for building models as block diagrams, with libraries of predefined blocks. Together, MATLAB and Simulink enable simulation and deployment to embedded systems via MathWorks Embedded Coder【user】.

ARC MetaWare Development Toolkit

The MetaWare Development Toolkit is a complete C/C++ toolchain for all DesignWare ARC processors. The MATLAB/Simulink plugin integrates MetaWare into MATLAB and Simulink, compiling “Embedded Coder” generated C code using the MetaWare Compiler for ARC targets and simulators such as ARC nSIM【user】.

Code Replacement

The plugin uses MATLAB’s code replacement feature to substitute ANSI/ISO C functions with highly optimized functions from the ARC MetaWare DSP libraries. A mapping table ensures optimal use for functions such as:

    • Vector Functions

    • Complex Math

    • Scalar Functions

    • Real and Complex Matrix Functions

    • Simulink DSP Blocks (FIR, Convolution, Correlation, Biquad, LMS Filter, FFT/IFFT, etc.)

For example, a plain ANSI matrix multiply is automatically replaced with the optimized ARC DSP library version【user】.

Processor-in-the-Loop (PIL)

PIL allows blocks in a Simulink model to run on hardware targets (e.g., ARC EM Starter Kit, AXS103) while comparing outputs with the simulation block. The plugin supports PIL via an Ashling Opella-XD JTAG probe, with communication over USB UART or TCP/IP. This ensures numerical equivalence between design and deployment【user】.

Benchmarking

The plugin supports native code execution profiling in Simulink. Results show significant improvements when using the MetaWare DSP library, e.g.:

    • 5×5 matrix multiply (32-bit float) → 2.5× faster

    • Discrete FIR filter (q15 fixed-point, 64×1 vector) → 6.6× faster

Conclusion

The MATLAB/Simulink plugin for the Synopsys DesignWare ARC MetaWare Development Toolkit empowers ARC processor users to generate highly optimized C code. By leveraging MATLAB’s Embedded Coder and ARC DSP libraries, developers can achieve significant performance gains in embedded applications【user】.

For details visit: Synopsys ARC DSP | Ashling Opella-XD | embARC Open Software Platform

All trademarks, logos, and brand names are the property of their respective owners.