|
Universal Numbers Library C++ API
sw::universal -- header-only custom arithmetic types (posit, cfloat, lns, fixpnt, dd/qd, and more)
|
Type advisor for mixed-precision algorithm design. More...
#include <type_advisor.hpp>
Public Member Functions | |
| TypeAdvisor () | |
| const std::vector< TypeCharacteristics > & | knownTypes () const |
| Get all known type characteristics. | |
| template<typename NumberSystem> | |
| std::vector< TypeRecommendation > | recommend (const range_analyzer< NumberSystem > &analyzer, const AccuracyRequirement &accuracy=AccuracyRequirement()) const |
| Recommend types based on range analysis and accuracy requirements. | |
| template<typename NumberSystem> | |
| std::vector< TypeRecommendation > | recommend (const range_analyzer< NumberSystem > &analyzer, double relative_error) const |
| Recommend types with simple relative error requirement. | |
| template<typename NumberSystem> | |
| TypeRecommendation | bestType (const range_analyzer< NumberSystem > &analyzer, const AccuracyRequirement &accuracy=AccuracyRequirement()) const |
| Get the top recommendation. | |
| TypeRecommendation | recommendForNsb (int nsb, double lo, double hi) const |
| Recommend a type based on required number of significant bits and value range This is the bridge from POP analysis to type selection. | |
| template<typename NumberSystem> | |
| void | report (std::ostream &ostr, const range_analyzer< NumberSystem > &analyzer, const AccuracyRequirement &accuracy=AccuracyRequirement()) const |
| Print recommendations report. | |
Type advisor for mixed-precision algorithm design.
|
inline |
|
inline |
Get the top recommendation.
|
inline |
Get all known type characteristics.
|
inline |
Recommend types based on range analysis and accuracy requirements.
|
inline |
Recommend types with simple relative error requirement.
|
inline |
Recommend a type based on required number of significant bits and value range This is the bridge from POP analysis to type selection.
|
inline |
Print recommendations report.