MyCORES

MyCORESMyCORESMyCORES

MyCORES

MyCORESMyCORESMyCORES
  • Home
  • Downloads
  • Tests & Experiments
  • Objectives
  • Більше
    • Home
    • Downloads
    • Tests & Experiments
    • Objectives
  • Home
  • Downloads
  • Tests & Experiments
  • Objectives

Graphic extension experiment

The graphics extension project is another simple example of using the X32Carrier core architecture. For this simple experiment, I chose a Stratix IV based board with HDMI output, 512MBytes DDR3 SDRAM, 4MBytes QDR SSRAM and EP4SGX530KH40C2 FPGA.

Functions that the X32Carrier kernel graphics extension should solve:

  1. Generation of a video with a resolution of 1024*768 at the HDMI output using a frame buffer based on QDR SSRAM
  2. Filling the frame buffer with data from window objects belonging to different processes, compiling the resulting frame depending on the order in which the windows are displayed - hardware support for the window function.
  3. Hardware acceleration for drawing lines, rectangles, triangles and ellipses in windowed objects.

The figure on the right shows the chosen concept for the video-graphics extension of the base kernel. The graphics accelerator draws basic shapes such as lines, rectangles, triangles and ellipses in window objects.

Frame assembler assembles a frame by selecting data from a screen object containing a background image and, using a table for placing objects on the screen, determines from which object the pixel value should be selected for each specific point on the screen. Using a system of comparators and priority channel selection, it is determined which object is visible at the point with the same coordinates.

The generated frame is placed in a frame buffer from which the data is read and transmitted via HDMI to the screen module.

Experiment results

To calculate the average time for drawing lines, rectangles, triangles and ellipses, the cycle time for drawing 1000 shapes was measured for each type separately. In this case, the coordinates of line points, vertices of triangles, rectangles and the coordinates/sizes of ellipses were selected using a pseudo-random number generator. During the cycle of drawing 1000 figures, process switching was stopped in order to eliminate possible downtime of the graphics accelerator due to switching to some other process.

All figures were drawn in windows sized 512*256


Average line drawing speed: 1900 clocks per line or 78947 lines/sec. @150MHz.

Average speed for drawing rectangles: 29889 clocks per rectangle or 5018 rectangles/sec. @150MHz.

Average speed for drawing triangles: 21646 clocks per triangle or 6929 triangles/sec. @150MHz.

Average speed for drawing ellipses:

  • without rotating the ellipse axis by an arbitrary angle: 162453 clocks per ellipse or 923 ellipses/sec. @150MHz.
  • with rotation of the ellipse axis by an arbitrary angle: 393362 clocks per ellipse or 381 ellipse/sec. @150MHz.


The results are extremely modest for the following reasons.

  1. This is the simplest accelerator that does not contain mechanisms for parallel calculation of the coordinates of several points at the same time.
  2. And most importantly, all data transactions pass through one bottleneck in the form of an access channel to the main memory with a width of 64 bits and a bus frequency of 150 MHz. 1144.4 MBytes/sec.  All transactions from the base core, from the Frame assembler, from the graphics accelerator and from internal processor blocks, such as the messenger and the context controller, flow here.
  3. The graphics extension has a maximum access speed limit for main memory of 572.2MBytes/sec.@150MHz. The accelerator, as a resource that expands the capabilities of the base core, is allocated half of the total memory channel bandwidth. This is done to prevent a core extension from completely blocking the base core's access to main memory.

Graphic extension description

Завантажити PDF

Downloads

You can use Configurable assembler and Prohect manager /from Downloads page/ for to modify and recompile GA microcode and sample projects.

X32CsVideo Quartus project archive. (zip)Завантажити
Graphic accelerator Microcode (zip)Завантажити
Video sample processes (zip)Завантажити

MyCORES

© 2019 MyCORES

mail to: sda@mycores.biz