Namespaces
Enumerations
enum Operation
| Name | Value |
|---|---|
| Value | 0 |
| Addition | 1 |
| Subtraction | 2 |
| Multiplication | 3 |
| Division | 4 |
| Negation | 5 |
| Resolution | 6 |
Enumeration representing the type or function of an Expression.
Defined at line 23 of file ../../zircon/system/ulib/ffl/include/ffl/expression.h
Records
-
class BestFittingType -
class BestFittingType -
class BestFittingType -
class BestFittingType -
class BestFittingType -
class BestFittingType -
class BestFittingType -
class BestFittingType -
class BestFittingType -
class Bit -
class ComparisonTraits -
class ComparisonTraits -
class ComparisonTraits -
class ComparisonTraits -
class ComparisonTraits -
class ComparisonTraits -
class ExponentialAverage -
class ExponentialAverage -
class Expression -
class Expression -
class Expression -
class Expression -
class Expression -
class Expression -
class Expression -
class Expression -
class ExpressionTraits -
class ExpressionTraits -
class ExpressionTraits -
class ExpressionTraits -
class Fixed -
class FixedFormat -
class Init -
class IntegerPrecisionType -
class IntegerPrecisionType -
class IntegerPrecisionType -
class IntegerPrecisionType -
class IntegerPrecisionType -
class IntegerPrecisionType -
class IntegerPrecisionType -
class IntegerPrecisionType -
class IntegerPrecisionType -
class PromoteFormat -
class PromoteFormat -
class PromoteFormat -
class PromoteFormat -
class PromoteFormat -
class PromoteFormat -
class Resolution -
class ResultAsType -
class String -
class Value -
class Value
Functions
-
template <typename V, size_t VFractionalBits, typename A, size_t AFractionalBits>ExponentialAverage<Fixed<V, VFractionalBits>, Fixed<A, AFractionalBits>, Fixed<A, AFractionalBits>> <deduction guide for ExponentialAverage> (Fixed<V, VFractionalBits> , Fixed<A, AFractionalBits> ) -
template <typename V, size_t VFractionalBits, typename A, size_t AFractionalBits, typename B, size_t BFractionalBits>ExponentialAverage<Fixed<V, VFractionalBits>, Fixed<A, AFractionalBits>, Fixed<B, BFractionalBits>> <deduction guide for ExponentialAverage> (Fixed<V, VFractionalBits> , Fixed<A, AFractionalBits> , Fixed<B, BFractionalBits> ) -
std::ostream & operator<< (std::ostream & out, String::Mode mode)A stream manipulator for setting the current mode.
Defaults to String::Dec.
Defined at line 15 of file ../../zircon/system/ulib/ffl/string.cc
-
template <typename T, typename U, typename Result = decltype(std::declval<T>() + std::declval<U>())>Result SaturateAdd (T a, U b, ResultAsType<Result> )Returns the saturated result of addition on the given integer values. By
default, the type of the result is deduced from the argument types using the
normal integer promotion rules. The default can be overridden by passing
ResultAs
<type
> as the final argument.
Defined at line 36 of file ../../zircon/system/ulib/ffl/include/ffl/saturating_arithmetic.h
-
template <typename Result, typename T, typename U>Result SaturateAddAs (T a, U b)Returns the saturated result of addition on the given integer values, using
the given integer result type.
Defined at line 49 of file ../../zircon/system/ulib/ffl/include/ffl/saturating_arithmetic.h
-
template <typename T, typename U, typename Result = decltype(std::declval<T>() - std::declval<U>())>Result SaturateSubtract (T a, U b, ResultAsType<Result> )Returns the saturated result of subtraction on the given integer values. By
default, the type of the result is deduced from the argument types using the
normal integer promotion rules. The default can be overridden by passing
ResultAs
<type
> as the final argument.
Defined at line 58 of file ../../zircon/system/ulib/ffl/include/ffl/saturating_arithmetic.h
-
template <typename Result, typename T, typename U>Result SaturateSubtractAs (T a, U b)Returns the saturated result of subtraction on the given integer values,
using the given integer result type.
Defined at line 72 of file ../../zircon/system/ulib/ffl/include/ffl/saturating_arithmetic.h
-
template <typename T, typename U, typename Result = decltype(std::declval<T>() * std::declval<U>())>Result SaturateMultiply (T a, U b, ResultAsType<Result> )Returns the saturated result of multiplication on the given integer values.
By default, the type of the result is deduced from the argument types using
the normal integer promotion rules. The default can be overridden by passing
ResultAs
<type
> as the final argument.
Defined at line 81 of file ../../zircon/system/ulib/ffl/include/ffl/saturating_arithmetic.h
-
template <typename Result, typename T, typename U>Result SaturateMultiplyAs (T a, U b)Returns the saturated result of multiplication on the given integer values,
using the given integer result type.
Defined at line 93 of file ../../zircon/system/ulib/ffl/include/ffl/saturating_arithmetic.h
-
template <typename Result, typename Integer, std::enable_if_t<std::is_integral_v<Result> && std::is_integral_v<Integer> && std::is_unsigned_v<Result> && std::is_signed_v<Integer>, int> = 0>Result ClampCast (Integer value)Clamps the given Integer value to the range of Result. Optimized for all
combinations of sizes and signedness.
Defined at line 134 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
-
template <typename Integer, size_t FractionalBits>String Format (Fixed<Integer, FractionalBits> value, String::Mode mode, size_t max_fractional_digits)Utility that returns a String for the given Fixed value. This function may
be looked up by ADL to reduce namespace clutter at call sites. The noinline
attribute avoids unnecessary expansion around logging/printing calls.
Defined at line 142 of file ../../zircon/system/ulib/ffl/include/ffl/string.h
-
template <typename Result, typename Integer, std::enable_if_t<std::is_integral_v<Result> && std::is_integral_v<Integer> && std::is_unsigned_v<Result> && std::is_unsigned_v<Integer>, int> = 1>Result ClampCast (Integer value)Defined at line 150 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
-
template <typename Result, typename Integer, std::enable_if_t<std::is_integral_v<Result> && std::is_integral_v<Integer> && std::is_signed_v<Result> && std::is_unsigned_v<Integer>, int> = 2>Result ClampCast (Integer value)Defined at line 163 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
-
template <typename Result, typename Integer, std::enable_if_t<std::is_integral_v<Result> && std::is_integral_v<Integer> && std::is_signed_v<Result> && std::is_signed_v<Integer>, int> = 3>Result ClampCast (Integer value)Defined at line 176 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
-
template <typename Integer, typename T, typename Enabled = EnableIfUnaryExpression<T>>auto Round (T expression)Utility to round an expression to the given Integer.
Defined at line 217 of file ../../zircon/system/ulib/ffl/include/ffl/fixed.h
-
template <typename Integer, typename Enabled = std::enable_if_t<std::is_integral_v<Integer>>>auto FromInteger (Integer value)Utility to create an Expression node from an integer value.
Defined at line 224 of file ../../zircon/system/ulib/ffl/include/ffl/fixed.h
-
template <typename Integer, typename Enabled = std::enable_if_t<std::is_integral_v<Integer>>>auto FromRatio (Integer numerator, Integer denominator)Utility to create an Expression node from an integer ratio. May be used to
initialize a Fixed variable from a ratio.
Defined at line 231 of file ../../zircon/system/ulib/ffl/include/ffl/fixed.h
-
template <size_t FractionalBits, typename T>auto ToResolution (T expression)Utility to coerce an expression to the given resolution.
Defined at line 237 of file ../../zircon/system/ulib/ffl/include/ffl/fixed.h
-
template <size_t FractionalBits, typename Integer>auto FromRaw (Integer value)Utility to create a value Expression from a raw integer value already in the
fixed-point format with the given number of fractional bits.
Defined at line 244 of file ../../zircon/system/ulib/ffl/include/ffl/fixed.h
-
template <typename Left, typename Right, typename Enabled = EnableIfComparisonExpression<Left, Right>>bool operator< (Left left, Right right)Relational operators.
Fixed-to-fixed comparisons convert to an intermediate type with suitable
precision and the least resolution of the two operands, using convergent
rounding to reduce resolution and avoid bias.
Fixed-to-integer comparisons convert to an intermediate type with suitable
precision and the resolution of the fixed-point type. This is less
less surprising when comparing a fixed-point type to zero and other integer
constants.
Defined at line 260 of file ../../zircon/system/ulib/ffl/include/ffl/fixed.h
-
template <typename Left, typename Right, typename Enabled = EnableIfComparisonExpression<Left, Right>>bool operator> (Left left, Right right)Defined at line 266 of file ../../zircon/system/ulib/ffl/include/ffl/fixed.h
-
template <typename Left, typename Right, typename Enabled = EnableIfComparisonExpression<Left, Right>>bool operator<= (Left left, Right right)Defined at line 272 of file ../../zircon/system/ulib/ffl/include/ffl/fixed.h
-
template <typename Left, typename Right, typename Enabled = EnableIfComparisonExpression<Left, Right>>bool operator>= (Left left, Right right)Defined at line 278 of file ../../zircon/system/ulib/ffl/include/ffl/fixed.h
-
template <typename Left, typename Right, typename Enabled = EnableIfComparisonExpression<Left, Right>>bool operator== (Left left, Right right)Defined at line 284 of file ../../zircon/system/ulib/ffl/include/ffl/fixed.h
-
template <typename Left, typename Right, typename Enabled = EnableIfComparisonExpression<Left, Right>>bool operator!= (Left left, Right right)Defined at line 290 of file ../../zircon/system/ulib/ffl/include/ffl/fixed.h
-
template <typename Left, typename Right, typename Enabled = EnableIfBinaryExpression<Left, Right>>auto operator+ (Left left, Right right)Arithmetic operators. These operators accept any combination of Fixed,
integer, and Expression (excluding integer/integer which is handled by the
language). The return type and value captures the operation and operands as
an Expression for later evaluation. Evaluation is performed when the
Expression tree is assigned to a Fixed variable. This can be composed in
multiple stages and assignments.
Example:
const int32_t value = ...;
cosnt int32_t offset = ...;
const auto quotient = FromRatio(value, 3);
const Fixed
<int32
_t, 1> low_precision = quotient;
const Fixed
<int64
_t, 10> high_precision = quotient;
const auto with_offset = quotient + ToResolution
<
10>(offset);
const Fixed
<int64
_t, 10> high_precision_with_offset = with_offset;
Defined at line 315 of file ../../zircon/system/ulib/ffl/include/ffl/fixed.h
-
template <typename T, typename Enabled = EnableIfUnaryExpression<T>>auto operator- (T value)Defined at line 319 of file ../../zircon/system/ulib/ffl/include/ffl/fixed.h
-
template <typename Left, typename Right, typename Enabled = EnableIfBinaryExpression<Left, Right>>auto operator- (Left left, Right right)Defined at line 323 of file ../../zircon/system/ulib/ffl/include/ffl/fixed.h
-
template <typename Left, typename Right, typename Enabled = EnableIfBinaryExpression<Left, Right>>auto operator* (Left left, Right right)Defined at line 327 of file ../../zircon/system/ulib/ffl/include/ffl/fixed.h
-
template <typename Left, typename Right, typename Enabled = EnableIfBinaryExpression<Left, Right>>auto operator/ (Left left, Right right)Defined at line 331 of file ../../zircon/system/ulib/ffl/include/ffl/fixed.h
-
template <typename Integersize_t FractionalBits>std::ostream & operator<< (std::ostream & outFixed<Integer, FractionalBits> value)Operator to write a Fixed value into an ostream.
Defined at line 356 of file ../../zircon/system/ulib/ffl/include/ffl/string.h
Variables
const ResultAsType<signed char> ResultAs
Defined at line 20 of file ../../zircon/system/ulib/ffl/include/ffl/saturating_arithmetic.h
const ResultAsType<unsigned int> ResultAs
Defined at line 20 of file ../../zircon/system/ulib/ffl/include/ffl/saturating_arithmetic.h
const ResultAsType<unsigned short> ResultAs
Defined at line 20 of file ../../zircon/system/ulib/ffl/include/ffl/saturating_arithmetic.h
const ResultAsType<unsigned char> ResultAs
Defined at line 20 of file ../../zircon/system/ulib/ffl/include/ffl/saturating_arithmetic.h
const ResultAsType<long> ResultAs
Defined at line 20 of file ../../zircon/system/ulib/ffl/include/ffl/saturating_arithmetic.h
const ResultAsType<unsigned long> ResultAs
Defined at line 20 of file ../../zircon/system/ulib/ffl/include/ffl/saturating_arithmetic.h
const ResultAsType<int> ResultAs
Defined at line 20 of file ../../zircon/system/ulib/ffl/include/ffl/saturating_arithmetic.h
const ResultAsType<short> ResultAs
Defined at line 20 of file ../../zircon/system/ulib/ffl/include/ffl/saturating_arithmetic.h
const auto ResultAs
Defined at line 21 of file ../../zircon/system/ulib/ffl/include/ffl/saturating_arithmetic.h
const Bit<20UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<40UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<4UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<5UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<6UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<7UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<8UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<14UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<15UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<16UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<29UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<30UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<32UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<61UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<62UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<12UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<28UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<60UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<11UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<27UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<59UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<9UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<10UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<25UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<26UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<57UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<58UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<24UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<56UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<23UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<55UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<22UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<54UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<21UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<53UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<17UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<18UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<19UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<48UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<49UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<47UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<46UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<45UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<33UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<63UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<50UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<34UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<13UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<2UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<1UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<0UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<31UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const Bit<3UL> ToPlace
Defined at line 28 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h
const auto ToPlace
Defined at line 29 of file ../../zircon/system/ulib/ffl/include/ffl/utility.h