Giter Site home page Giter Site logo

zslwyuan / high-performance-karatsuba-multiplier-hls-fpga Goto Github PK

View Code? Open in Web Editor NEW
9.0 3.0 1.0 26.13 MB

Implement High-Performance Karatsuba Multiplier in High-Level Synthesis (HLS) for FPGA Based on Recursive Template

License: GNU General Public License v3.0

C++ 38.66% Ada 42.50% Tcl 3.37% Shell 0.02% Makefile 0.41% C 0.08% Verilog 0.98% Coq 6.59% VHDL 7.39% Ruby 0.01% HTML 0.01%
karatsuba karatsuba-multiplication karatsuba-algorithm fpga high-level-synthesis hls

high-performance-karatsuba-multiplier-hls-fpga's Introduction

High-Performance-Karatsuba-Multiplier-HLS-FPGA

Based on Vivado HLS 2019.2, implement High-Performance Karatsuba Multiplier in High-Level Synthesis (HLS) for FPGA Based on Recursive Template. The design provides parameters which can help user to customize the multiplier according to different requirements of operand bitwidth, performance and resource cost.

The utilization of this open source project should follow the GPL-3.0 License.

(^_^) if this project helps you, a STAR will be encouragement.

When handling 4096x4096=>8192, the performance and resource cost are shown below (left is for non-dataflow design, 133333x(4096x4096=>8192 multiplication) per second ; right is for dataflow design, throughput increased by 27.0%, 166666x(4096x4096=>8192 multiplication) per second ):

HLS Implementation

non-dataflow design located in the directory "HLS_Implementation"

dataflow design located in the directory "HLS_Implementation_dataflow"

Use template in C++ to generate recursive multiplication tree during compilation which can make full use of parallelism of Karatsuba multiplier

each loop are pipelined.

One of the versions provides dataflow processing to increase throughput. However, although the design is validated by me on VivadoHLS 2019.2, dataflow implementation in VivadoHLS is not very reliable currently. If you use another version of VivadoHLS, please run C/RTL co-simulation before deploying the design in your project.

Detailed comments can be found in the source code.

the outline of the design is shown below:

Software Implementation

located in the directory "Software_Implementation"

the same as HLS version

but generate random input and use GMP library to verify the results

high-performance-karatsuba-multiplier-hls-fpga's People

Contributors

zslwyuan avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

shp776

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.