An AST representing a set of operations culminating in an IEEE754 floating point number. Do not instantiate this class directly, instead use FPV or FPS to construct a value or symbol, and then use operations to construct more complicated expressions. :ivar length: The length of this value :ivar sort: The sort of this value, usually either FSORT_FLOAT or FSORT_DOUBLE
Method | raw |
Interpret the bit-pattern of this IEEE754 floating point number as a bitvector. The inverse of this function is to_bv. |
Method | raw |
A counterpart to BV.raw_to_fp - does nothing and returns itself. |
Method | to |
Undocumented |
Method | to |
Convert this float to a different sort |
Method | val |
Convert this floating point value to an integer. |
Class Variable | __slots__ |
Undocumented |
Property | sort |
Undocumented |
Static Method | _from |
Undocumented |
Inherited from Bits
:
Method | make |
Undocumented |
Method | size |
:returns: The bit length of this AST |
Static Method | _check |
Undocumented |
Method | _type |
Undocumented |
Inherited from Base
(via Bits
):
Class Method | __init |
Undocumented |
Method | __a |
Initializes an AST. Takes the same arguments as ``Base.__new__()`` |
Method | __bool__ |
This prevents people from accidentally using an AST as a condition. For example, the following was previously common:: |
Method | __getattr__ |
Undocumented |
Method | __hash__ |
Undocumented |
Method | __init__ |
Undocumented |
Method | __iter__ |
This prevents people from iterating over ASTs. |
Method | __new__ |
This is called when you create a new Base object, whether directly or through an operation. It finalizes the arguments (see the _finalize function, above) and then computes a hash. If an AST of this hash already exists, it returns that AST... |
Method | __reduce__ |
Undocumented |
Method | __repr__ |
Undocumented |
Method | annotate |
Appends annotations to this AST. |
Method | append |
Appends an annotation to this AST. |
Method | append |
Appends several annotations to this AST. |
Method | canonicalize |
Undocumented |
Method | children |
Return an iterator over the nested children ASTs. |
Method | dbg |
Undocumented |
Method | dbg |
Returns a debug representation of this AST. |
Method | insert |
Inserts an annotation to this AST. |
Method | insert |
Inserts several annotations to this AST. |
Method | leaf |
Return an iterator over the leaf ASTs. |
Method | remove |
Removes an annotation from this AST. |
Method | remove |
Removes several annotations from this AST. |
Method | replace |
Returns this AST but with the AST 'old' replaced with AST 'new' in its subexpressions. |
Method | replace |
Replaces annotations on this AST. |
Method | replace |
Returns this AST with subexpressions replaced by those that can be found in `replacements` dict. |
Method | shallow |
Returns a string representation of this AST, but with a maximum depth to prevent floods of text being printed. |
Method | split |
Splits the AST if its operation is `split_on` (i.e., return all the arguments). Otherwise, return a list with just the AST. |
Method | structurally |
Structurally compares two A objects, and check if their corresponding leaves are definitely the same A object (name-wise or hash-identity wise). |
Method | swap |
This returns the same AST, with the arguments swapped out for new_args. |
Method | to |
Returns itself. Provides compatibility with other classes (such as SimActionObject) which provide a similar method to unwrap to an AST. |
Constant | FULL |
Undocumented |
Constant | FULL |
Undocumented |
Constant | LITE |
Undocumented |
Constant | LITE |
Undocumented |
Constant | MID |
Undocumented |
Constant | UNSIMPLIFIED |
Undocumented |
Instance Variable | annotations |
Undocumented |
Instance Variable | args |
Undocumented |
Instance Variable | depth |
Undocumented |
Instance Variable | length |
Undocumented |
Instance Variable | op |
Undocumented |
Instance Variable | symbolic |
Undocumented |
Instance Variable | variables |
Undocumented |
Property | cache |
A key that refers to this AST - this value is appropriate for usage as a key in dictionaries. |
Property | cardinality |
Undocumented |
Property | concrete |
Undocumented |
Property | ite |
Returns an equivalent AST that "burrows" the ITE expressions as deep as possible into the ast, for simpler printing. |
Property | ite |
Returns an equivalent AST that "excavates" the ITE expressions out as far as possible toward the root of the AST, for processing in static analyses. |
Property | multivalued |
Undocumented |
Property | recursive |
DEPRECATED: Use children_asts() instead. |
Property | recursive |
DEPRECATED: Use leaf_asts() instead. |
Property | singlevalued |
Undocumented |
Property | uc |
The depth of allocation by lazy-initialization. It's only used in under-constrained symbolic execution mode. |
Property | uninitialized |
Whether this AST comes from an uninitialized dereference or not. It's only used in under-constrained symbolic execution mode. |
Static Method | _arg |
Undocumented |
Static Method | _ast |
Serialize the AST and get a bytestring for hashing. |
Static Method | _calc |
Calculates the hash of an AST, given the operation, args, and kwargs. |
Static Method | _op |
Undocumented |
Method | _apply |
Undocumented |
Method | _burrow |
Undocumented |
Method | _excavate |
Undocumented |
Method | _first |
Undocumented |
Method | _identify |
Undocumented |
Method | _rename |
Undocumented |
Class Variable | _hash |
Undocumented |
Class Variable | _leaf |
Undocumented |
Instance Variable | _burrowed |
Undocumented |
Instance Variable | _cache |
Undocumented |
Instance Variable | _cached |
Undocumented |
Instance Variable | _eager |
Undocumented |
Instance Variable | _errored |
Undocumented |
Instance Variable | _excavated |
Undocumented |
Instance Variable | _hash |
Undocumented |
Instance Variable | _relocatable |
Undocumented |
Instance Variable | _simplified |
Undocumented |
Instance Variable | _uc |
Undocumented |
Instance Variable | _uneliminatable |
Undocumented |
Instance Variable | _uninitialized |
Undocumented |
Property | _encoded |
Undocumented |
claripy.ast.bits.Bits.raw_to_bv
Interpret the bit-pattern of this IEEE754 floating point number as a bitvector. The inverse of this function is to_bv. :return: A BV AST whose bit-pattern is the same as this FP
claripy.ast.bits.Bits.raw_to_fp
A counterpart to BV.raw_to_fp - does nothing and returns itself.
Convert this float to a different sort :param sort: The sort to convert to :param rm: Optional: The rounding mode to use :return: An FP AST