Coder Social home page Coder Social logo

fftgen's Introduction

FFT Generator

Build Status Build Status

This repo contains code for an FFT generator and testbench. The generator can build an 8-point FFT, a 1024-point FFT, or any power-of-two in between. It also provides a choice of 1, 2, or 4 butterfly units. The generator is powered by Genesis2.

This FFT uses a conflict-free schedule, meaning that it runs to completion without ever having to pause for memory-conflict resolution. Not counting setup and takedown simulation time, the FFT will therefore complete its operation in minimal time. So, for instance, if local memory access takes one cycle to complete, and if you use the generator to build a 1024-point FFT with only a single butterfly unit, it will complete its operation in (n/2)log2(n) or 5120 cycles. An FFT built with two butterflies working in parallel will take just half that amount of time, and so on.

The conflict-free schedule works on a variety of memory configurations, including single-ported SRAM. The single-ported version of this FFT would thus be the least-area memory configuration for a resource-constrained FFT.

Also see

Building FFT's with fftgen: A Quick How-To

You will need csh and perl (sorry!). If you don't already have them, see internet for instructions on how to install. Oh, and you'll also need verilator if you're going to use this prepackaged test build. VCS is also supported maybe, see bin/golden_test.csh --help.

  # 1. Clone the repo
  git clone https://github.com/steveri/fftgen
  FFTGEN=$PWD/fftgen

  # 2. The `setup_genesis` script installs Genesis.pl
  #    if it's not already in your path
  source $FFTGEN/bin/setup_genesis.sh

  # 3. Build a scratch/build area inside the clone
  mkdir fftgen/build; cd fftgen/build

  # 4. Build and test a single FFT design against a golden model,
  #    e.g. to build a 32-point in-place FFT using two butterfly units
  #    and one bank of single-port DRAM:
  $FFTGEN/bin/golden_test.csh 32 2 1port -sim verilator

  # 5. (Optional) Exhaustive test of multiple models
  $FFTGEN/bin/golden_test.csh

  # 6. (optional) More information
  $FFTGEN/bin/golden_test.csh --help

Our CI scripts also provide a good guide on how to build and run fftgen using an extensive test suite. Scripts are here:

And you can see the results of previous runs here:

Using RTL examples

If you want to not fool with genesis and just use see/use straight SystemVerilog RTL, there are example configurations in the subdirectory examples-rtl, along with README.md instructions on how to build and use a Verilator testbench to verify its correctness.

CURRENT STATUS Jun 2021

  • all regression tests PASS (47/47) using homebrew fpu
  • I think it's all working with verilator now
  • see 0notes-fft.txt, README.txt for latest/best info

NOTES

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.