pencil and rubber

Logo of Triple-A Level WCAG-1 Conformance, W3C-WAI Web Content Accessibility Guidelines 1.0

XHTML 1.0 Conformance Validation CSS 3 Conformance Validation
Logo of Department of Mathematics and Computer Science, Course on Dedicated systems, link to Forum

Program analysis tools and examples of their use

Tutorial 08 on Dedicated systems

Teacher: Giuseppe Scollo

University of Catania
Department of Mathematics and Computer Science
Graduate Course in Computer Science, 2016-17

Table of Contents

  1. Program analysis tools and examples of their use
  2. tutorial outline
  3. GNU cross-compilers and binutils
  4. example for NIOS II processor
  5. example for SimIt-ARM simulator
  6. example for ARM Cortex-A9 processor
  7. execution with debugger for NIOS II processor on FPGA
  8. lab experience
  9. references

tutorial outline

this tutorial deals with:

GNU cross-compilers and binutils

program development for dedicated systems often takes place on machines that are based on a different processor than the target one, viz. that which is meant for their execution

the cross-compilers and utilities here considered are GNU free software, that typically have names <target>–gcc for the compiler, where <target> indicates the target architecture, and <target>–<util> for the utility <util>, such as for example

example for NIOS II processor

the use of the nios2-elf-gcc cross-compiler and of a couple of binary utilities, exposed in sect. 7.4 of (Schaumont 2012) for the example in Listing 7.7, can be reproduced by running the scripts provided in the nios2binutils_example.tgz archive, available in the crosstools folder of the reserved lab area

for each version, two scripts are available:

example for SimIt-ARM simulator

the example showcases the use of the simulator SimIt-ARM v. 2.1 both for the analysis of the executable and for the command-line simulation of a program for GCD computation with Euclid's algorithm (Listing 7.11 in (Schaumont, 2012))

compilation goes through the cross-compiler arm-linux-gcc, for ISA ARMv5, implemented in the StrongARM processor among others

archive arm_simitarm_example.tgz, available in folder crosstools of the reserved lab area, provides two scripts for this tutorial:

example for ARM Cortex-A9 processor

the example deals with the execution, on an ARM Cortex-A9 in the Altera DE1-SoC system, of a variation of the program in Listing 7.1, where the main() function body is replaced by

loading and execution take place by means of the program altera-monitor-program, under control of its included GDB debugger and through the JTAG connection between the program and the DE1-SoC

the archive arm_cortex-a9_example.tgz, available in the crosstools folder of the reserved lab area contains the following scripts:

execution with debugger for NIOS II processor on FPGA

the same C source from the previous example may be compiled and executed by a NIOS II softcore on the FPGA of the DE1-SoC system, in this example with no other script, just to explore the use of the debugger included in the monitor program

caption text

a snapshot of execution on an Altera DE1-SoC board, controlled by the Altera Monitor Program debugger

lab experience

run the scripts provided with this tutorial, examine the files produced by their execution, find a few not well-known aspects of their contents, search the web for information about them and produce some tutorial documentation in form of a list of questions and answers

here are three examples of question and answer, one for each of the three types described above:

references

recommended readings:

readings for further consultation:

useful materials for the proposed lab experience: