| Filter Design HDL Coder™ | ![]() |
Specify error margin for HDL language-based test benches
n
Some HDL optimizations can generate test bench code that produces numeric results that differ from those produced by the original filter function. By specifying an error margin, you can specify an acceptable minimum number of bits by which the numeric results can differ before the coder issues a warning.
Specify the error margin as an integer number of bits.
Optimizations that can generate test bench code that produces numeric results that differ from those produced by the original filter function include
CastBeforeSum (qfilts only)
OptimizeForHDL
CoeffMultipliers
FIRAdderStyle ('Tree')
AddPipelineRegisters (for FIR, Asymmetric FIR, and Symmetric FIR filters)
The error margin is the number of least significant bits a Verilog or VHDL language-based test bench can ignore when comparing the numeric results before generating a warning.
For fixed-point filters, the Error margin (bits) value is initialized to a default value of 4.
For double precision floating-point filters, the Error margin (bits) value is fixed at 1e-9. This value is displayed with the field disabled to indicate that the value cannot be changed.
AddPipelineRegisters, CastBeforeSum, CoeffMultipliers, FIRAdderStyle, OptimizeForHDL
![]() | EntityConflictPostfix | FIRAdderStyle | ![]() |
| © 1984-2008- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |