FPGA, CPLD, and ASIC solutions from Altera
  • Download Center
  • Literature
Sign in/register
myAltera Account
Welcome
  •   myAltera
  •   Logout
  • Products
    • Devices
    • Design Software
    • Intellectual Property
    • Development Kits/Cables
    • Design & Support Services
    • Literature
  • End Markets
    • Automotive
    • Broadcast
    • Computer & Storage
    • Consumer
    • Industrial
    • Medical
    • Military
    • Test & Measurement
    • Wireless
    • Wireline
  • Technology
    • DSP
    • External Memory
    • Embedded Processing
    • Transceivers
    • Parallel I/O
    • Signal Integrity
    • System Integration
  • Training
    • Training Courses
    • University Program
    • Webcasts & Videos
    • Demonstrations
    • Events Calendar
  • Support
    • Design & Support Resources
    • Knowledge Database
    • Devices
    • Design Software
    • Intellectual Property
    • Development Kits/Cables
    • Design Examples
    • Downloads
    • User Communities/Forums
    • mySupport
  • About Altera
    • About Us
    • Environmental
    • Customer Successes
    • Partners
    • Newsroom
    • Investor Relations
    • Jobs
    • Contact Us
  • Buy Online
    • Devices
    • Design Software
    • Development & Education Kits
    • Cables & Programming Hardware
    • Intellectual Property
  • Entire Site
  • Part Number
  • Knowledge Database
  • Support & Technical Docs
  • Forums & Wiki
Username:  
Password:  
 
Forgot my username or password
Don't have myAltera account? Register Now.
Enter your email address:

C2H Compiler Mandelbrot Design Example

Home > Support > Design Examples > Nios II > C2H Compiler Mandelbrot Design Example

Related Links

  • Nios II C2H Compiler User Guide (PDF)
  • Optimizing Nios II C2H Compiler Results (PDF)
  • Accelerating Nios II Systems with the C2H Compiler Tutorial (PDF)

This Mandelbrot design example demonstrates the use of the Nios® II embedded processor C-to-Hardware (C2H) acceleration compiler. In this example, the C2H compiler transforms the C-based implementation of the Mandelbrot algorithm into hardware. This design also contains a video controller to display full-motion video of the calculated pixel values.

The Mandelbrot pattern has become one of the most well known fractals because of its complex patterns and processor-intensive implementation. The algorithm operates in the complex plane where the x-axis represents the real component, and the y-axis represents the imaginary component. The example performs movements to different regions of the plane and also zooms in and out, creating full-motion video.

This example makes full use of parallelism by performing coordinate calculations in software while the hardware accelerators are in use. This is done by triple buffering the video data in DDR SDRAM and using the Nios II embedded processor to coordinate the data flow. Every time a full frame buffer is rendered by the hardware accelerator, the data is then managed by the processor to overlay benchmark data and notify the video controller that a new buffer is ready for display.

Using This Design Example

This design targets the following development kits:

  • Nios II Embedded Evaluation Kit, Cyclone® III FPGA Edition
  • Nios II Embedded Development Kit, Cyclone III FPGA Edition

Download the Nios II C2H Mandelbrot Design Example (.zip file)

Download the Nios II C2H Mandelbrot Design Example README (.txt file)

The use of this design is governed by, and subject to, the terms and conditions of the Altera® Hardware Reference Design License Agreement.

The .zip files contain all the necessary software files to reproduce the example, as well as a readme.txt file. The readme.txt file contains instructions for rebuilding the design targeting an existing hardware design.

Block Diagram

Figure 1 shows the block diagram of the C2H Compiler Mandelbrot design example.

Figure 1. C2H Compiler Mandelbrot Design Example

Figure1. C2H Compiler Mandelbrot Design Example
View Full Size

C2H Compiler Accelerated Results

The C2H compiler-accelerated Mandelbrot algorithm results in a speed improvement of at least 60x compared to the same algorithm running on the fastest Nios II processor using compiler optimization level 2 (-O2). This speed increase is because of the parallelism and fast iteration speeds that hardware can provide, which are not possible from a general-purpose processing unit.

Design Examples Disclaimer

These design examples may only be used within Altera devices and remain the property of Altera Corporation. They are being provided on an “as-is” basis and as an accommodation; therefore, all warranties, representations, or guarantees of any kind (whether express, implied, or statutory) including, without limitation, warranties of merchantability, non-infringement, or fitness for a particular purpose, are specifically disclaimed. Altera expressly does not recommend, suggest, or require that these examples be used in combination with any other product not provided by Altera.

Rate This Page


  • Products
    • MAX/MAX II
    • Stratix/Stratix GX
    • Nios II
  • Functionality
    • Arithmetic
    • External Memory Interfaces
    • On-Chip Memory
    • Bus & I/O Functions
    • Logic
    • Interfaces & Peripherals
    • DSP
    • Communications
    • PLL & Clocking
  • Design Entry
    • Quartus II
    • Tcl
    • VHDL
    • Verilog HDL
    • C Code
    • DSP Builder
    • TimeQuest
    • On-Chip Debugging
      • SignalTap II
  • Simulation Tools
    • Mentor Graphics ModelSim
    • Cadence NCsim
    • Synopsys VCS
  • Legacy Examples
    • Graphic Editor
    • AHDL
    Please give us feedback
    Products | End Markets | Technology | Training | Support | About Altera | Buy Online
    Jobs | Investor Relations | Contact Us | Site Map | Privacy | Legal Notice
    Copyright © 1995-2010 Altera Corporation. All Rights Reserved.
    Altera Forum
    Altera
    Forum
    Twitter
    Twitter
    RSS
    RSS
    Facebook
    Facebook
    Flickr
    Flickr
    YouTube
    YouTube
    Email Updates
    Email
    Updates