mirror of
https://github.com/Z3Prover/z3
synced 2025-05-02 13:27:01 +00:00
Added accessors to extract sign/exponent/significand BV numerals from FP numerals.
This commit is contained in:
parent
5716eaafed
commit
6b474adc8a
7 changed files with 246 additions and 5 deletions
|
@ -1324,6 +1324,9 @@ struct
|
|||
let mk_to_real = Z3native.mk_fpa_to_real
|
||||
let get_ebits = Z3native.fpa_get_ebits
|
||||
let get_sbits = Z3native.fpa_get_sbits
|
||||
let get_numeral_sign_bv = Z3native.fpa_get_numeral_sign_bv
|
||||
let get_numeral_exponent_bv = Z3native.fpa_get_numeral_exponent_bv
|
||||
let get_numeral_significand_bv = Z3native.fpa_get_numeral_significand_bv
|
||||
let get_numeral_sign = Z3native.fpa_get_numeral_sign
|
||||
let get_numeral_significand_string = Z3native.fpa_get_numeral_significand_string
|
||||
let get_numeral_significand_uint = Z3native.fpa_get_numeral_significand_uint64
|
||||
|
|
|
@ -2138,6 +2138,18 @@ sig
|
|||
(** Retrieves the number of bits reserved for the significand in a FloatingPoint sort. *)
|
||||
val get_sbits : context -> Sort.sort -> int
|
||||
|
||||
(** Return the sign of a floating-point numeral as a bit-vector expression.
|
||||
Remark: NaN's do not have a bit-vector sign, so they are invalid arguments. *)
|
||||
val get_numeral_sign_bv : context -> Expr.expr -> Expr.expr
|
||||
|
||||
(** Return the exponent of a floating-point numeral as a bit-vector expression.
|
||||
Remark: +oo, -oo and NaN's do not have a bit-vector exponent, so they are invalid arguments. *)
|
||||
val get_numeral_exponent_bv : context -> Expr.expr -> Expr.expr
|
||||
|
||||
(** Return the significand value of a floating-point numeral as a bit-vector expression.
|
||||
Remark: +oo, -oo and NaN's do not have a bit-vector significand, so they are invalid arguments. *)
|
||||
val get_numeral_significand_bv : context -> Expr.expr -> Expr.expr
|
||||
|
||||
(** Retrieves the sign of a floating-point literal. *)
|
||||
val get_numeral_sign : context -> Expr.expr -> bool * int
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue