Implement floating-point Fast Fourier Transform#210
Implement floating-point Fast Fourier Transform#210ethanuppal wants to merge 20 commits intointel:mainfrom
Conversation
Signed-off-by: Ethan Uppal <113849268+ethanuppal@users.noreply.github.com>
Signed-off-by: Ethan Uppal <113849268+ethanuppal@users.noreply.github.com>
| name: name, | ||
| ); | ||
|
|
||
| ComplexFloatingPoint adder(ComplexFloatingPoint other) => |
There was a problem hiding this comment.
why not override operator + and *?
There was a problem hiding this comment.
I don't want to hide the fact that it's expensive
There was a problem hiding this comment.
the names of the functions seem unintuitive to me, maybe plus and times or addedTo and multipliedBy or something?
if we wanted to stay more consistent with other parts of the library, these could be their own components (classes, modules) e.g. ComplexFloatingPointMultiplier, perhaps with an argument that allows you to choose your own FloatingPointMultiplier implementation for the internals.
Signed-off-by: Ethan Uppal <113849268+ethanuppal@users.noreply.github.com>
| required this.inB, | ||
| required this.twiddleFactor, | ||
| super.name = 'butterfly'}) { | ||
| addInput('inA', inA, width: inA.width); |
There was a problem hiding this comment.
heads up, you'll want to use the signal returned by addInput or input for internal computation rather than the one provided in the constructor
Signed-off-by: Ethan Uppal <113849268+ethanuppal@users.noreply.github.com>
| name: name, | ||
| ); | ||
|
|
||
| ComplexFloatingPoint adder(ComplexFloatingPoint other) => |
There was a problem hiding this comment.
the names of the functions seem unintuitive to me, maybe plus and times or addedTo and multipliedBy or something?
if we wanted to stay more consistent with other parts of the library, these could be their own components (classes, modules) e.g. ComplexFloatingPointMultiplier, perhaps with an argument that allows you to choose your own FloatingPointMultiplier implementation for the internals.
| import 'package:rohd_hcl/src/arithmetic/floating_point/fft/butterfly.dart'; | ||
| import 'package:rohd_hcl/src/arithmetic/signals/floating_point_logics/complex_floating_point_logic.dart'; | ||
|
|
||
| class BadFFTStage extends Module { |
There was a problem hiding this comment.
maybe "multi-cycle" is a better name or something (if that's what it is)?
| required this.twiddleFactorROM, | ||
| super.name = 'badfftstage'}) | ||
| : assert(ready.width == 1) { | ||
| addInput('clk', clk); |
There was a problem hiding this comment.
reminder: you'll want to do something like clk = addInput('clk', clk); instead of just taking this.clk as the argument, since the signals received as arguments to the constructor are not the input ports of this module.
Signed-off-by: Ethan Uppal <113849268+ethanuppal@users.noreply.github.com>
Signed-off-by: Ethan Uppal <113849268+ethanuppal@users.noreply.github.com>
Signed-off-by: Ethan Uppal <113849268+ethanuppal@users.noreply.github.com>
Signed-off-by: Ethan Uppal <113849268+ethanuppal@users.noreply.github.com>
Signed-off-by: Ethan Uppal <113849268+ethanuppal@users.noreply.github.com>
| @@ -0,0 +1,35 @@ | |||
| // Copyright (C) 2025 Intel Corporation | |||
| // SPDX-License-Identifier: BSD-3-Clause | |||
There was a problem hiding this comment.
please update headers on the files to match the recommended style, including the name of the file, date authored, purpose of the file, etc.
There was a problem hiding this comment.
probably worth naming this something better than bad?
|
|
||
| late final Logic done; | ||
|
|
||
| BadFFTStage({ |
There was a problem hiding this comment.
please do write doc comments
There was a problem hiding this comment.
remember to export components that are intended to be part of the public API for ROHD-HCL
There was a problem hiding this comment.
Please add user guide descriptions on how to use new components in the doc/ directory (including links to the pages)
| return complex; | ||
| } | ||
|
|
||
| class Complex { |
There was a problem hiding this comment.
this class is defined in multiple files?
There was a problem hiding this comment.
Is there a place for shared utilities in tests?
There was a problem hiding this comment.
you can create a directory in either lib (not exported) or in the test directory and can reference other files that way
Signed-off-by: Ethan Uppal <113849268+ethanuppal@users.noreply.github.com>
Signed-off-by: Ethan Uppal <113849268+ethanuppal@users.noreply.github.com>
Description & Motivation
TODO
Related Issue(s)
Testing
Backwards-compatibility
Documentation