diff --git a/src/plugins/e-acsl/Makefile.in b/src/plugins/e-acsl/Makefile.in index 8ac367acffe5abaded67762e36864437b0b2da65..49070853bb018e3b2c269cdf1873a3a331ce6938 100644 --- a/src/plugins/e-acsl/Makefile.in +++ b/src/plugins/e-acsl/Makefile.in @@ -55,7 +55,6 @@ $(PLUGIN_DIR)/local_config.ml: $(PLUGIN_DIR)/Makefile.in $(PRINT_MAKING) $@ $(RM) $@ $(ECHO) "(* This file was automatically generated from $<. Don't edit it. *)" >> $@ - $(ECHO) "let may_compile_with_cc = @MAY_COMPILE_WITH_CC@" >> $@ $(ECHO) "let may_use_assert = @MAY_USE_ASSERT@" >> $@ $(CHMOD_RO) $@ diff --git a/src/plugins/e-acsl/TODO b/src/plugins/e-acsl/TODO index 7a4303f1380bad913e1b7af7862fd84f65402211..d52e1c85a3f34072a30b3769eacd7454a82971ea 100644 --- a/src/plugins/e-acsl/TODO +++ b/src/plugins/e-acsl/TODO @@ -18,8 +18,23 @@ - minimiser le nombre de variables générées - constante entière longue: utiliser la représentation sous forme de string et rechercher la base appropriée. -- introduire feature wishes Bernard (voir mail du 9 juin) - arithmetic overflows +[Bernard] avoir une fonction + e_acsl_assert(int guard, char *msg, char *kind) { + if (guard) e_acsl_fail(msg, kind); + } +à appeler au lieu de générer la garde. La kind est le type de l'annotation +(assert, requires, ensures, RTE? ...) +[Bernard] avoir une fonction + e_acsl_trace_behavior(char *bhv_name) {} +à appeler dès qu'un behavior est activé +- meilleur schéma de compilation des assumes: + if (assume_bhv) { + e_acsl_trace_behavior(bhv_name); + requires_bhv; + run_function; + ensures_bhv; + } ############## # KNOWN BUGS # @@ -32,7 +47,6 @@ ######### - fonction sans code -- ajouter -Wall -pedantic -c99 - exécuter rte - tester plusieurs fonctions contenant des annotations - améliorer test "integer_constant.i" quand bug fixed #745 diff --git a/src/plugins/e-acsl/configure.ac b/src/plugins/e-acsl/configure.ac index 17dbc0723eec755c9c8aa9ee79678729b7afb578..1395b3077103f6f43020ca54844135c8af99e61c 100644 --- a/src/plugins/e-acsl/configure.ac +++ b/src/plugins/e-acsl/configure.ac @@ -41,7 +41,6 @@ check_plugin(e_acsl,PLUGIN_RELATIVE_PATH(plugin_file), # C specific stuff for E-ACSL # ############################### -MAY_COMPILE_WITH_CC=true MAY_USE_ASSERT=true MAY_RUN_TESTS=yes @@ -58,9 +57,7 @@ if test -z $CC; then else if test -z $HAVE_STDIO_H; then - MAY_COMPILE_WITH_CC=false MAY_RUN_TESTS=no - AC_MSG_WARN([stdio.h missing: cannot use option -e-acsl-include-headers.]) AC_MSG_WARN([stdio.h missing: non-regression tests unavailable.]) fi @@ -73,7 +70,6 @@ if test -z $HAVE_ASSERT_H; then MAY_USE_ASSERT=false MAY_RUN_TESTS=no AC_MSG_WARN([assert.h missing: cannot use E-ACSL option -e-acsl-use-assert.]) - AC_MSG_WARN([assert.h missing: non-regression tests unavailable.]) fi # GMP library @@ -82,9 +78,7 @@ fi AC_CHECK_LIB(gmp,__gmpz_init,HAVE_GMP=yes,) # also set LIBS if test -z $HAVE_GMP; then - MAY_COMPILE_WITH_CC=false MAY_RUN_TESTS=no - AC_MSG_WARN([GMP library missing: cannot use E-ACSL option -e-acsl-include-headers.]) AC_MSG_WARN([GMP library missing: non-regression tests unavailable.]) fi diff --git a/src/plugins/e-acsl/local_config.mli b/src/plugins/e-acsl/local_config.mli index aacfa9bd0ba23539d1b34dcc2dd7fb2acc3f1823..1ba938b1ab55dde64f4112ac273cd5344545a062 100644 --- a/src/plugins/e-acsl/local_config.mli +++ b/src/plugins/e-acsl/local_config.mli @@ -19,7 +19,6 @@ (* *) (**************************************************************************) -val may_compile_with_cc: bool val may_use_assert: bool (* diff --git a/src/plugins/e-acsl/main.ml b/src/plugins/e-acsl/main.ml index 1e0c8ed4ad1e5ded4ec70c3b6704397b48e8610c..a83acf3b11a34ef4d8738c5bfa9da06d73e4d901 100644 --- a/src/plugins/e-acsl/main.ml +++ b/src/plugins/e-acsl/main.ml @@ -55,8 +55,7 @@ module Resulting_projects = let name = "E-ACSL resulting projects" let size = 7 let kind = `Correctness - let dependencies = - [ Ast.self; Options.Include_headers.self; Options.Use_assert.self ] + let dependencies = [ Ast.self; Options.Use_assert.self ] end) let () = Env.global_state := Resulting_projects.self @@ -66,20 +65,7 @@ let generate_code = (fun name -> try let visit prj = Visit.do_visit ~prj true in - let preprocess = - if Options.Include_headers.get () then - if Local_config.may_compile_with_cc then begin - if Local_config.may_use_assert then Options.Use_assert.on (); - true - end else begin - Options.warning "option `-e-acsl-include-headers' not available \ -(see configure warning) : ignoring it."; - false - end - else - false - in - File.create_rebuilt_project_from_visitor ~preprocess name visit + File.create_rebuilt_project_from_visitor ~preprocess:false name visit with Misc.Typing_error s -> Options.abort ~current:true "%s" s) diff --git a/src/plugins/e-acsl/mpz.ml b/src/plugins/e-acsl/mpz.ml index 6bb79500272d13fb95f644246c1c179cd1ba1e62..33b1e438d3256601edf0bb4c131698fdec6e210e 100644 --- a/src/plugins/e-acsl/mpz.ml +++ b/src/plugins/e-acsl/mpz.ml @@ -34,14 +34,14 @@ let is_now_referenced () = t_torig.treferenced <- true let t = TNamed(t_torig, []) let is_t ty = Cil_datatype.Typ.equal ty t -let apply_on_var funname e = Misc.mk_call ("mpz_" ^ funname) [ e ] +let apply_on_var funname e = Misc.mk_call ("__gmpz_" ^ funname) [ e ] let init = apply_on_var "init" let clear = apply_on_var "clear" let init_set v e = let ty = typeOf e in if is_t ty then - Misc.mk_call "mpz_init_set" [ v; e ] + Misc.mk_call "__gmpz_init_set" [ v; e ] else let fname, args = match ty with | TInt((IBool | IChar | IUChar | IUInt | IUShort | IULong), _) -> @@ -54,7 +54,7 @@ let init_set v e = [ e; integer ~loc:Location.unknown 10 ] | _ -> assert false in - Misc.mk_call ("mpz_init_set_" ^ fname) (v :: args) + Misc.mk_call ("__gmpz_init_set_" ^ fname) (v :: args) (* Local Variables: diff --git a/src/plugins/e-acsl/options.ml b/src/plugins/e-acsl/options.ml index 5deef961919c795c9f3e48d8dda59c90c43f4d7d..467473dec419a0d995da6f380ab9f05163b812a1 100644 --- a/src/plugins/e-acsl/options.ml +++ b/src/plugins/e-acsl/options.ml @@ -46,15 +46,6 @@ module Project_name = let arg_name = "prj" end) -module Include_headers = - False - (struct - let option_name = "-e-acsl-include-headers" - let help = "include standard headers in the new project \ -(unset by default)" - let kind = `Correctness - end) - module Use_assert = False (struct diff --git a/src/plugins/e-acsl/options.mli b/src/plugins/e-acsl/options.mli index c141632bb58b31ade5aa917e5370ce9954e6b26f..ef8540b777e124d6fd088f9ce97cf6b9de5b297e 100644 --- a/src/plugins/e-acsl/options.mli +++ b/src/plugins/e-acsl/options.mli @@ -26,7 +26,6 @@ include S (** implementation of Log.S for E-ACSL *) module Check: Bool module Project_name: String -module Include_headers: Bool module Use_assert: Bool (* diff --git a/src/plugins/e-acsl/read_header.ml b/src/plugins/e-acsl/read_header.ml index 2403767af599c4fe97e5410723ed396ae339728c..265666bf11f0ac1b6a1dd09bd23d4109888f7a20 100644 --- a/src/plugins/e-acsl/read_header.ml +++ b/src/plugins/e-acsl/read_header.ml @@ -46,12 +46,7 @@ let text = let buf = Buffer.create 97 in fun () -> if Buffer.length buf = 0 then begin - if Options.Include_headers.get () then begin - add_include buf "stdio.h"; - if Options.Use_assert.get () then add_include buf "assert.h"; - add_include buf "gmp.h"; - end else - put_file_in_buffer "e_acsl_gmp_types.h" buf; + put_file_in_buffer "e_acsl_gmp_types.h" buf; put_file_in_buffer "e_acsl_gmp.h" buf; put_file_in_buffer "e_acsl.h" buf end; diff --git a/src/plugins/e-acsl/share/e-acsl/e_acsl_gmp.h b/src/plugins/e-acsl/share/e-acsl/e_acsl_gmp.h index 5290f586777882139e9bcfacf5f120ff1c4126c7..ea2661d603caf9221d6228e114ecbb32b4ad6da4 100644 --- a/src/plugins/e-acsl/share/e-acsl/e_acsl_gmp.h +++ b/src/plugins/e-acsl/share/e-acsl/e_acsl_gmp.h @@ -7,83 +7,83 @@ /*@ ensures \valid(x); @ assigns *x; */ -extern void mpz_init(mpz_t x); +extern void __gmpz_init(mpz_t x); /*@ ensures \valid(z); @ assigns *z; */ -extern void mpz_init_set(mpz_t z, const mpz_t z_orig); +extern void __gmpz_init_set(mpz_t z, const mpz_t z_orig); /*@ ensures \valid(z); @ assigns *z \from n; */ -extern void mpz_init_set_ui(mpz_t z, unsigned long int n); +extern void __gmpz_init_set_ui(mpz_t z, unsigned long int n); /*@ ensures \valid(z); @ assigns *z \from n; */ -extern void mpz_init_set_si(mpz_t z, signed long int n); +extern void __gmpz_init_set_si(mpz_t z, signed long int n); /*@ ensures \valid(z); @ assigns *z; */ -extern int mpz_init_set_str(mpz_t z, const char *str, int base); +extern int __gmpz_init_set_str(mpz_t z, const char *str, int base); // finalizer /*@ requires \valid(x); @ assigns *x; */ -extern void mpz_clear(mpz_t x); +extern void __gmpz_clear(mpz_t x); // logical and arithmetic operators /*@ requires \valid(z1); @ requires \valid(z2); @ assigns \nothing; */ -extern int mpz_cmp(const mpz_t z1, const mpz_t z2); +extern int __gmpz_cmp(const mpz_t z1, const mpz_t z2); /*@ requires \valid(z1); @ requires \valid(z2); @ assigns *z1; */ -extern int mpz_comp(mpz_t z1, const mpz_t z2); +extern int __gmpz_comp(mpz_t z1, const mpz_t z2); /*@ requires \valid(z1); @ requires \valid(z2); @ assigns *z1; */ -extern void mpz_neg(mpz_t z1, const mpz_t z2); +extern void __gmpz_neg(mpz_t z1, const mpz_t z2); /*@ requires \valid(z1); @ requires \valid(z2); @ requires \valid(z3); @ assigns *z1; */ -extern void mpz_add(mpz_t z1, const mpz_t z2, const mpz_t z3); +extern void __gmpz_add(mpz_t z1, const mpz_t z2, const mpz_t z3); /*@ requires \valid(z1); @ requires \valid(z2); @ requires \valid(z3); @ assigns *z1; */ -extern void mpz_sub(mpz_t z1, const mpz_t z2, const mpz_t z3); +extern void __gmpz_sub(mpz_t z1, const mpz_t z2, const mpz_t z3); /*@ requires \valid(z1); @ requires \valid(z2); @ requires \valid(z3); @ assigns *z1; */ -extern void mpz_mul(mpz_t z1, const mpz_t z2, const mpz_t z3); +extern void __gmpz_mul(mpz_t z1, const mpz_t z2, const mpz_t z3); /*@ requires \valid(z1); @ requires \valid(z2); @ requires \valid(z3); @ assigns *z1; */ -extern void mpz_tdiv_q(mpz_t z1, const mpz_t z2, const mpz_t z3); +extern void __gmpz_tdiv_q(mpz_t z1, const mpz_t z2, const mpz_t z3); /*@ requires \valid(z1); @ requires \valid(z2); @ requires \valid(z3); @ assigns *z1; */ -extern void mpz_tdiv_r(mpz_t z1, const mpz_t z2, const mpz_t z3); +extern void __gmpz_tdiv_r(mpz_t z1, const mpz_t z2, const mpz_t z3); // coercions to C int /*@ requires \valid(z); @ assigns \nothing; */ -extern long mpz_get_si(const mpz_t z); +extern long __gmpz_get_si(const mpz_t z); /*@ requires \valid(z); @ assigns \nothing; */ -extern unsigned long mpz_get_ui(const mpz_t z); +extern unsigned long __gmpz_get_ui(const mpz_t z); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/addrOf.i b/src/plugins/e-acsl/tests/e-acsl-runtime/addrOf.i index 8e3d7aca223a0cf6e1aaab3b2d7ff15f57d9293c..51565e156ed35085aa807085cd8c6f740a883858 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/addrOf.i +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/addrOf.i @@ -1,6 +1,6 @@ /* run.config COMMENT: addrOf - EXECNOW: LOG gen_addrOf.c BIN gen_addrOf.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/addrOf.i -e-acsl-project p -e-acsl-include-headers -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_addrOf.c > /dev/null && gcc -o ./tests/e-acsl-runtime/result/gen_addrOf.out ./tests/e-acsl-runtime/result/gen_addrOf.c && ./tests/e-acsl-runtime/result/gen_addrOf.out + EXECNOW: LOG gen_addrOf.c BIN gen_addrOf.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/addrOf.i -e-acsl-project p -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_addrOf.c > /dev/null && gcc -pedantic -o ./tests/e-acsl-runtime/result/gen_addrOf.out ./tests/e-acsl-runtime/result/gen_addrOf.c && ./tests/e-acsl-runtime/result/gen_addrOf.out */ int main(void) { int x = 0; diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/arith.i b/src/plugins/e-acsl/tests/e-acsl-runtime/arith.i index d1ead2ef6e2c3b09c13cd9bedbda29be5e90e96b..0c526f6e42cf897e84a0312fb6929046a05f986a 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/arith.i +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/arith.i @@ -1,7 +1,7 @@ /* run.config COMMENT: arithmetic operations COMMENT: add the last assertion when fixing BTS #751 - EXECNOW: LOG gen_arith.c BIN gen_arith.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/arith.i -e-acsl-project p -e-acsl-include-headers -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_arith.c > /dev/null && gcc -o ./tests/e-acsl-runtime/result/gen_arith.out ./tests/e-acsl-runtime/result/gen_arith.c -lgmp && ./tests/e-acsl-runtime/result/gen_arith.out + EXECNOW: LOG gen_arith.c BIN gen_arith.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/arith.i -e-acsl-project p -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_arith.c > /dev/null && gcc -pedantic -o ./tests/e-acsl-runtime/result/gen_arith.out ./tests/e-acsl-runtime/result/gen_arith.c -lgmp && ./tests/e-acsl-runtime/result/gen_arith.out */ int main(void) { diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/array.i b/src/plugins/e-acsl/tests/e-acsl-runtime/array.i index 4c688bfe8d05432061b67360e45788a75fc7203b..9900338f8085d623c22da84946720566e31bae47 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/array.i +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/array.i @@ -1,6 +1,6 @@ /* run.config COMMENT: arrays - EXECNOW: LOG gen_array.c BIN gen_array.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/array.i -e-acsl-project p -e-acsl-include-headers -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_array.c > /dev/null && gcc -o ./tests/e-acsl-runtime/result/gen_array.out ./tests/e-acsl-runtime/result/gen_array.c -lgmp && ./tests/e-acsl-runtime/result/gen_array.out + EXECNOW: LOG gen_array.c BIN gen_array.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/array.i -e-acsl-project p -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_array.c > /dev/null && gcc -pedantic -o ./tests/e-acsl-runtime/result/gen_array.out ./tests/e-acsl-runtime/result/gen_array.c -lgmp && ./tests/e-acsl-runtime/result/gen_array.out */ int T1[3],T2[4]; diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/at.i b/src/plugins/e-acsl/tests/e-acsl-runtime/at.i index 9ca397f65f6927364e962f610b0f1b674a6e8d60..6c5184c2088b09e32121687cae436e05746c65f5 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/at.i +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/at.i @@ -1,6 +1,6 @@ /* run.config COMMENT: \at - EXECNOW: LOG gen_at.c BIN gen_at.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/at.i -e-acsl-project p -e-acsl-include-headers -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_at.c > /dev/null && gcc -o ./tests/e-acsl-runtime/result/gen_at.out ./tests/e-acsl-runtime/result/gen_at.c -lgmp && ./tests/e-acsl-runtime/result/gen_at.out + EXECNOW: LOG gen_at.c BIN gen_at.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/at.i -e-acsl-project p -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_at.c > /dev/null && gcc -pedantic -o ./tests/e-acsl-runtime/result/gen_at.out ./tests/e-acsl-runtime/result/gen_at.c -lgmp && ./tests/e-acsl-runtime/result/gen_at.out */ int A = 0; diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/cast.i b/src/plugins/e-acsl/tests/e-acsl-runtime/cast.i index ebd2e6d97c0b4ebd8ba5899fb9467be1bccb7c93..4dfe44dcf375e3d5f3bf22c9706b461af22b6b61 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/cast.i +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/cast.i @@ -1,6 +1,6 @@ /* run.config COMMENT: cast - EXECNOW: LOG gen_cast.c BIN gen_cast.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/cast.i -e-acsl-project p -e-acsl-include-headers -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_cast.c > /dev/null && gcc -o ./tests/e-acsl-runtime/result/gen_cast.out ./tests/e-acsl-runtime/result/gen_cast.c -lgmp && ./tests/e-acsl-runtime/result/gen_cast.out + EXECNOW: LOG gen_cast.c BIN gen_cast.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/cast.i -e-acsl-project p -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_cast.c > /dev/null && gcc -pedantic -o ./tests/e-acsl-runtime/result/gen_cast.out ./tests/e-acsl-runtime/result/gen_cast.c -lgmp && ./tests/e-acsl-runtime/result/gen_cast.out */ int main(void) { diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/comparison.i b/src/plugins/e-acsl/tests/e-acsl-runtime/comparison.i index b3b772e3767acecb9a4b285bd524b9756b70d569..1d07baab4663e7195960fb88a47c55d00e5707c2 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/comparison.i +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/comparison.i @@ -1,6 +1,6 @@ /* run.config COMMENT: comparison operators - EXECNOW: LOG gen_comparison.c BIN gen_comparison.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/comparison.i -e-acsl-project p -e-acsl-include-headers -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_comparison.c > /dev/null && gcc -o ./tests/e-acsl-runtime/result/gen_comparison.out ./tests/e-acsl-runtime/result/gen_comparison.c -lgmp && ./tests/e-acsl-runtime/result/gen_comparison.out + EXECNOW: LOG gen_comparison.c BIN gen_comparison.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/comparison.i -e-acsl-project p -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_comparison.c > /dev/null && gcc -pedantic -o ./tests/e-acsl-runtime/result/gen_comparison.out ./tests/e-acsl-runtime/result/gen_comparison.c -lgmp && ./tests/e-acsl-runtime/result/gen_comparison.out */ int main(void) { diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/false.i b/src/plugins/e-acsl/tests/e-acsl-runtime/false.i index 051451ade6db2837f64d1ade436cd2ce14be7015..109f5b28bc92bc7891b3b08090b92dcbb4bfa73e 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/false.i +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/false.i @@ -1,6 +1,6 @@ /* run.config COMMENT: assert \false - EXECNOW: LOG gen_false.c BIN gen_false.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/false.i -e-acsl-project p -e-acsl-include-headers -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_false.c > /dev/null && gcc -o ./tests/e-acsl-runtime/result/gen_false.out ./tests/e-acsl-runtime/result/gen_false.c && ./tests/e-acsl-runtime/result/gen_false.out + EXECNOW: LOG gen_false.c BIN gen_false.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/false.i -e-acsl-project p -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_false.c > /dev/null && gcc -pedantic -o ./tests/e-acsl-runtime/result/gen_false.out ./tests/e-acsl-runtime/result/gen_false.c && ./tests/e-acsl-runtime/result/gen_false.out */ int main(void) { int x = 0; diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/function_contract.i b/src/plugins/e-acsl/tests/e-acsl-runtime/function_contract.i index d60e8c729b12f6643e75b0fdf2ba821ae06e0872..b3a7eed0542afec6f7baff18605c477cb1125fc8 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/function_contract.i +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/function_contract.i @@ -1,6 +1,6 @@ /* run.config COMMENT: function contract - EXECNOW: LOG gen_function_contract.c BIN gen_function_contract.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/function_contract.i -e-acsl-project p -e-acsl-include-headers -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_function_contract.c > /dev/null && gcc -o ./tests/e-acsl-runtime/result/gen_function_contract.out ./tests/e-acsl-runtime/result/gen_function_contract.c -lgmp && ./tests/e-acsl-runtime/result/gen_function_contract.out + EXECNOW: LOG gen_function_contract.c BIN gen_function_contract.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/function_contract.i -e-acsl-project p -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_function_contract.c > /dev/null && gcc -pedantic -o ./tests/e-acsl-runtime/result/gen_function_contract.out ./tests/e-acsl-runtime/result/gen_function_contract.c -lgmp && ./tests/e-acsl-runtime/result/gen_function_contract.out */ int X = 0, Y = 2; diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/integer_constant.i b/src/plugins/e-acsl/tests/e-acsl-runtime/integer_constant.i index ad3b125def1d2b19aa134d34c0c73ca42c687d0b..fddc7eba8cc36cc4b5b766f4516b7e1df1544f82 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/integer_constant.i +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/integer_constant.i @@ -1,7 +1,7 @@ /* run.config COMMENT: integer constant + a stmt after the assertion COMMENT: waiting for fixing BTS #745 - EXECNOW: LOG gen_integer_constant.c BIN gen_integer_constant.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/integer_constant.i -e-acsl-project p -e-acsl-include-headers -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_integer_constant.c > /dev/null && gcc -o ./tests/e-acsl-runtime/result/gen_integer_constant.out ./tests/e-acsl-runtime/result/gen_integer_constant.c -lgmp && ./tests/e-acsl-runtime/result/gen_integer_constant.out + EXECNOW: LOG gen_integer_constant.c BIN gen_integer_constant.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/integer_constant.i -e-acsl-project p -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_integer_constant.c > /dev/null && gcc -pedantic -o ./tests/e-acsl-runtime/result/gen_integer_constant.out ./tests/e-acsl-runtime/result/gen_integer_constant.c -lgmp && ./tests/e-acsl-runtime/result/gen_integer_constant.out */ int main(void) { int x; diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/lazy.i b/src/plugins/e-acsl/tests/e-acsl-runtime/lazy.i index df25a0847f1d68fec82cbb360190f0a679df6f41..d0ef7f799a1d703ddb48d66d44891b29725e3d9b 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/lazy.i +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/lazy.i @@ -1,6 +1,6 @@ /* run.config COMMENT: predicate using lazy operators - EXECNOW: LOG gen_lazy.c BIN gen_lazy.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/lazy.i -e-acsl-project p -e-acsl-include-headers -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_lazy.c > /dev/null && gcc -o ./tests/e-acsl-runtime/result/gen_lazy.out ./tests/e-acsl-runtime/result/gen_lazy.c -lgmp 2> /dev/null && ./tests/e-acsl-runtime/result/gen_lazy.out + EXECNOW: LOG gen_lazy.c BIN gen_lazy.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/lazy.i -e-acsl-project p -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_lazy.c > /dev/null && gcc -pedantic -o ./tests/e-acsl-runtime/result/gen_lazy.out ./tests/e-acsl-runtime/result/gen_lazy.c -lgmp 2> /dev/null && ./tests/e-acsl-runtime/result/gen_lazy.out */ int main(void) { diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/nested_code_annot.i b/src/plugins/e-acsl/tests/e-acsl-runtime/nested_code_annot.i index 3d3b2ef6960914d223caaa2e6a555d2e564e9a82..97290d82949cc51a5d98d258f5ff99301545df4a 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/nested_code_annot.i +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/nested_code_annot.i @@ -1,6 +1,6 @@ /* run.config COMMENT: structured stmt with several code annotations inside - EXECNOW: LOG gen_nested_code_annot.c BIN gen_nested_code_annot.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/nested_code_annot.i -e-acsl-project p -e-acsl-include-headers -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_nested_code_annot.c > /dev/null && gcc -o ./tests/e-acsl-runtime/result/gen_nested_code_annot.out ./tests/e-acsl-runtime/result/gen_nested_code_annot.c -lgmp && ./tests/e-acsl-runtime/result/gen_nested_code_annot.out + EXECNOW: LOG gen_nested_code_annot.c BIN gen_nested_code_annot.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/nested_code_annot.i -e-acsl-project p -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_nested_code_annot.c > /dev/null && gcc -pedantic -o ./tests/e-acsl-runtime/result/gen_nested_code_annot.out ./tests/e-acsl-runtime/result/gen_nested_code_annot.c -lgmp && ./tests/e-acsl-runtime/result/gen_nested_code_annot.out */ int main(void) { diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/not.i b/src/plugins/e-acsl/tests/e-acsl-runtime/not.i index 452dd89b8e894bad1adeca5f5dd4b80c2f9a6d18..264b6c1e9ca75711e7eb27162fa1a37fec25a714 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/not.i +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/not.i @@ -1,6 +1,6 @@ /* run.config COMMENT: predicate [!p] - EXECNOW: LOG gen_not.c BIN gen_not.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/not.i -e-acsl-project p -e-acsl-include-headers -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_not.c > /dev/null && gcc -o ./tests/e-acsl-runtime/result/gen_not.out ./tests/e-acsl-runtime/result/gen_not.c && ./tests/e-acsl-runtime/result/gen_not.out + EXECNOW: LOG gen_not.c BIN gen_not.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/not.i -e-acsl-project p -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_not.c > /dev/null && gcc -pedantic -o ./tests/e-acsl-runtime/result/gen_not.out ./tests/e-acsl-runtime/result/gen_not.c && ./tests/e-acsl-runtime/result/gen_not.out */ int main(void) { int x = 0; diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/null.i b/src/plugins/e-acsl/tests/e-acsl-runtime/null.i index 32f28ac1131a986abc0ca99750dcadcf42fefded..656111e89ba271fedb1533db646c236fc56e0f5c 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/null.i +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/null.i @@ -1,6 +1,6 @@ /* run.config COMMENT: assert \null == 0 - EXECNOW: LOG gen_null.c BIN gen_null.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/null.i -e-acsl-project p -e-acsl-include-headers -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_null.c > /dev/null && gcc -o ./tests/e-acsl-runtime/result/gen_null.out ./tests/e-acsl-runtime/result/gen_null.c -lgmp && ./tests/e-acsl-runtime/result/gen_null.out + EXECNOW: LOG gen_null.c BIN gen_null.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/null.i -e-acsl-project p -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_null.c > /dev/null && gcc -pedantic -o ./tests/e-acsl-runtime/result/gen_null.out ./tests/e-acsl-runtime/result/gen_null.c -lgmp && ./tests/e-acsl-runtime/result/gen_null.out */ int main(void) { diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/arith.res.oracle b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/arith.res.oracle index f0b9cef6ca96dfc5db3abb0e35b2532cd7321d3e..7d10e2a3f562dbd515f55e4cccb837c7135c5e38 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/arith.res.oracle +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/arith.res.oracle @@ -4,27 +4,27 @@ [value] Initial state computed [value] Values of globals at initialization PROJECT_FILE.i:138:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:144. -PROJECT_FILE.i:33:[value] Function mpz_init_set_si: postcondition got status valid. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +PROJECT_FILE.i:33:[value] Function __gmpz_init_set_si: postcondition got status valid. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:145. -PROJECT_FILE.i:21:[value] Function mpz_init: postcondition got status valid. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +PROJECT_FILE.i:21:[value] Function __gmpz_init: postcondition got status valid. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:146. -PROJECT_FILE.i:59:[value] Function mpz_neg: precondition got status valid. -PROJECT_FILE.i:60:[value] Function mpz_neg: precondition got status valid. -[value] Done for function mpz_neg -[value] computing for function mpz_init_set_si <- main. +PROJECT_FILE.i:59:[value] Function __gmpz_neg: precondition got status valid. +PROJECT_FILE.i:60:[value] Function __gmpz_neg: precondition got status valid. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:147. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:148. -PROJECT_FILE.i:49:[value] Function mpz_cmp: precondition got status valid. -PROJECT_FILE.i:50:[value] Function mpz_cmp: precondition got status valid. -[value] Done for function mpz_cmp +PROJECT_FILE.i:49:[value] Function __gmpz_cmp: precondition got status valid. +PROJECT_FILE.i:50:[value] Function __gmpz_cmp: precondition got status valid. +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:149. [value] computing for function printf <- e_acsl_fail <- main. @@ -36,32 +36,32 @@ PROJECT_FILE.i:119:[value] Function exit: postcondition got status invalid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:150. -PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +PROJECT_FILE.i:43:[value] Function __gmpz_clear: precondition got status valid. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:151. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:152. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:156:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:162. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:163. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:164. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:165. -[value] Done for function mpz_neg -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:166. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:167. [value] computing for function printf <- e_acsl_fail <- main. @@ -72,29 +72,29 @@ PROJECT_FILE.i:156:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:168. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:169. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:170. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:174:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:179. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:180. -[value] Done for function mpz_init -[value] computing for function mpz_com <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_com <- main. Called from PROJECT_FILE.i:181. -[kernel] warning: No code for function mpz_com, default assigns generated -[value] Done for function mpz_com -[value] computing for function mpz_cmp <- main. +[kernel] warning: No code for function __gmpz_com, default assigns generated +[value] Done for function __gmpz_com +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:182. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:183. [value] computing for function printf <- e_acsl_fail <- main. @@ -105,40 +105,40 @@ PROJECT_FILE.i:174:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:184. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:185. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:189:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:197. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:198. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:199. -[value] Done for function mpz_init -[value] computing for function mpz_add <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_add <- main. Called from PROJECT_FILE.i:200. -PROJECT_FILE.i:64:[value] Function mpz_add: precondition got status valid. -PROJECT_FILE.i:65:[value] Function mpz_add: precondition got status valid. -PROJECT_FILE.i:66:[value] Function mpz_add: precondition got status valid. -[value] Done for function mpz_add -[value] computing for function mpz_init_set_si <- main. +PROJECT_FILE.i:64:[value] Function __gmpz_add: precondition got status valid. +PROJECT_FILE.i:65:[value] Function __gmpz_add: precondition got status valid. +PROJECT_FILE.i:66:[value] Function __gmpz_add: precondition got status valid. +[value] Done for function __gmpz_add +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:201. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:202. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:203. -[value] Done for function mpz_neg -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:204. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:205. [value] computing for function printf <- e_acsl_fail <- main. @@ -149,49 +149,49 @@ PROJECT_FILE.i:66:[value] Function mpz_add: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:206. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:207. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:208. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:209. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:210. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:214:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:222. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:223. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:224. -[value] Done for function mpz_init -[value] computing for function mpz_sub <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_sub <- main. Called from PROJECT_FILE.i:225. -PROJECT_FILE.i:70:[value] Function mpz_sub: precondition got status valid. -PROJECT_FILE.i:71:[value] Function mpz_sub: precondition got status valid. -PROJECT_FILE.i:72:[value] Function mpz_sub: precondition got status valid. -[value] Done for function mpz_sub -[value] computing for function mpz_init_set_si <- main. +PROJECT_FILE.i:70:[value] Function __gmpz_sub: precondition got status valid. +PROJECT_FILE.i:71:[value] Function __gmpz_sub: precondition got status valid. +PROJECT_FILE.i:72:[value] Function __gmpz_sub: precondition got status valid. +[value] Done for function __gmpz_sub +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:226. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:227. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:228. -[value] Done for function mpz_neg -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:229. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:230. [value] computing for function printf <- e_acsl_fail <- main. @@ -202,49 +202,49 @@ PROJECT_FILE.i:72:[value] Function mpz_sub: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:231. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:232. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:233. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:234. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:235. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:239:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:247. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:248. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:249. -[value] Done for function mpz_init -[value] computing for function mpz_mul <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_mul <- main. Called from PROJECT_FILE.i:250. -PROJECT_FILE.i:76:[value] Function mpz_mul: precondition got status valid. -PROJECT_FILE.i:77:[value] Function mpz_mul: precondition got status valid. -PROJECT_FILE.i:78:[value] Function mpz_mul: precondition got status valid. -[value] Done for function mpz_mul -[value] computing for function mpz_init_set_si <- main. +PROJECT_FILE.i:76:[value] Function __gmpz_mul: precondition got status valid. +PROJECT_FILE.i:77:[value] Function __gmpz_mul: precondition got status valid. +PROJECT_FILE.i:78:[value] Function __gmpz_mul: precondition got status valid. +[value] Done for function __gmpz_mul +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:251. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:252. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:253. -[value] Done for function mpz_neg -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:254. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:255. [value] computing for function printf <- e_acsl_fail <- main. @@ -255,35 +255,35 @@ PROJECT_FILE.i:78:[value] Function mpz_mul: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:256. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:257. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:258. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:259. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:260. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:264:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:273. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:274. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_get_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_get_si <- main. Called from PROJECT_FILE.i:275. -PROJECT_FILE.i:96:[value] Function mpz_get_si: precondition got status valid. -[value] Done for function mpz_get_si -[value] computing for function mpz_init <- main. +PROJECT_FILE.i:96:[value] Function __gmpz_get_si: precondition got status valid. +[value] Done for function __gmpz_get_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:276. -[value] Done for function mpz_init +[value] Done for function __gmpz_init PROJECT_FILE.i:277:[value] Assertion got status valid. [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:278. @@ -295,24 +295,24 @@ PROJECT_FILE.i:277:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_tdiv_q <- main. +[value] computing for function __gmpz_tdiv_q <- main. Called from PROJECT_FILE.i:279. -PROJECT_FILE.i:82:[value] Function mpz_tdiv_q: precondition got status valid. -PROJECT_FILE.i:83:[value] Function mpz_tdiv_q: precondition got status valid. -PROJECT_FILE.i:84:[value] Function mpz_tdiv_q: precondition got status valid. -[value] Done for function mpz_tdiv_q -[value] computing for function mpz_init_set_si <- main. +PROJECT_FILE.i:82:[value] Function __gmpz_tdiv_q: precondition got status valid. +PROJECT_FILE.i:83:[value] Function __gmpz_tdiv_q: precondition got status valid. +PROJECT_FILE.i:84:[value] Function __gmpz_tdiv_q: precondition got status valid. +[value] Done for function __gmpz_tdiv_q +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:280. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:281. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:282. -[value] Done for function mpz_neg -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:283. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:284. [value] computing for function printf <- e_acsl_fail <- main. @@ -323,35 +323,35 @@ PROJECT_FILE.i:84:[value] Function mpz_tdiv_q: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:285. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:286. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:287. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:288. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:289. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:293:[value] Assertion got status valid. -[value] computing for function mpz_init_set_str <- main. +[value] computing for function __gmpz_init_set_str <- main. Called from PROJECT_FILE.i:301. -PROJECT_FILE.i:37:[value] Function mpz_init_set_str: postcondition got status valid. -[value] Done for function mpz_init_set_str -[value] computing for function mpz_init_set_si <- main. +PROJECT_FILE.i:37:[value] Function __gmpz_init_set_str: postcondition got status valid. +[value] Done for function __gmpz_init_set_str +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:302. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:303. -[value] Done for function mpz_cmp -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:304. -[value] Done for function mpz_init +[value] Done for function __gmpz_init PROJECT_FILE.i:305:[value] Assertion got status valid. [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:306. @@ -363,15 +363,15 @@ PROJECT_FILE.i:305:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_tdiv_q <- main. +[value] computing for function __gmpz_tdiv_q <- main. Called from PROJECT_FILE.i:307. -[value] Done for function mpz_tdiv_q -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_tdiv_q +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:308. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:309. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:311. [value] computing for function printf <- e_acsl_fail <- main. @@ -382,31 +382,31 @@ PROJECT_FILE.i:305:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:313. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:314. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:315. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:316. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:320:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:329. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:330. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_get_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_get_si <- main. Called from PROJECT_FILE.i:331. -[value] Done for function mpz_get_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_get_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:332. -[value] Done for function mpz_init +[value] Done for function __gmpz_init PROJECT_FILE.i:333:[value] Assertion got status valid. [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:334. @@ -418,24 +418,24 @@ PROJECT_FILE.i:333:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_tdiv_r <- main. +[value] computing for function __gmpz_tdiv_r <- main. Called from PROJECT_FILE.i:335. -PROJECT_FILE.i:88:[value] Function mpz_tdiv_r: precondition got status valid. -PROJECT_FILE.i:89:[value] Function mpz_tdiv_r: precondition got status valid. -PROJECT_FILE.i:90:[value] Function mpz_tdiv_r: precondition got status valid. -[value] Done for function mpz_tdiv_r -[value] computing for function mpz_init_set_si <- main. +PROJECT_FILE.i:88:[value] Function __gmpz_tdiv_r: precondition got status valid. +PROJECT_FILE.i:89:[value] Function __gmpz_tdiv_r: precondition got status valid. +PROJECT_FILE.i:90:[value] Function __gmpz_tdiv_r: precondition got status valid. +[value] Done for function __gmpz_tdiv_r +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:336. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:337. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:338. -[value] Done for function mpz_neg -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:339. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:340. [value] computing for function printf <- e_acsl_fail <- main. @@ -446,49 +446,49 @@ PROJECT_FILE.i:90:[value] Function mpz_tdiv_r: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:341. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:342. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:343. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:344. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:345. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:349:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:361. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:362. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:363. -[value] Done for function mpz_neg -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:364. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:365. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:366. -[value] Done for function mpz_neg -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:367. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:368. -[value] Done for function mpz_cmp -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:369. -[value] Done for function mpz_init +[value] Done for function __gmpz_init PROJECT_FILE.i:370:[value] Assertion got status valid. [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:371. @@ -500,21 +500,21 @@ PROJECT_FILE.i:370:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_tdiv_r <- main. +[value] computing for function __gmpz_tdiv_r <- main. Called from PROJECT_FILE.i:372. -[value] Done for function mpz_tdiv_r -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_tdiv_r +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:373. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:374. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:375. -[value] Done for function mpz_neg -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:376. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:377. [value] computing for function printf <- e_acsl_fail <- main. @@ -525,52 +525,52 @@ PROJECT_FILE.i:370:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:378. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:379. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:380. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:381. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:382. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:383. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:384. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:385. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:389:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:399. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:400. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:401. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:402. -[value] Done for function mpz_neg -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:403. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:404. -[value] Done for function mpz_cmp -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:405. -[value] Done for function mpz_init +[value] Done for function __gmpz_init PROJECT_FILE.i:406:[value] Assertion got status valid. [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:407. @@ -582,15 +582,15 @@ PROJECT_FILE.i:406:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_tdiv_r <- main. +[value] computing for function __gmpz_tdiv_r <- main. Called from PROJECT_FILE.i:408. -[value] Done for function mpz_tdiv_r -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_tdiv_r +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:409. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:410. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:411. [value] computing for function printf <- e_acsl_fail <- main. @@ -601,88 +601,88 @@ PROJECT_FILE.i:406:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:412. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:413. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:414. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:415. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:416. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:417. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:421:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:437. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:438. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:439. -[value] Done for function mpz_init -[value] computing for function mpz_mul <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_mul <- main. Called from PROJECT_FILE.i:440. -[value] Done for function mpz_mul -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_mul +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:441. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:442. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:443. -[value] Done for function mpz_init -[value] computing for function mpz_add <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_add <- main. Called from PROJECT_FILE.i:444. -[value] Done for function mpz_add -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_add +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:445. -[value] Done for function mpz_init -[value] computing for function mpz_add <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_add <- main. Called from PROJECT_FILE.i:446. -[value] Done for function mpz_add -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_add +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:447. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:448. -[value] Done for function mpz_init -[value] computing for function mpz_sub <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_sub <- main. Called from PROJECT_FILE.i:449. -[value] Done for function mpz_sub -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_sub +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:450. -[value] Done for function mpz_init -[value] computing for function mpz_sub <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_sub <- main. Called from PROJECT_FILE.i:451. -[value] Done for function mpz_sub -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_sub +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:452. -[value] Done for function mpz_init -[value] computing for function mpz_add <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_add <- main. Called from PROJECT_FILE.i:453. -[value] Done for function mpz_add -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_add +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:454. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:455. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:456. -[value] Done for function mpz_neg -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:457. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:458. [value] computing for function printf <- e_acsl_fail <- main. @@ -693,62 +693,62 @@ PROJECT_FILE.i:421:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:460. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:461. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:462. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:463. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:464. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:465. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:466. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:467. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:468. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:469. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:470. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:471. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:472. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:476:[value] Assertion got status valid. PROJECT_FILE.i:479:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:485. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:486. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:487. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:488. -[value] Done for function mpz_neg -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:489. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:490. [value] computing for function printf <- e_acsl_fail <- main. @@ -759,31 +759,31 @@ PROJECT_FILE.i:479:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:492. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:493. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:494. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:498:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:504. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:505. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:506. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:507. -[value] Done for function mpz_neg -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:508. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:510. [value] computing for function printf <- e_acsl_fail <- main. @@ -794,15 +794,15 @@ PROJECT_FILE.i:498:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:512. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:513. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:514. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:518:[value] Assertion got status valid. PROJECT_FILE.i:521:[value] Assertion got status valid. [value] Recording results for main @@ -824,71 +824,71 @@ typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; /*@ ensures \valid(\old(x)); assigns *x; */ -extern void mpz_init(__mpz_struct * /*[1]*/ x); +extern void __gmpz_init(__mpz_struct * /*[1]*/ x); /*@ ensures \valid(\old(z)); assigns *z; assigns *z \from n; */ -extern void mpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); +extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); /*@ ensures \valid(\old(z)); assigns *z; */ -extern int mpz_init_set_str(__mpz_struct * /*[1]*/ z, char const *str, - int base); +extern int __gmpz_init_set_str(__mpz_struct * /*[1]*/ z, char const *str, + int base); /*@ requires \valid(x); assigns *x; */ -extern void mpz_clear(__mpz_struct * /*[1]*/ x); +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); assigns \nothing; */ -extern int mpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ requires \valid(z1); requires \valid(z2); assigns *z1; */ -extern void mpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); +extern void __gmpz_neg(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ requires \valid(z1); requires \valid(z2); requires \valid(z3); assigns *z1; */ -extern void mpz_add(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); +extern void __gmpz_add(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2, + __mpz_struct const * /*[1]*/ z3); /*@ requires \valid(z1); requires \valid(z2); requires \valid(z3); assigns *z1; */ -extern void mpz_sub(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); +extern void __gmpz_sub(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2, + __mpz_struct const * /*[1]*/ z3); /*@ requires \valid(z1); requires \valid(z2); requires \valid(z3); assigns *z1; */ -extern void mpz_mul(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); +extern void __gmpz_mul(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2, + __mpz_struct const * /*[1]*/ z3); /*@ requires \valid(z1); requires \valid(z2); requires \valid(z3); assigns *z1; */ -extern void mpz_tdiv_q(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); +extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2, + __mpz_struct const * /*[1]*/ z3); /*@ requires \valid(z1); requires \valid(z2); requires \valid(z3); assigns *z1; */ -extern void mpz_tdiv_r(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); +extern void __gmpz_tdiv_r(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2, + __mpz_struct const * /*[1]*/ z3); /*@ requires \valid(z); assigns \nothing; */ -extern long mpz_get_si(__mpz_struct const * /*[1]*/ z); +extern long __gmpz_get_si(__mpz_struct const * /*[1]*/ z); /*@ terminates \false; ensures \false; assigns \nothing; */ @@ -904,7 +904,7 @@ void e_acsl_fail(char *msg) /*@ behavior generated: assigns \at(\result,Post) \from \nothing; */ -extern int ( /* missing proto */ mpz_com)(); +extern int ( /* missing proto */ __gmpz_com)(); int main(void) { int __retres; @@ -918,16 +918,16 @@ int main(void) mpz_t e_acsl_2; mpz_t e_acsl_3; int e_acsl_4; - mpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)3); - mpz_init((__mpz_struct *)(e_acsl_2)); - mpz_neg((__mpz_struct *)(e_acsl_2),(__mpz_struct const *)(e_acsl_1)); - mpz_init_set_si((__mpz_struct *)(e_acsl_3),(long)x); - e_acsl_4 = mpz_cmp((__mpz_struct const *)(e_acsl_2), - (__mpz_struct const *)(e_acsl_3)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)3); + __gmpz_init((__mpz_struct *)(e_acsl_2)); + __gmpz_neg((__mpz_struct *)(e_acsl_2),(__mpz_struct const *)(e_acsl_1)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_3),(long)x); + e_acsl_4 = __gmpz_cmp((__mpz_struct const *)(e_acsl_2), + (__mpz_struct const *)(e_acsl_3)); if (! (e_acsl_4 == 0)) { e_acsl_fail((char *)"(-3 == x)"); } - mpz_clear((__mpz_struct *)(e_acsl_1)); - mpz_clear((__mpz_struct *)(e_acsl_2)); - mpz_clear((__mpz_struct *)(e_acsl_3)); + __gmpz_clear((__mpz_struct *)(e_acsl_1)); + __gmpz_clear((__mpz_struct *)(e_acsl_2)); + __gmpz_clear((__mpz_struct *)(e_acsl_3)); } /*@ assert x ≡ -3; */ ; @@ -936,16 +936,16 @@ int main(void) mpz_t e_acsl_6; mpz_t e_acsl_7; int e_acsl_8; - mpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_6),(long)3); - mpz_init((__mpz_struct *)(e_acsl_7)); - mpz_neg((__mpz_struct *)(e_acsl_7),(__mpz_struct const *)(e_acsl_6)); - e_acsl_8 = mpz_cmp((__mpz_struct const *)(e_acsl_5), - (__mpz_struct const *)(e_acsl_7)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_6),(long)3); + __gmpz_init((__mpz_struct *)(e_acsl_7)); + __gmpz_neg((__mpz_struct *)(e_acsl_7),(__mpz_struct const *)(e_acsl_6)); + e_acsl_8 = __gmpz_cmp((__mpz_struct const *)(e_acsl_5), + (__mpz_struct const *)(e_acsl_7)); if (! (e_acsl_8 == 0)) { e_acsl_fail((char *)"(x == -3)"); } - mpz_clear((__mpz_struct *)(e_acsl_5)); - mpz_clear((__mpz_struct *)(e_acsl_6)); - mpz_clear((__mpz_struct *)(e_acsl_7)); + __gmpz_clear((__mpz_struct *)(e_acsl_5)); + __gmpz_clear((__mpz_struct *)(e_acsl_6)); + __gmpz_clear((__mpz_struct *)(e_acsl_7)); } /*@ assert 0 ≢ ~0; */ ; @@ -953,14 +953,14 @@ int main(void) mpz_t e_acsl_9; mpz_t e_acsl_10; int e_acsl_11; - mpz_init_set_si((__mpz_struct *)(e_acsl_9),(long)0); - mpz_init((__mpz_struct *)(e_acsl_10)); - mpz_com(e_acsl_10,e_acsl_9); - e_acsl_11 = mpz_cmp((__mpz_struct const *)(e_acsl_9), - (__mpz_struct const *)(e_acsl_10)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_9),(long)0); + __gmpz_init((__mpz_struct *)(e_acsl_10)); + __gmpz_com(e_acsl_10,e_acsl_9); + e_acsl_11 = __gmpz_cmp((__mpz_struct const *)(e_acsl_9), + (__mpz_struct const *)(e_acsl_10)); if (! (e_acsl_11 != 0)) { e_acsl_fail((char *)"(0 != ~0)"); } - mpz_clear((__mpz_struct *)(e_acsl_9)); - mpz_clear((__mpz_struct *)(e_acsl_10)); + __gmpz_clear((__mpz_struct *)(e_acsl_9)); + __gmpz_clear((__mpz_struct *)(e_acsl_10)); } /*@ assert x+1 ≡ -2; */ ; @@ -971,22 +971,22 @@ int main(void) mpz_t e_acsl_15; mpz_t e_acsl_16; int e_acsl_17; - mpz_init_set_si((__mpz_struct *)(e_acsl_12),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_13),(long)1); - mpz_init((__mpz_struct *)(e_acsl_14)); - mpz_add((__mpz_struct *)(e_acsl_14),(__mpz_struct const *)(e_acsl_12), - (__mpz_struct const *)(e_acsl_13)); - mpz_init_set_si((__mpz_struct *)(e_acsl_15),(long)2); - mpz_init((__mpz_struct *)(e_acsl_16)); - mpz_neg((__mpz_struct *)(e_acsl_16),(__mpz_struct const *)(e_acsl_15)); - e_acsl_17 = mpz_cmp((__mpz_struct const *)(e_acsl_14), - (__mpz_struct const *)(e_acsl_16)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_12),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_13),(long)1); + __gmpz_init((__mpz_struct *)(e_acsl_14)); + __gmpz_add((__mpz_struct *)(e_acsl_14),(__mpz_struct const *)(e_acsl_12), + (__mpz_struct const *)(e_acsl_13)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_15),(long)2); + __gmpz_init((__mpz_struct *)(e_acsl_16)); + __gmpz_neg((__mpz_struct *)(e_acsl_16),(__mpz_struct const *)(e_acsl_15)); + e_acsl_17 = __gmpz_cmp((__mpz_struct const *)(e_acsl_14), + (__mpz_struct const *)(e_acsl_16)); if (! (e_acsl_17 == 0)) { e_acsl_fail((char *)"(x+1 == -2)"); } - mpz_clear((__mpz_struct *)(e_acsl_12)); - mpz_clear((__mpz_struct *)(e_acsl_13)); - mpz_clear((__mpz_struct *)(e_acsl_14)); - mpz_clear((__mpz_struct *)(e_acsl_15)); - mpz_clear((__mpz_struct *)(e_acsl_16)); + __gmpz_clear((__mpz_struct *)(e_acsl_12)); + __gmpz_clear((__mpz_struct *)(e_acsl_13)); + __gmpz_clear((__mpz_struct *)(e_acsl_14)); + __gmpz_clear((__mpz_struct *)(e_acsl_15)); + __gmpz_clear((__mpz_struct *)(e_acsl_16)); } /*@ assert x-1 ≡ -4; */ ; @@ -997,22 +997,22 @@ int main(void) mpz_t e_acsl_21; mpz_t e_acsl_22; int e_acsl_23; - mpz_init_set_si((__mpz_struct *)(e_acsl_18),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_19),(long)1); - mpz_init((__mpz_struct *)(e_acsl_20)); - mpz_sub((__mpz_struct *)(e_acsl_20),(__mpz_struct const *)(e_acsl_18), - (__mpz_struct const *)(e_acsl_19)); - mpz_init_set_si((__mpz_struct *)(e_acsl_21),(long)4); - mpz_init((__mpz_struct *)(e_acsl_22)); - mpz_neg((__mpz_struct *)(e_acsl_22),(__mpz_struct const *)(e_acsl_21)); - e_acsl_23 = mpz_cmp((__mpz_struct const *)(e_acsl_20), - (__mpz_struct const *)(e_acsl_22)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_18),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_19),(long)1); + __gmpz_init((__mpz_struct *)(e_acsl_20)); + __gmpz_sub((__mpz_struct *)(e_acsl_20),(__mpz_struct const *)(e_acsl_18), + (__mpz_struct const *)(e_acsl_19)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_21),(long)4); + __gmpz_init((__mpz_struct *)(e_acsl_22)); + __gmpz_neg((__mpz_struct *)(e_acsl_22),(__mpz_struct const *)(e_acsl_21)); + e_acsl_23 = __gmpz_cmp((__mpz_struct const *)(e_acsl_20), + (__mpz_struct const *)(e_acsl_22)); if (! (e_acsl_23 == 0)) { e_acsl_fail((char *)"(x-1 == -4)"); } - mpz_clear((__mpz_struct *)(e_acsl_18)); - mpz_clear((__mpz_struct *)(e_acsl_19)); - mpz_clear((__mpz_struct *)(e_acsl_20)); - mpz_clear((__mpz_struct *)(e_acsl_21)); - mpz_clear((__mpz_struct *)(e_acsl_22)); + __gmpz_clear((__mpz_struct *)(e_acsl_18)); + __gmpz_clear((__mpz_struct *)(e_acsl_19)); + __gmpz_clear((__mpz_struct *)(e_acsl_20)); + __gmpz_clear((__mpz_struct *)(e_acsl_21)); + __gmpz_clear((__mpz_struct *)(e_acsl_22)); } /*@ assert x*3 ≡ -9; */ ; @@ -1023,22 +1023,22 @@ int main(void) mpz_t e_acsl_27; mpz_t e_acsl_28; int e_acsl_29; - mpz_init_set_si((__mpz_struct *)(e_acsl_24),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_25),(long)3); - mpz_init((__mpz_struct *)(e_acsl_26)); - mpz_mul((__mpz_struct *)(e_acsl_26),(__mpz_struct const *)(e_acsl_24), - (__mpz_struct const *)(e_acsl_25)); - mpz_init_set_si((__mpz_struct *)(e_acsl_27),(long)9); - mpz_init((__mpz_struct *)(e_acsl_28)); - mpz_neg((__mpz_struct *)(e_acsl_28),(__mpz_struct const *)(e_acsl_27)); - e_acsl_29 = mpz_cmp((__mpz_struct const *)(e_acsl_26), - (__mpz_struct const *)(e_acsl_28)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_24),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_25),(long)3); + __gmpz_init((__mpz_struct *)(e_acsl_26)); + __gmpz_mul((__mpz_struct *)(e_acsl_26),(__mpz_struct const *)(e_acsl_24), + (__mpz_struct const *)(e_acsl_25)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_27),(long)9); + __gmpz_init((__mpz_struct *)(e_acsl_28)); + __gmpz_neg((__mpz_struct *)(e_acsl_28),(__mpz_struct const *)(e_acsl_27)); + e_acsl_29 = __gmpz_cmp((__mpz_struct const *)(e_acsl_26), + (__mpz_struct const *)(e_acsl_28)); if (! (e_acsl_29 == 0)) { e_acsl_fail((char *)"(x*3 == -9)"); } - mpz_clear((__mpz_struct *)(e_acsl_24)); - mpz_clear((__mpz_struct *)(e_acsl_25)); - mpz_clear((__mpz_struct *)(e_acsl_26)); - mpz_clear((__mpz_struct *)(e_acsl_27)); - mpz_clear((__mpz_struct *)(e_acsl_28)); + __gmpz_clear((__mpz_struct *)(e_acsl_24)); + __gmpz_clear((__mpz_struct *)(e_acsl_25)); + __gmpz_clear((__mpz_struct *)(e_acsl_26)); + __gmpz_clear((__mpz_struct *)(e_acsl_27)); + __gmpz_clear((__mpz_struct *)(e_acsl_28)); } /*@ assert x/3 ≡ -1; */ ; @@ -1050,25 +1050,26 @@ int main(void) mpz_t e_acsl_34; mpz_t e_acsl_35; int e_acsl_36; - mpz_init_set_si((__mpz_struct *)(e_acsl_30),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_31),(long)3); - e_acsl_32 = (int)mpz_get_si((__mpz_struct const *)(e_acsl_31)); - mpz_init((__mpz_struct *)(e_acsl_33)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_30),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_31),(long)3); + e_acsl_32 = (int)__gmpz_get_si((__mpz_struct const *)(e_acsl_31)); + __gmpz_init((__mpz_struct *)(e_acsl_33)); /*@ assert 3 ≢ 0; */ ; if (e_acsl_32 == 0) { e_acsl_fail((char *)"(3 == 0)"); } - mpz_tdiv_q((__mpz_struct *)(e_acsl_33),(__mpz_struct const *)(e_acsl_30), - (__mpz_struct const *)(e_acsl_31)); - mpz_init_set_si((__mpz_struct *)(e_acsl_34),(long)1); - mpz_init((__mpz_struct *)(e_acsl_35)); - mpz_neg((__mpz_struct *)(e_acsl_35),(__mpz_struct const *)(e_acsl_34)); - e_acsl_36 = mpz_cmp((__mpz_struct const *)(e_acsl_33), - (__mpz_struct const *)(e_acsl_35)); + __gmpz_tdiv_q((__mpz_struct *)(e_acsl_33), + (__mpz_struct const *)(e_acsl_30), + (__mpz_struct const *)(e_acsl_31)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_34),(long)1); + __gmpz_init((__mpz_struct *)(e_acsl_35)); + __gmpz_neg((__mpz_struct *)(e_acsl_35),(__mpz_struct const *)(e_acsl_34)); + e_acsl_36 = __gmpz_cmp((__mpz_struct const *)(e_acsl_33), + (__mpz_struct const *)(e_acsl_35)); if (! (e_acsl_36 == 0)) { e_acsl_fail((char *)"(x/3 == -1)"); } - mpz_clear((__mpz_struct *)(e_acsl_30)); - mpz_clear((__mpz_struct *)(e_acsl_31)); - mpz_clear((__mpz_struct *)(e_acsl_33)); - mpz_clear((__mpz_struct *)(e_acsl_34)); - mpz_clear((__mpz_struct *)(e_acsl_35)); + __gmpz_clear((__mpz_struct *)(e_acsl_30)); + __gmpz_clear((__mpz_struct *)(e_acsl_31)); + __gmpz_clear((__mpz_struct *)(e_acsl_33)); + __gmpz_clear((__mpz_struct *)(e_acsl_34)); + __gmpz_clear((__mpz_struct *)(e_acsl_35)); } /*@ assert 0xfffffffffff/0xfffffffffff ≡ 1; */ ; @@ -1079,25 +1080,26 @@ int main(void) mpz_t e_acsl_40; mpz_t e_acsl_41; int e_acsl_42; - mpz_init_set_str((__mpz_struct *)(e_acsl_37),"17592186044415",10); - mpz_init_set_si((__mpz_struct *)(e_acsl_38),(long)0); - e_acsl_39 = mpz_cmp((__mpz_struct const *)(e_acsl_37), - (__mpz_struct const *)(e_acsl_38)); - mpz_init((__mpz_struct *)(e_acsl_40)); + __gmpz_init_set_str((__mpz_struct *)(e_acsl_37),"17592186044415",10); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_38),(long)0); + e_acsl_39 = __gmpz_cmp((__mpz_struct const *)(e_acsl_37), + (__mpz_struct const *)(e_acsl_38)); + __gmpz_init((__mpz_struct *)(e_acsl_40)); /*@ assert 0xfffffffffff ≢ 0; */ ; if (e_acsl_39 == 0) { e_acsl_fail((char *)"(0xfffffffffff == 0)"); } - mpz_tdiv_q((__mpz_struct *)(e_acsl_40),(__mpz_struct const *)(e_acsl_37), - (__mpz_struct const *)(e_acsl_37)); - mpz_init_set_si((__mpz_struct *)(e_acsl_41),(long)1); - e_acsl_42 = mpz_cmp((__mpz_struct const *)(e_acsl_40), - (__mpz_struct const *)(e_acsl_41)); + __gmpz_tdiv_q((__mpz_struct *)(e_acsl_40), + (__mpz_struct const *)(e_acsl_37), + (__mpz_struct const *)(e_acsl_37)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_41),(long)1); + e_acsl_42 = __gmpz_cmp((__mpz_struct const *)(e_acsl_40), + (__mpz_struct const *)(e_acsl_41)); if (! (e_acsl_42 == 0)) { e_acsl_fail((char *)"(0xfffffffffff/0xfffffffffff == 1)"); } - mpz_clear((__mpz_struct *)(e_acsl_37)); - mpz_clear((__mpz_struct *)(e_acsl_38)); - mpz_clear((__mpz_struct *)(e_acsl_40)); - mpz_clear((__mpz_struct *)(e_acsl_41)); + __gmpz_clear((__mpz_struct *)(e_acsl_37)); + __gmpz_clear((__mpz_struct *)(e_acsl_38)); + __gmpz_clear((__mpz_struct *)(e_acsl_40)); + __gmpz_clear((__mpz_struct *)(e_acsl_41)); } /*@ assert x%2 ≡ -1; */ ; @@ -1109,25 +1111,26 @@ int main(void) mpz_t e_acsl_47; mpz_t e_acsl_48; int e_acsl_49; - mpz_init_set_si((__mpz_struct *)(e_acsl_43),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_44),(long)2); - e_acsl_45 = (int)mpz_get_si((__mpz_struct const *)(e_acsl_44)); - mpz_init((__mpz_struct *)(e_acsl_46)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_43),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_44),(long)2); + e_acsl_45 = (int)__gmpz_get_si((__mpz_struct const *)(e_acsl_44)); + __gmpz_init((__mpz_struct *)(e_acsl_46)); /*@ assert 2 ≢ 0; */ ; if (e_acsl_45 == 0) { e_acsl_fail((char *)"(2 == 0)"); } - mpz_tdiv_r((__mpz_struct *)(e_acsl_46),(__mpz_struct const *)(e_acsl_43), - (__mpz_struct const *)(e_acsl_44)); - mpz_init_set_si((__mpz_struct *)(e_acsl_47),(long)1); - mpz_init((__mpz_struct *)(e_acsl_48)); - mpz_neg((__mpz_struct *)(e_acsl_48),(__mpz_struct const *)(e_acsl_47)); - e_acsl_49 = mpz_cmp((__mpz_struct const *)(e_acsl_46), - (__mpz_struct const *)(e_acsl_48)); + __gmpz_tdiv_r((__mpz_struct *)(e_acsl_46), + (__mpz_struct const *)(e_acsl_43), + (__mpz_struct const *)(e_acsl_44)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_47),(long)1); + __gmpz_init((__mpz_struct *)(e_acsl_48)); + __gmpz_neg((__mpz_struct *)(e_acsl_48),(__mpz_struct const *)(e_acsl_47)); + e_acsl_49 = __gmpz_cmp((__mpz_struct const *)(e_acsl_46), + (__mpz_struct const *)(e_acsl_48)); if (! (e_acsl_49 == 0)) { e_acsl_fail((char *)"(x%2 == -1)"); } - mpz_clear((__mpz_struct *)(e_acsl_43)); - mpz_clear((__mpz_struct *)(e_acsl_44)); - mpz_clear((__mpz_struct *)(e_acsl_46)); - mpz_clear((__mpz_struct *)(e_acsl_47)); - mpz_clear((__mpz_struct *)(e_acsl_48)); + __gmpz_clear((__mpz_struct *)(e_acsl_43)); + __gmpz_clear((__mpz_struct *)(e_acsl_44)); + __gmpz_clear((__mpz_struct *)(e_acsl_46)); + __gmpz_clear((__mpz_struct *)(e_acsl_47)); + __gmpz_clear((__mpz_struct *)(e_acsl_48)); } /*@ assert -3%-2 ≡ -1; */ ; @@ -1142,34 +1145,35 @@ int main(void) mpz_t e_acsl_57; mpz_t e_acsl_58; int e_acsl_59; - mpz_init_set_si((__mpz_struct *)(e_acsl_50),(long)3); - mpz_init((__mpz_struct *)(e_acsl_51)); - mpz_neg((__mpz_struct *)(e_acsl_51),(__mpz_struct const *)(e_acsl_50)); - mpz_init_set_si((__mpz_struct *)(e_acsl_52),(long)2); - mpz_init((__mpz_struct *)(e_acsl_53)); - mpz_neg((__mpz_struct *)(e_acsl_53),(__mpz_struct const *)(e_acsl_52)); - mpz_init_set_si((__mpz_struct *)(e_acsl_54),(long)0); - e_acsl_55 = mpz_cmp((__mpz_struct const *)(e_acsl_53), - (__mpz_struct const *)(e_acsl_54)); - mpz_init((__mpz_struct *)(e_acsl_56)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_50),(long)3); + __gmpz_init((__mpz_struct *)(e_acsl_51)); + __gmpz_neg((__mpz_struct *)(e_acsl_51),(__mpz_struct const *)(e_acsl_50)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_52),(long)2); + __gmpz_init((__mpz_struct *)(e_acsl_53)); + __gmpz_neg((__mpz_struct *)(e_acsl_53),(__mpz_struct const *)(e_acsl_52)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_54),(long)0); + e_acsl_55 = __gmpz_cmp((__mpz_struct const *)(e_acsl_53), + (__mpz_struct const *)(e_acsl_54)); + __gmpz_init((__mpz_struct *)(e_acsl_56)); /*@ assert -2 ≢ 0; */ ; if (e_acsl_55 == 0) { e_acsl_fail((char *)"(-2 == 0)"); } - mpz_tdiv_r((__mpz_struct *)(e_acsl_56),(__mpz_struct const *)(e_acsl_51), - (__mpz_struct const *)(e_acsl_53)); - mpz_init_set_si((__mpz_struct *)(e_acsl_57),(long)1); - mpz_init((__mpz_struct *)(e_acsl_58)); - mpz_neg((__mpz_struct *)(e_acsl_58),(__mpz_struct const *)(e_acsl_57)); - e_acsl_59 = mpz_cmp((__mpz_struct const *)(e_acsl_56), - (__mpz_struct const *)(e_acsl_58)); + __gmpz_tdiv_r((__mpz_struct *)(e_acsl_56), + (__mpz_struct const *)(e_acsl_51), + (__mpz_struct const *)(e_acsl_53)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_57),(long)1); + __gmpz_init((__mpz_struct *)(e_acsl_58)); + __gmpz_neg((__mpz_struct *)(e_acsl_58),(__mpz_struct const *)(e_acsl_57)); + e_acsl_59 = __gmpz_cmp((__mpz_struct const *)(e_acsl_56), + (__mpz_struct const *)(e_acsl_58)); if (! (e_acsl_59 == 0)) { e_acsl_fail((char *)"(-3%-2 == -1)"); } - mpz_clear((__mpz_struct *)(e_acsl_50)); - mpz_clear((__mpz_struct *)(e_acsl_51)); - mpz_clear((__mpz_struct *)(e_acsl_52)); - mpz_clear((__mpz_struct *)(e_acsl_53)); - mpz_clear((__mpz_struct *)(e_acsl_54)); - mpz_clear((__mpz_struct *)(e_acsl_56)); - mpz_clear((__mpz_struct *)(e_acsl_57)); - mpz_clear((__mpz_struct *)(e_acsl_58)); + __gmpz_clear((__mpz_struct *)(e_acsl_50)); + __gmpz_clear((__mpz_struct *)(e_acsl_51)); + __gmpz_clear((__mpz_struct *)(e_acsl_52)); + __gmpz_clear((__mpz_struct *)(e_acsl_53)); + __gmpz_clear((__mpz_struct *)(e_acsl_54)); + __gmpz_clear((__mpz_struct *)(e_acsl_56)); + __gmpz_clear((__mpz_struct *)(e_acsl_57)); + __gmpz_clear((__mpz_struct *)(e_acsl_58)); } /*@ assert 3%-2 ≡ 1; */ ; @@ -1182,28 +1186,29 @@ int main(void) mpz_t e_acsl_65; mpz_t e_acsl_66; int e_acsl_67; - mpz_init_set_si((__mpz_struct *)(e_acsl_60),(long)3); - mpz_init_set_si((__mpz_struct *)(e_acsl_61),(long)2); - mpz_init((__mpz_struct *)(e_acsl_62)); - mpz_neg((__mpz_struct *)(e_acsl_62),(__mpz_struct const *)(e_acsl_61)); - mpz_init_set_si((__mpz_struct *)(e_acsl_63),(long)0); - e_acsl_64 = mpz_cmp((__mpz_struct const *)(e_acsl_62), - (__mpz_struct const *)(e_acsl_63)); - mpz_init((__mpz_struct *)(e_acsl_65)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_60),(long)3); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_61),(long)2); + __gmpz_init((__mpz_struct *)(e_acsl_62)); + __gmpz_neg((__mpz_struct *)(e_acsl_62),(__mpz_struct const *)(e_acsl_61)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_63),(long)0); + e_acsl_64 = __gmpz_cmp((__mpz_struct const *)(e_acsl_62), + (__mpz_struct const *)(e_acsl_63)); + __gmpz_init((__mpz_struct *)(e_acsl_65)); /*@ assert -2 ≢ 0; */ ; if (e_acsl_64 == 0) { e_acsl_fail((char *)"(-2 == 0)"); } - mpz_tdiv_r((__mpz_struct *)(e_acsl_65),(__mpz_struct const *)(e_acsl_60), - (__mpz_struct const *)(e_acsl_62)); - mpz_init_set_si((__mpz_struct *)(e_acsl_66),(long)1); - e_acsl_67 = mpz_cmp((__mpz_struct const *)(e_acsl_65), - (__mpz_struct const *)(e_acsl_66)); + __gmpz_tdiv_r((__mpz_struct *)(e_acsl_65), + (__mpz_struct const *)(e_acsl_60), + (__mpz_struct const *)(e_acsl_62)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_66),(long)1); + e_acsl_67 = __gmpz_cmp((__mpz_struct const *)(e_acsl_65), + (__mpz_struct const *)(e_acsl_66)); if (! (e_acsl_67 == 0)) { e_acsl_fail((char *)"(3%-2 == 1)"); } - mpz_clear((__mpz_struct *)(e_acsl_60)); - mpz_clear((__mpz_struct *)(e_acsl_61)); - mpz_clear((__mpz_struct *)(e_acsl_62)); - mpz_clear((__mpz_struct *)(e_acsl_63)); - mpz_clear((__mpz_struct *)(e_acsl_65)); - mpz_clear((__mpz_struct *)(e_acsl_66)); + __gmpz_clear((__mpz_struct *)(e_acsl_60)); + __gmpz_clear((__mpz_struct *)(e_acsl_61)); + __gmpz_clear((__mpz_struct *)(e_acsl_62)); + __gmpz_clear((__mpz_struct *)(e_acsl_63)); + __gmpz_clear((__mpz_struct *)(e_acsl_65)); + __gmpz_clear((__mpz_struct *)(e_acsl_66)); } /*@ assert ((x*2+(3+y))-4)+(x-y) ≡ -10; */ ; @@ -1222,50 +1227,50 @@ int main(void) mpz_t e_acsl_79; mpz_t e_acsl_80; int e_acsl_81; - mpz_init_set_si((__mpz_struct *)(e_acsl_68),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_69),(long)2); - mpz_init((__mpz_struct *)(e_acsl_70)); - mpz_mul((__mpz_struct *)(e_acsl_70),(__mpz_struct const *)(e_acsl_68), - (__mpz_struct const *)(e_acsl_69)); - mpz_init_set_si((__mpz_struct *)(e_acsl_71),(long)3); - mpz_init_set_si((__mpz_struct *)(e_acsl_72),(long)y); - mpz_init((__mpz_struct *)(e_acsl_73)); - mpz_add((__mpz_struct *)(e_acsl_73),(__mpz_struct const *)(e_acsl_71), - (__mpz_struct const *)(e_acsl_72)); - mpz_init((__mpz_struct *)(e_acsl_74)); - mpz_add((__mpz_struct *)(e_acsl_74),(__mpz_struct const *)(e_acsl_70), - (__mpz_struct const *)(e_acsl_73)); - mpz_init_set_si((__mpz_struct *)(e_acsl_75),(long)4); - mpz_init((__mpz_struct *)(e_acsl_76)); - mpz_sub((__mpz_struct *)(e_acsl_76),(__mpz_struct const *)(e_acsl_74), - (__mpz_struct const *)(e_acsl_75)); - mpz_init((__mpz_struct *)(e_acsl_77)); - mpz_sub((__mpz_struct *)(e_acsl_77),(__mpz_struct const *)(e_acsl_68), - (__mpz_struct const *)(e_acsl_72)); - mpz_init((__mpz_struct *)(e_acsl_78)); - mpz_add((__mpz_struct *)(e_acsl_78),(__mpz_struct const *)(e_acsl_76), - (__mpz_struct const *)(e_acsl_77)); - mpz_init_set_si((__mpz_struct *)(e_acsl_79),(long)10); - mpz_init((__mpz_struct *)(e_acsl_80)); - mpz_neg((__mpz_struct *)(e_acsl_80),(__mpz_struct const *)(e_acsl_79)); - e_acsl_81 = mpz_cmp((__mpz_struct const *)(e_acsl_78), - (__mpz_struct const *)(e_acsl_80)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_68),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_69),(long)2); + __gmpz_init((__mpz_struct *)(e_acsl_70)); + __gmpz_mul((__mpz_struct *)(e_acsl_70),(__mpz_struct const *)(e_acsl_68), + (__mpz_struct const *)(e_acsl_69)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_71),(long)3); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_72),(long)y); + __gmpz_init((__mpz_struct *)(e_acsl_73)); + __gmpz_add((__mpz_struct *)(e_acsl_73),(__mpz_struct const *)(e_acsl_71), + (__mpz_struct const *)(e_acsl_72)); + __gmpz_init((__mpz_struct *)(e_acsl_74)); + __gmpz_add((__mpz_struct *)(e_acsl_74),(__mpz_struct const *)(e_acsl_70), + (__mpz_struct const *)(e_acsl_73)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_75),(long)4); + __gmpz_init((__mpz_struct *)(e_acsl_76)); + __gmpz_sub((__mpz_struct *)(e_acsl_76),(__mpz_struct const *)(e_acsl_74), + (__mpz_struct const *)(e_acsl_75)); + __gmpz_init((__mpz_struct *)(e_acsl_77)); + __gmpz_sub((__mpz_struct *)(e_acsl_77),(__mpz_struct const *)(e_acsl_68), + (__mpz_struct const *)(e_acsl_72)); + __gmpz_init((__mpz_struct *)(e_acsl_78)); + __gmpz_add((__mpz_struct *)(e_acsl_78),(__mpz_struct const *)(e_acsl_76), + (__mpz_struct const *)(e_acsl_77)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_79),(long)10); + __gmpz_init((__mpz_struct *)(e_acsl_80)); + __gmpz_neg((__mpz_struct *)(e_acsl_80),(__mpz_struct const *)(e_acsl_79)); + e_acsl_81 = __gmpz_cmp((__mpz_struct const *)(e_acsl_78), + (__mpz_struct const *)(e_acsl_80)); if (! (e_acsl_81 == 0)) { e_acsl_fail((char *)"(((x*2+(3+y))-4)+(x-y) == -10)"); } - mpz_clear((__mpz_struct *)(e_acsl_68)); - mpz_clear((__mpz_struct *)(e_acsl_69)); - mpz_clear((__mpz_struct *)(e_acsl_70)); - mpz_clear((__mpz_struct *)(e_acsl_71)); - mpz_clear((__mpz_struct *)(e_acsl_72)); - mpz_clear((__mpz_struct *)(e_acsl_73)); - mpz_clear((__mpz_struct *)(e_acsl_74)); - mpz_clear((__mpz_struct *)(e_acsl_75)); - mpz_clear((__mpz_struct *)(e_acsl_76)); - mpz_clear((__mpz_struct *)(e_acsl_77)); - mpz_clear((__mpz_struct *)(e_acsl_78)); - mpz_clear((__mpz_struct *)(e_acsl_79)); - mpz_clear((__mpz_struct *)(e_acsl_80)); + __gmpz_clear((__mpz_struct *)(e_acsl_68)); + __gmpz_clear((__mpz_struct *)(e_acsl_69)); + __gmpz_clear((__mpz_struct *)(e_acsl_70)); + __gmpz_clear((__mpz_struct *)(e_acsl_71)); + __gmpz_clear((__mpz_struct *)(e_acsl_72)); + __gmpz_clear((__mpz_struct *)(e_acsl_73)); + __gmpz_clear((__mpz_struct *)(e_acsl_74)); + __gmpz_clear((__mpz_struct *)(e_acsl_75)); + __gmpz_clear((__mpz_struct *)(e_acsl_76)); + __gmpz_clear((__mpz_struct *)(e_acsl_77)); + __gmpz_clear((__mpz_struct *)(e_acsl_78)); + __gmpz_clear((__mpz_struct *)(e_acsl_79)); + __gmpz_clear((__mpz_struct *)(e_acsl_80)); } /*@ assert (0≡1) ≡ !(0≡0); */ ; @@ -1278,18 +1283,18 @@ int main(void) mpz_t e_acsl_83; mpz_t e_acsl_84; int e_acsl_85; - mpz_init_set_si((__mpz_struct *)(e_acsl_82),(long)0); - mpz_init_set_si((__mpz_struct *)(e_acsl_83),(long)1); - mpz_init((__mpz_struct *)(e_acsl_84)); - mpz_neg((__mpz_struct *)(e_acsl_84),(__mpz_struct const *)(e_acsl_83)); - e_acsl_85 = mpz_cmp((__mpz_struct const *)(e_acsl_82), - (__mpz_struct const *)(e_acsl_84)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_82),(long)0); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_83),(long)1); + __gmpz_init((__mpz_struct *)(e_acsl_84)); + __gmpz_neg((__mpz_struct *)(e_acsl_84),(__mpz_struct const *)(e_acsl_83)); + e_acsl_85 = __gmpz_cmp((__mpz_struct const *)(e_acsl_82), + (__mpz_struct const *)(e_acsl_84)); if (! ((e_acsl_85 <= 0) == (0 > 0))) { e_acsl_fail((char *)"((0<=-1) == (0>0))"); } - mpz_clear((__mpz_struct *)(e_acsl_82)); - mpz_clear((__mpz_struct *)(e_acsl_83)); - mpz_clear((__mpz_struct *)(e_acsl_84)); + __gmpz_clear((__mpz_struct *)(e_acsl_82)); + __gmpz_clear((__mpz_struct *)(e_acsl_83)); + __gmpz_clear((__mpz_struct *)(e_acsl_84)); } /*@ assert (0≥-1) ≡ (0≤0); */ ; @@ -1298,18 +1303,18 @@ int main(void) mpz_t e_acsl_87; mpz_t e_acsl_88; int e_acsl_89; - mpz_init_set_si((__mpz_struct *)(e_acsl_86),(long)0); - mpz_init_set_si((__mpz_struct *)(e_acsl_87),(long)1); - mpz_init((__mpz_struct *)(e_acsl_88)); - mpz_neg((__mpz_struct *)(e_acsl_88),(__mpz_struct const *)(e_acsl_87)); - e_acsl_89 = mpz_cmp((__mpz_struct const *)(e_acsl_86), - (__mpz_struct const *)(e_acsl_88)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_86),(long)0); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_87),(long)1); + __gmpz_init((__mpz_struct *)(e_acsl_88)); + __gmpz_neg((__mpz_struct *)(e_acsl_88),(__mpz_struct const *)(e_acsl_87)); + e_acsl_89 = __gmpz_cmp((__mpz_struct const *)(e_acsl_86), + (__mpz_struct const *)(e_acsl_88)); if (! ((e_acsl_89 >= 0) == (0 <= 0))) { e_acsl_fail((char *)"((0>=-1) == (0<=0))"); } - mpz_clear((__mpz_struct *)(e_acsl_86)); - mpz_clear((__mpz_struct *)(e_acsl_87)); - mpz_clear((__mpz_struct *)(e_acsl_88)); + __gmpz_clear((__mpz_struct *)(e_acsl_86)); + __gmpz_clear((__mpz_struct *)(e_acsl_87)); + __gmpz_clear((__mpz_struct *)(e_acsl_88)); } /*@ assert (0≢1) ≡ !(0≢0); */ ; diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/at.res.oracle b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/at.res.oracle index a167a416e324980c98d827d341d2a2f8ad615d2f..0b57da4f8feb6c582fec30b67f2f094a51cd40c0 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/at.res.oracle +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/at.res.oracle @@ -9,49 +9,49 @@ tests/e-acsl-runtime/at.i:33:[e-acsl] warning: missing guard for ensuring that p [value] Initial state computed [value] Values of globals at initialization A ∈ {0} -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:291. -PROJECT_FILE.i:33:[value] Function mpz_init_set_si: postcondition got status valid. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +PROJECT_FILE.i:33:[value] Function __gmpz_init_set_si: postcondition got status valid. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:292. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:293. -PROJECT_FILE.i:21:[value] Function mpz_init: postcondition got status valid. -[value] Done for function mpz_init -[value] computing for function mpz_add <- main. +PROJECT_FILE.i:21:[value] Function __gmpz_init: postcondition got status valid. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_add <- main. Called from PROJECT_FILE.i:294. -PROJECT_FILE.i:64:[value] Function mpz_add: precondition got status valid. -PROJECT_FILE.i:65:[value] Function mpz_add: precondition got status valid. -PROJECT_FILE.i:66:[value] Function mpz_add: precondition got status valid. -[value] Done for function mpz_add -[value] computing for function mpz_init_set <- main. +PROJECT_FILE.i:64:[value] Function __gmpz_add: precondition got status valid. +PROJECT_FILE.i:65:[value] Function __gmpz_add: precondition got status valid. +PROJECT_FILE.i:66:[value] Function __gmpz_add: precondition got status valid. +[value] Done for function __gmpz_add +[value] computing for function __gmpz_init_set <- main. Called from PROJECT_FILE.i:295. -PROJECT_FILE.i:25:[value] Function mpz_init_set: postcondition got status valid. -[value] Done for function mpz_init_set -[value] computing for function mpz_clear <- main. +PROJECT_FILE.i:25:[value] Function __gmpz_init_set: postcondition got status valid. +[value] Done for function __gmpz_init_set +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:296. -PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +PROJECT_FILE.i:43:[value] Function __gmpz_clear: precondition got status valid. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:297. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:298. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:302:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:307. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:308. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:309. -PROJECT_FILE.i:49:[value] Function mpz_cmp: precondition got status valid. -PROJECT_FILE.i:50:[value] Function mpz_cmp: precondition got status valid. -[value] Done for function mpz_cmp +PROJECT_FILE.i:49:[value] Function __gmpz_cmp: precondition got status valid. +PROJECT_FILE.i:50:[value] Function __gmpz_cmp: precondition got status valid. +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:310. [value] computing for function printf <- e_acsl_fail <- main. @@ -63,24 +63,24 @@ PROJECT_FILE.i:119:[value] Function exit: postcondition got status invalid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:311. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:312. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] computing for function f <- main. Called from PROJECT_FILE.i:318. PROJECT_FILE.i:148:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- f <- main. +[value] computing for function __gmpz_init_set_si <- f <- main. Called from PROJECT_FILE.i:153. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- f <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- f <- main. Called from PROJECT_FILE.i:154. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- f <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- f <- main. Called from PROJECT_FILE.i:155. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- f <- main. Called from PROJECT_FILE.i:156. [value] computing for function printf <- e_acsl_fail <- f <- main. @@ -91,22 +91,22 @@ PROJECT_FILE.i:148:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- f <- main. +[value] computing for function __gmpz_clear <- f <- main. Called from PROJECT_FILE.i:157. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- f <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- f <- main. Called from PROJECT_FILE.i:158. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:162:[value] Assertion got status unknown. -[value] computing for function mpz_init_set_si <- f <- main. +[value] computing for function __gmpz_init_set_si <- f <- main. Called from PROJECT_FILE.i:167. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- f <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- f <- main. Called from PROJECT_FILE.i:168. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- f <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- f <- main. Called from PROJECT_FILE.i:169. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- f <- main. Called from PROJECT_FILE.i:170. [value] computing for function printf <- e_acsl_fail <- f <- main. @@ -117,22 +117,22 @@ PROJECT_FILE.i:162:[value] Assertion got status unknown. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- f <- main. +[value] computing for function __gmpz_clear <- f <- main. Called from PROJECT_FILE.i:171. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- f <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- f <- main. Called from PROJECT_FILE.i:172. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:176:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- f <- main. +[value] computing for function __gmpz_init_set_si <- f <- main. Called from PROJECT_FILE.i:182. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- f <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- f <- main. Called from PROJECT_FILE.i:183. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- f <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- f <- main. Called from PROJECT_FILE.i:184. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- f <- main. Called from PROJECT_FILE.i:185. [value] computing for function printf <- e_acsl_fail <- f <- main. @@ -143,22 +143,22 @@ PROJECT_FILE.i:176:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- f <- main. +[value] computing for function __gmpz_clear <- f <- main. Called from PROJECT_FILE.i:186. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- f <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- f <- main. Called from PROJECT_FILE.i:187. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:191:[value] Assertion got status unknown. -[value] computing for function mpz_init_set_si <- f <- main. +[value] computing for function __gmpz_init_set_si <- f <- main. Called from PROJECT_FILE.i:196. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- f <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- f <- main. Called from PROJECT_FILE.i:197. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- f <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- f <- main. Called from PROJECT_FILE.i:198. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- f <- main. Called from PROJECT_FILE.i:199. [value] computing for function printf <- e_acsl_fail <- f <- main. @@ -169,21 +169,21 @@ PROJECT_FILE.i:191:[value] Assertion got status unknown. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- f <- main. +[value] computing for function __gmpz_clear <- f <- main. Called from PROJECT_FILE.i:200. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- f <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- f <- main. Called from PROJECT_FILE.i:201. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- f <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- f <- main. Called from PROJECT_FILE.i:211. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- f <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- f <- main. Called from PROJECT_FILE.i:212. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- f <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- f <- main. Called from PROJECT_FILE.i:213. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- f <- main. Called from PROJECT_FILE.i:214. [value] computing for function printf <- e_acsl_fail <- f <- main. @@ -194,25 +194,25 @@ PROJECT_FILE.i:191:[value] Assertion got status unknown. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- f <- main. +[value] computing for function __gmpz_clear <- f <- main. Called from PROJECT_FILE.i:215. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- f <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- f <- main. Called from PROJECT_FILE.i:216. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:132:[value] Function f: postcondition got status valid. [value] Recording results for f [value] Done for function f PROJECT_FILE.i:319:[value] Assertion got status unknown. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:324. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:325. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:326. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:327. [value] computing for function printf <- e_acsl_fail <- main. @@ -223,19 +223,19 @@ PROJECT_FILE.i:319:[value] Assertion got status unknown. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:328. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:329. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:333:[value] Assertion got status unknown. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:337. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:338. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:339. [value] computing for function printf <- e_acsl_fail <- main. @@ -246,25 +246,25 @@ PROJECT_FILE.i:333:[value] Assertion got status unknown. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:340. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:344:[value] Assertion got status unknown. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:350. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:351. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:352. -[value] Done for function mpz_init -[value] computing for function mpz_add <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_add <- main. Called from PROJECT_FILE.i:353. -[value] Done for function mpz_add -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_add +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:354. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:355. [value] computing for function printf <- e_acsl_fail <- main. @@ -275,27 +275,27 @@ PROJECT_FILE.i:344:[value] Assertion got status unknown. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:356. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:357. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:358. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] computing for function g <- main. Called from PROJECT_FILE.i:362. PROJECT_FILE.i:240:[value] Assertion got status unknown. -[value] computing for function mpz_init_set_si <- g <- main. +[value] computing for function __gmpz_init_set_si <- g <- main. Called from PROJECT_FILE.i:245. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- g <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- g <- main. Called from PROJECT_FILE.i:246. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- g <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- g <- main. Called from PROJECT_FILE.i:247. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- g <- main. Called from PROJECT_FILE.i:248. [value] computing for function printf <- e_acsl_fail <- g <- main. @@ -306,22 +306,22 @@ PROJECT_FILE.i:240:[value] Assertion got status unknown. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- g <- main. +[value] computing for function __gmpz_clear <- g <- main. Called from PROJECT_FILE.i:250. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- g <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- g <- main. Called from PROJECT_FILE.i:251. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:256:[value] Assertion got status unknown. -[value] computing for function mpz_init_set_si <- g <- main. +[value] computing for function __gmpz_init_set_si <- g <- main. Called from PROJECT_FILE.i:262. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- g <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- g <- main. Called from PROJECT_FILE.i:263. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- g <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- g <- main. Called from PROJECT_FILE.i:264. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- g <- main. Called from PROJECT_FILE.i:266. [value] computing for function printf <- e_acsl_fail <- g <- main. @@ -332,17 +332,17 @@ PROJECT_FILE.i:256:[value] Assertion got status unknown. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- g <- main. +[value] computing for function __gmpz_clear <- g <- main. Called from PROJECT_FILE.i:268. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- g <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- g <- main. Called from PROJECT_FILE.i:269. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] Recording results for g [value] Done for function g -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:364. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] Recording results for main [value] done for function main [value] ====== VALUES COMPUTED ====== @@ -384,31 +384,31 @@ typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; /*@ ensures \valid(\old(x)); assigns *x; */ -extern void mpz_init(__mpz_struct * /*[1]*/ x); +extern void __gmpz_init(__mpz_struct * /*[1]*/ x); /*@ ensures \valid(\old(z)); assigns *z; */ -extern void mpz_init_set(__mpz_struct * /*[1]*/ z, - __mpz_struct const * /*[1]*/ z_orig); +extern void __gmpz_init_set(__mpz_struct * /*[1]*/ z, + __mpz_struct const * /*[1]*/ z_orig); /*@ ensures \valid(\old(z)); assigns *z; assigns *z \from n; */ -extern void mpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); +extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); /*@ requires \valid(x); assigns *x; */ -extern void mpz_clear(__mpz_struct * /*[1]*/ x); +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); assigns \nothing; */ -extern int mpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ requires \valid(z1); requires \valid(z2); requires \valid(z3); assigns *z1; */ -extern void mpz_add(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); +extern void __gmpz_add(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2, + __mpz_struct const * /*[1]*/ z3); /*@ terminates \false; ensures \false; assigns \nothing; */ @@ -443,13 +443,13 @@ void f(void) mpz_t e_acsl_2; mpz_t e_acsl_3; int e_acsl_4; - mpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)e_acsl_1); - mpz_init_set_si((__mpz_struct *)(e_acsl_3),(long)0); - e_acsl_4 = mpz_cmp((__mpz_struct const *)(e_acsl_2), - (__mpz_struct const *)(e_acsl_3)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)e_acsl_1); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_3),(long)0); + e_acsl_4 = __gmpz_cmp((__mpz_struct const *)(e_acsl_2), + (__mpz_struct const *)(e_acsl_3)); if (! (e_acsl_4 == 0)) { e_acsl_fail((char *)"(\\at(A,Pre) == 0)"); } - mpz_clear((__mpz_struct *)(e_acsl_2)); - mpz_clear((__mpz_struct *)(e_acsl_3)); + __gmpz_clear((__mpz_struct *)(e_acsl_2)); + __gmpz_clear((__mpz_struct *)(e_acsl_3)); } /*@ assert \at(A,F) ≡ 1; */ ; @@ -457,13 +457,13 @@ void f(void) mpz_t e_acsl_6; mpz_t e_acsl_7; int e_acsl_8; - mpz_init_set_si((__mpz_struct *)(e_acsl_6),(long)e_acsl_5); - mpz_init_set_si((__mpz_struct *)(e_acsl_7),(long)1); - e_acsl_8 = mpz_cmp((__mpz_struct const *)(e_acsl_6), - (__mpz_struct const *)(e_acsl_7)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_6),(long)e_acsl_5); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_7),(long)1); + e_acsl_8 = __gmpz_cmp((__mpz_struct const *)(e_acsl_6), + (__mpz_struct const *)(e_acsl_7)); if (! (e_acsl_8 == 0)) { e_acsl_fail((char *)"(\\at(A,F) == 1)"); } - mpz_clear((__mpz_struct *)(e_acsl_6)); - mpz_clear((__mpz_struct *)(e_acsl_7)); + __gmpz_clear((__mpz_struct *)(e_acsl_6)); + __gmpz_clear((__mpz_struct *)(e_acsl_7)); } /*@ assert \at(A,Here) ≡ 2; */ ; @@ -472,13 +472,13 @@ void f(void) mpz_t e_acsl_11; int e_acsl_12; e_acsl_9 = A; - mpz_init_set_si((__mpz_struct *)(e_acsl_10),(long)e_acsl_9); - mpz_init_set_si((__mpz_struct *)(e_acsl_11),(long)2); - e_acsl_12 = mpz_cmp((__mpz_struct const *)(e_acsl_10), - (__mpz_struct const *)(e_acsl_11)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_10),(long)e_acsl_9); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_11),(long)2); + e_acsl_12 = __gmpz_cmp((__mpz_struct const *)(e_acsl_10), + (__mpz_struct const *)(e_acsl_11)); if (! (e_acsl_12 == 0)) { e_acsl_fail((char *)"(\\at(A,Here) == 2)"); } - mpz_clear((__mpz_struct *)(e_acsl_10)); - mpz_clear((__mpz_struct *)(e_acsl_11)); + __gmpz_clear((__mpz_struct *)(e_acsl_10)); + __gmpz_clear((__mpz_struct *)(e_acsl_11)); } /*@ assert \at(\at(A,Pre),F) ≡ 0; */ ; @@ -486,15 +486,15 @@ void f(void) mpz_t e_acsl_15; mpz_t e_acsl_16; int e_acsl_17; - mpz_init_set_si((__mpz_struct *)(e_acsl_15),(long)e_acsl_14); - mpz_init_set_si((__mpz_struct *)(e_acsl_16),(long)0); - e_acsl_17 = mpz_cmp((__mpz_struct const *)(e_acsl_15), - (__mpz_struct const *)(e_acsl_16)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_15),(long)e_acsl_14); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_16),(long)0); + e_acsl_17 = __gmpz_cmp((__mpz_struct const *)(e_acsl_15), + (__mpz_struct const *)(e_acsl_16)); if (! (e_acsl_17 == 0)) { e_acsl_fail((char *)"(\\at(\\at(A,Pre),F) == 0)"); } - mpz_clear((__mpz_struct *)(e_acsl_15)); - mpz_clear((__mpz_struct *)(e_acsl_16)); + __gmpz_clear((__mpz_struct *)(e_acsl_15)); + __gmpz_clear((__mpz_struct *)(e_acsl_16)); } A = 3; @@ -503,13 +503,13 @@ void f(void) mpz_t e_acsl_20; int e_acsl_21; e_acsl_18 = A; - mpz_init_set_si((__mpz_struct *)(e_acsl_19),(long)e_acsl_18); - mpz_init_set_si((__mpz_struct *)(e_acsl_20),(long)3); - e_acsl_21 = mpz_cmp((__mpz_struct const *)(e_acsl_19), - (__mpz_struct const *)(e_acsl_20)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_19),(long)e_acsl_18); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_20),(long)3); + e_acsl_21 = __gmpz_cmp((__mpz_struct const *)(e_acsl_19), + (__mpz_struct const *)(e_acsl_20)); if (! (e_acsl_21 == 0)) { e_acsl_fail((char *)"(\\at(A,Post) == 3)"); } - mpz_clear((__mpz_struct *)(e_acsl_19)); - mpz_clear((__mpz_struct *)(e_acsl_20)); + __gmpz_clear((__mpz_struct *)(e_acsl_19)); + __gmpz_clear((__mpz_struct *)(e_acsl_20)); return; } @@ -536,15 +536,15 @@ void g(int *p, int *q) mpz_t e_acsl_3; mpz_t e_acsl_4; int e_acsl_5; - mpz_init_set_si((__mpz_struct *)(e_acsl_3),(long)e_acsl_2); - mpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)2); - e_acsl_5 = mpz_cmp((__mpz_struct const *)(e_acsl_3), - (__mpz_struct const *)(e_acsl_4)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_3),(long)e_acsl_2); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)2); + e_acsl_5 = __gmpz_cmp((__mpz_struct const *)(e_acsl_3), + (__mpz_struct const *)(e_acsl_4)); if (! (e_acsl_5 == 0)) { e_acsl_fail((char *)"(\\at(*(p+\\at(*q,L1)),L2) == 2)"); } - mpz_clear((__mpz_struct *)(e_acsl_3)); - mpz_clear((__mpz_struct *)(e_acsl_4)); + __gmpz_clear((__mpz_struct *)(e_acsl_3)); + __gmpz_clear((__mpz_struct *)(e_acsl_4)); } L3: @@ -554,15 +554,15 @@ void g(int *p, int *q) mpz_t e_acsl_9; int e_acsl_10; e_acsl_7 = *(p + e_acsl_6); - mpz_init_set_si((__mpz_struct *)(e_acsl_8),(long)e_acsl_7); - mpz_init_set_si((__mpz_struct *)(e_acsl_9),(long)2); - e_acsl_10 = mpz_cmp((__mpz_struct const *)(e_acsl_8), - (__mpz_struct const *)(e_acsl_9)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_8),(long)e_acsl_7); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_9),(long)2); + e_acsl_10 = __gmpz_cmp((__mpz_struct const *)(e_acsl_8), + (__mpz_struct const *)(e_acsl_9)); if (! (e_acsl_10 == 0)) { e_acsl_fail((char *)"(\\at(*(p+\\at(*q,L1)),Here) == 2)"); } - mpz_clear((__mpz_struct *)(e_acsl_8)); - mpz_clear((__mpz_struct *)(e_acsl_9)); + __gmpz_clear((__mpz_struct *)(e_acsl_8)); + __gmpz_clear((__mpz_struct *)(e_acsl_9)); } return; @@ -582,16 +582,16 @@ int main(void) mpz_t e_acsl_8; mpz_t e_acsl_9; mpz_t e_acsl_10; - mpz_init_set_si((__mpz_struct *)(e_acsl_8),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_9),(long)1); - mpz_init((__mpz_struct *)(e_acsl_10)); - mpz_add((__mpz_struct *)(e_acsl_10),(__mpz_struct const *)(e_acsl_8), - (__mpz_struct const *)(e_acsl_9)); - mpz_init_set((__mpz_struct *)(e_acsl_11), - (__mpz_struct const *)(e_acsl_10)); - mpz_clear((__mpz_struct *)(e_acsl_8)); - mpz_clear((__mpz_struct *)(e_acsl_9)); - mpz_clear((__mpz_struct *)(e_acsl_10)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_8),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_9),(long)1); + __gmpz_init((__mpz_struct *)(e_acsl_10)); + __gmpz_add((__mpz_struct *)(e_acsl_10),(__mpz_struct const *)(e_acsl_8), + (__mpz_struct const *)(e_acsl_9)); + __gmpz_init_set((__mpz_struct *)(e_acsl_11), + (__mpz_struct const *)(e_acsl_10)); + __gmpz_clear((__mpz_struct *)(e_acsl_8)); + __gmpz_clear((__mpz_struct *)(e_acsl_9)); + __gmpz_clear((__mpz_struct *)(e_acsl_10)); } e_acsl_4 = x; @@ -600,13 +600,13 @@ int main(void) mpz_t e_acsl_1; mpz_t e_acsl_2; int e_acsl_3; - mpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)0); - e_acsl_3 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_2)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)0); + e_acsl_3 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_2)); if (! (e_acsl_3 == 0)) { e_acsl_fail((char *)"(x == 0)"); } - mpz_clear((__mpz_struct *)(e_acsl_1)); - mpz_clear((__mpz_struct *)(e_acsl_2)); + __gmpz_clear((__mpz_struct *)(e_acsl_1)); + __gmpz_clear((__mpz_struct *)(e_acsl_2)); } x = 1; @@ -617,24 +617,24 @@ int main(void) mpz_t e_acsl_5; mpz_t e_acsl_6; int e_acsl_7; - mpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)e_acsl_4); - mpz_init_set_si((__mpz_struct *)(e_acsl_6),(long)0); - e_acsl_7 = mpz_cmp((__mpz_struct const *)(e_acsl_5), - (__mpz_struct const *)(e_acsl_6)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)e_acsl_4); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_6),(long)0); + e_acsl_7 = __gmpz_cmp((__mpz_struct const *)(e_acsl_5), + (__mpz_struct const *)(e_acsl_6)); if (! (e_acsl_7 == 0)) { e_acsl_fail((char *)"(\\at(x,L) == 0)"); } - mpz_clear((__mpz_struct *)(e_acsl_5)); - mpz_clear((__mpz_struct *)(e_acsl_6)); + __gmpz_clear((__mpz_struct *)(e_acsl_5)); + __gmpz_clear((__mpz_struct *)(e_acsl_6)); } /*@ assert \at(x+1,L) ≡ 1; */ ; { mpz_t e_acsl_12; int e_acsl_13; - mpz_init_set_si((__mpz_struct *)(e_acsl_12),(long)1); - e_acsl_13 = mpz_cmp((__mpz_struct const *)(e_acsl_11), - (__mpz_struct const *)(e_acsl_12)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_12),(long)1); + e_acsl_13 = __gmpz_cmp((__mpz_struct const *)(e_acsl_11), + (__mpz_struct const *)(e_acsl_12)); if (! (e_acsl_13 == 0)) { e_acsl_fail((char *)"(\\at(x+1,L) == 1)"); } - mpz_clear((__mpz_struct *)(e_acsl_12)); + __gmpz_clear((__mpz_struct *)(e_acsl_12)); } /*@ assert \at(x,L)+1 ≡ 1; */ ; @@ -643,22 +643,22 @@ int main(void) mpz_t e_acsl_16; mpz_t e_acsl_17; int e_acsl_18; - mpz_init_set_si((__mpz_struct *)(e_acsl_15),(long)e_acsl_14); - mpz_init_set_si((__mpz_struct *)(e_acsl_16),(long)1); - mpz_init((__mpz_struct *)(e_acsl_17)); - mpz_add((__mpz_struct *)(e_acsl_17),(__mpz_struct const *)(e_acsl_15), - (__mpz_struct const *)(e_acsl_16)); - e_acsl_18 = mpz_cmp((__mpz_struct const *)(e_acsl_17), - (__mpz_struct const *)(e_acsl_16)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_15),(long)e_acsl_14); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_16),(long)1); + __gmpz_init((__mpz_struct *)(e_acsl_17)); + __gmpz_add((__mpz_struct *)(e_acsl_17),(__mpz_struct const *)(e_acsl_15), + (__mpz_struct const *)(e_acsl_16)); + e_acsl_18 = __gmpz_cmp((__mpz_struct const *)(e_acsl_17), + (__mpz_struct const *)(e_acsl_16)); if (! (e_acsl_18 == 0)) { e_acsl_fail((char *)"(\\at(x,L)+1 == 1)"); } - mpz_clear((__mpz_struct *)(e_acsl_15)); - mpz_clear((__mpz_struct *)(e_acsl_16)); - mpz_clear((__mpz_struct *)(e_acsl_17)); + __gmpz_clear((__mpz_struct *)(e_acsl_15)); + __gmpz_clear((__mpz_struct *)(e_acsl_16)); + __gmpz_clear((__mpz_struct *)(e_acsl_17)); } g(t,& x); __retres = 0; - mpz_clear((__mpz_struct *)(e_acsl_11)); + __gmpz_clear((__mpz_struct *)(e_acsl_11)); return (__retres); } diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/cast.res.oracle b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/cast.res.oracle index aa0fd63006d99ae7cbd769bb66410b0f318eaa85..04fedcf0e6436a0b04d2c2b98a206799fe40588b 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/cast.res.oracle +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/cast.res.oracle @@ -5,14 +5,14 @@ tests/e-acsl-runtime/cast.i:18:[e-acsl] warning: missing guard for ensuring that [value] Initial state computed [value] Values of globals at initialization PROJECT_FILE.i:138:[value] Assertion got status valid. -[value] computing for function mpz_init_set_str <- main. +[value] computing for function __gmpz_init_set_str <- main. Called from PROJECT_FILE.i:142. -PROJECT_FILE.i:37:[value] Function mpz_init_set_str: postcondition got status valid. -[value] Done for function mpz_init_set_str -[value] computing for function mpz_get_si <- main. +PROJECT_FILE.i:37:[value] Function __gmpz_init_set_str: postcondition got status valid. +[value] Done for function __gmpz_init_set_str +[value] computing for function __gmpz_get_si <- main. Called from PROJECT_FILE.i:143. -PROJECT_FILE.i:96:[value] Function mpz_get_si: precondition got status valid. -[value] Done for function mpz_get_si +PROJECT_FILE.i:96:[value] Function __gmpz_get_si: precondition got status valid. +[value] Done for function __gmpz_get_si [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:144. [value] computing for function printf <- e_acsl_fail <- main. @@ -24,18 +24,18 @@ PROJECT_FILE.i:119:[value] Function exit: postcondition got status invalid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:145. -PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. -[value] Done for function mpz_clear +PROJECT_FILE.i:43:[value] Function __gmpz_clear: precondition got status valid. +[value] Done for function __gmpz_clear PROJECT_FILE.i:149:[value] Assertion got status valid. -[value] computing for function mpz_init_set_str <- main. +[value] computing for function __gmpz_init_set_str <- main. Called from PROJECT_FILE.i:153. -[value] Done for function mpz_init_set_str -[value] computing for function mpz_get_ui <- main. +[value] Done for function __gmpz_init_set_str +[value] computing for function __gmpz_get_ui <- main. Called from PROJECT_FILE.i:154. -PROJECT_FILE.i:100:[value] Function mpz_get_ui: precondition got status valid. -[value] Done for function mpz_get_ui +PROJECT_FILE.i:100:[value] Function __gmpz_get_ui: precondition got status valid. +[value] Done for function __gmpz_get_ui [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:156. [value] computing for function printf <- e_acsl_fail <- main. @@ -46,9 +46,9 @@ PROJECT_FILE.i:100:[value] Function mpz_get_ui: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:158. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] Recording results for main [value] done for function main [value] ====== VALUES COMPUTED ====== @@ -68,17 +68,17 @@ typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; /*@ ensures \valid(\old(z)); assigns *z; */ -extern int mpz_init_set_str(__mpz_struct * /*[1]*/ z, char const *str, - int base); +extern int __gmpz_init_set_str(__mpz_struct * /*[1]*/ z, char const *str, + int base); /*@ requires \valid(x); assigns *x; */ -extern void mpz_clear(__mpz_struct * /*[1]*/ x); +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z); assigns \nothing; */ -extern long mpz_get_si(__mpz_struct const * /*[1]*/ z); +extern long __gmpz_get_si(__mpz_struct const * /*[1]*/ z); /*@ requires \valid(z); assigns \nothing; */ -extern unsigned long mpz_get_ui(__mpz_struct const * /*[1]*/ z); +extern unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z); /*@ terminates \false; ensures \false; assigns \nothing; */ @@ -103,24 +103,24 @@ int main(void) { mpz_t e_acsl_1; int e_acsl_2; - mpz_init_set_str((__mpz_struct *)(e_acsl_1),"1152921504606846975",10); - e_acsl_2 = (int)mpz_get_si((__mpz_struct const *)(e_acsl_1)); + __gmpz_init_set_str((__mpz_struct *)(e_acsl_1),"1152921504606846975",10); + e_acsl_2 = (int)__gmpz_get_si((__mpz_struct const *)(e_acsl_1)); if (! (y != e_acsl_2)) { e_acsl_fail((char *)"(y != (int)0xfffffffffffffff)"); } - mpz_clear((__mpz_struct *)(e_acsl_1)); + __gmpz_clear((__mpz_struct *)(e_acsl_1)); } /*@ assert (unsigned int)y ≢ (unsigned int)0xfffffffffffffff; */ ; { mpz_t e_acsl_3; unsigned int e_acsl_4; - mpz_init_set_str((__mpz_struct *)(e_acsl_3),"1152921504606846975",10); - e_acsl_4 = (unsigned int)mpz_get_ui((__mpz_struct const *)(e_acsl_3)); + __gmpz_init_set_str((__mpz_struct *)(e_acsl_3),"1152921504606846975",10); + e_acsl_4 = (unsigned int)__gmpz_get_ui((__mpz_struct const *)(e_acsl_3)); if (! ((unsigned int)y != e_acsl_4)) { e_acsl_fail((char *)"((unsigned int)y != (unsigned int)0xfffffffffffffff)"); } - mpz_clear((__mpz_struct *)(e_acsl_3)); + __gmpz_clear((__mpz_struct *)(e_acsl_3)); } __retres = 0; diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/comparison.res.oracle b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/comparison.res.oracle index 1bac2ca8dccea3d3b2ed0e98a4d1a26dcdfeaf91..edd0696c274c938329b5c6648dfba03de3dd828f 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/comparison.res.oracle +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/comparison.res.oracle @@ -5,18 +5,18 @@ PROJECT_FILE.i:139:[value] Assertion got status valid. PROJECT_FILE.i:142:[value] Assertion got status valid. PROJECT_FILE.i:145:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:150. -PROJECT_FILE.i:33:[value] Function mpz_init_set_si: postcondition got status valid. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +PROJECT_FILE.i:33:[value] Function __gmpz_init_set_si: postcondition got status valid. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:151. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:152. -PROJECT_FILE.i:49:[value] Function mpz_cmp: precondition got status valid. -PROJECT_FILE.i:50:[value] Function mpz_cmp: precondition got status valid. -[value] Done for function mpz_cmp +PROJECT_FILE.i:49:[value] Function __gmpz_cmp: precondition got status valid. +PROJECT_FILE.i:50:[value] Function __gmpz_cmp: precondition got status valid. +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:153. [value] computing for function printf <- e_acsl_fail <- main. @@ -28,23 +28,23 @@ PROJECT_FILE.i:119:[value] Function exit: postcondition got status invalid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:154. -PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +PROJECT_FILE.i:43:[value] Function __gmpz_clear: precondition got status valid. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:155. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:159:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:164. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:165. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:166. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:167. [value] computing for function printf <- e_acsl_fail <- main. @@ -55,12 +55,12 @@ PROJECT_FILE.i:159:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:168. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:169. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:174:[value] Assertion got status valid. PROJECT_FILE.i:177:[value] Assertion got status unknown. PROJECT_FILE.i:180:[value] Assertion got status valid. @@ -70,24 +70,24 @@ PROJECT_FILE.i:189:[value] Assertion got status valid. PROJECT_FILE.i:192:[value] Assertion got status valid. PROJECT_FILE.i:195:[value] Assertion got status valid. PROJECT_FILE.i:198:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:204. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:205. -PROJECT_FILE.i:21:[value] Function mpz_init: postcondition got status valid. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +PROJECT_FILE.i:21:[value] Function __gmpz_init: postcondition got status valid. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:206. -PROJECT_FILE.i:59:[value] Function mpz_neg: precondition got status valid. -PROJECT_FILE.i:60:[value] Function mpz_neg: precondition got status valid. -[value] Done for function mpz_neg -[value] computing for function mpz_init_set_si <- main. +PROJECT_FILE.i:59:[value] Function __gmpz_neg: precondition got status valid. +PROJECT_FILE.i:60:[value] Function __gmpz_neg: precondition got status valid. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:207. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:208. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:209. [value] computing for function printf <- e_acsl_fail <- main. @@ -98,31 +98,31 @@ PROJECT_FILE.i:60:[value] Function mpz_neg: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:210. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:211. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:212. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:216:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:222. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:223. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:224. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:225. -[value] Done for function mpz_neg -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:226. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:227. [value] computing for function printf <- e_acsl_fail <- main. @@ -133,31 +133,31 @@ PROJECT_FILE.i:216:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:228. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:229. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:230. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:234:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:240. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:241. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:242. -[value] Done for function mpz_neg -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:243. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:244. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:245. [value] computing for function printf <- e_acsl_fail <- main. @@ -168,31 +168,31 @@ PROJECT_FILE.i:234:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:246. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:247. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:248. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:252:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:258. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:259. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:260. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:261. -[value] Done for function mpz_neg -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:262. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:263. [value] computing for function printf <- e_acsl_fail <- main. @@ -203,28 +203,28 @@ PROJECT_FILE.i:252:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:264. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:265. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:266. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:270:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:275. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:276. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:277. -[value] Done for function mpz_neg -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:278. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:279. [value] computing for function printf <- e_acsl_fail <- main. @@ -235,28 +235,28 @@ PROJECT_FILE.i:270:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:280. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:281. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:285:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:291. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:292. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:293. -[value] Done for function mpz_init -[value] computing for function mpz_neg <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_neg <- main. Called from PROJECT_FILE.i:294. -[value] Done for function mpz_neg -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_neg +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:295. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:296. [value] computing for function printf <- e_acsl_fail <- main. @@ -267,15 +267,15 @@ PROJECT_FILE.i:285:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:297. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:298. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:299. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] Recording results for main [value] done for function main [value] ====== VALUES COMPUTED ====== @@ -296,24 +296,24 @@ typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; /*@ ensures \valid(\old(x)); assigns *x; */ -extern void mpz_init(__mpz_struct * /*[1]*/ x); +extern void __gmpz_init(__mpz_struct * /*[1]*/ x); /*@ ensures \valid(\old(z)); assigns *z; assigns *z \from n; */ -extern void mpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); +extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); /*@ requires \valid(x); assigns *x; */ -extern void mpz_clear(__mpz_struct * /*[1]*/ x); +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); assigns \nothing; */ -extern int mpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ requires \valid(z1); requires \valid(z2); assigns *z1; */ -extern void mpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); +extern void __gmpz_neg(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ terminates \false; ensures \false; assigns \nothing; */ @@ -344,13 +344,13 @@ int main(void) mpz_t e_acsl_1; mpz_t e_acsl_2; int e_acsl_3; - mpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)0); - e_acsl_3 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_2)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)0); + e_acsl_3 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_2)); if (! (e_acsl_3 <= 0)) { e_acsl_fail((char *)"(x <= 0)"); } - mpz_clear((__mpz_struct *)(e_acsl_1)); - mpz_clear((__mpz_struct *)(e_acsl_2)); + __gmpz_clear((__mpz_struct *)(e_acsl_1)); + __gmpz_clear((__mpz_struct *)(e_acsl_2)); } /*@ assert y ≥ 1; */ ; @@ -358,13 +358,13 @@ int main(void) mpz_t e_acsl_4; mpz_t e_acsl_5; int e_acsl_6; - mpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)y); - mpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)1); - e_acsl_6 = mpz_cmp((__mpz_struct const *)(e_acsl_4), - (__mpz_struct const *)(e_acsl_5)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)y); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)1); + e_acsl_6 = __gmpz_cmp((__mpz_struct const *)(e_acsl_4), + (__mpz_struct const *)(e_acsl_5)); if (! (e_acsl_6 >= 0)) { e_acsl_fail((char *)"(y >= 1)"); } - mpz_clear((__mpz_struct *)(e_acsl_4)); - mpz_clear((__mpz_struct *)(e_acsl_5)); + __gmpz_clear((__mpz_struct *)(e_acsl_4)); + __gmpz_clear((__mpz_struct *)(e_acsl_5)); } s = (char *)"toto"; @@ -391,16 +391,16 @@ int main(void) mpz_t e_acsl_8; mpz_t e_acsl_9; int e_acsl_10; - mpz_init_set_si((__mpz_struct *)(e_acsl_7),(long)5); - mpz_init((__mpz_struct *)(e_acsl_8)); - mpz_neg((__mpz_struct *)(e_acsl_8),(__mpz_struct const *)(e_acsl_7)); - mpz_init_set_si((__mpz_struct *)(e_acsl_9),(long)18); - e_acsl_10 = mpz_cmp((__mpz_struct const *)(e_acsl_8), - (__mpz_struct const *)(e_acsl_9)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_7),(long)5); + __gmpz_init((__mpz_struct *)(e_acsl_8)); + __gmpz_neg((__mpz_struct *)(e_acsl_8),(__mpz_struct const *)(e_acsl_7)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_9),(long)18); + e_acsl_10 = __gmpz_cmp((__mpz_struct const *)(e_acsl_8), + (__mpz_struct const *)(e_acsl_9)); if (! (e_acsl_10 < 0)) { e_acsl_fail((char *)"(-5 < 18)"); } - mpz_clear((__mpz_struct *)(e_acsl_7)); - mpz_clear((__mpz_struct *)(e_acsl_8)); - mpz_clear((__mpz_struct *)(e_acsl_9)); + __gmpz_clear((__mpz_struct *)(e_acsl_7)); + __gmpz_clear((__mpz_struct *)(e_acsl_8)); + __gmpz_clear((__mpz_struct *)(e_acsl_9)); } /*@ assert 32 > -3; */ ; @@ -409,16 +409,16 @@ int main(void) mpz_t e_acsl_12; mpz_t e_acsl_13; int e_acsl_14; - mpz_init_set_si((__mpz_struct *)(e_acsl_11),(long)32); - mpz_init_set_si((__mpz_struct *)(e_acsl_12),(long)3); - mpz_init((__mpz_struct *)(e_acsl_13)); - mpz_neg((__mpz_struct *)(e_acsl_13),(__mpz_struct const *)(e_acsl_12)); - e_acsl_14 = mpz_cmp((__mpz_struct const *)(e_acsl_11), - (__mpz_struct const *)(e_acsl_13)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_11),(long)32); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_12),(long)3); + __gmpz_init((__mpz_struct *)(e_acsl_13)); + __gmpz_neg((__mpz_struct *)(e_acsl_13),(__mpz_struct const *)(e_acsl_12)); + e_acsl_14 = __gmpz_cmp((__mpz_struct const *)(e_acsl_11), + (__mpz_struct const *)(e_acsl_13)); if (! (e_acsl_14 > 0)) { e_acsl_fail((char *)"(32 > -3)"); } - mpz_clear((__mpz_struct *)(e_acsl_11)); - mpz_clear((__mpz_struct *)(e_acsl_12)); - mpz_clear((__mpz_struct *)(e_acsl_13)); + __gmpz_clear((__mpz_struct *)(e_acsl_11)); + __gmpz_clear((__mpz_struct *)(e_acsl_12)); + __gmpz_clear((__mpz_struct *)(e_acsl_13)); } /*@ assert -12 ≤ 13; */ ; @@ -427,16 +427,16 @@ int main(void) mpz_t e_acsl_16; mpz_t e_acsl_17; int e_acsl_18; - mpz_init_set_si((__mpz_struct *)(e_acsl_15),(long)12); - mpz_init((__mpz_struct *)(e_acsl_16)); - mpz_neg((__mpz_struct *)(e_acsl_16),(__mpz_struct const *)(e_acsl_15)); - mpz_init_set_si((__mpz_struct *)(e_acsl_17),(long)13); - e_acsl_18 = mpz_cmp((__mpz_struct const *)(e_acsl_16), - (__mpz_struct const *)(e_acsl_17)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_15),(long)12); + __gmpz_init((__mpz_struct *)(e_acsl_16)); + __gmpz_neg((__mpz_struct *)(e_acsl_16),(__mpz_struct const *)(e_acsl_15)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_17),(long)13); + e_acsl_18 = __gmpz_cmp((__mpz_struct const *)(e_acsl_16), + (__mpz_struct const *)(e_acsl_17)); if (! (e_acsl_18 <= 0)) { e_acsl_fail((char *)"(-12 <= 13)"); } - mpz_clear((__mpz_struct *)(e_acsl_15)); - mpz_clear((__mpz_struct *)(e_acsl_16)); - mpz_clear((__mpz_struct *)(e_acsl_17)); + __gmpz_clear((__mpz_struct *)(e_acsl_15)); + __gmpz_clear((__mpz_struct *)(e_acsl_16)); + __gmpz_clear((__mpz_struct *)(e_acsl_17)); } /*@ assert 123 ≥ -12; */ ; @@ -445,16 +445,16 @@ int main(void) mpz_t e_acsl_20; mpz_t e_acsl_21; int e_acsl_22; - mpz_init_set_si((__mpz_struct *)(e_acsl_19),(long)123); - mpz_init_set_si((__mpz_struct *)(e_acsl_20),(long)12); - mpz_init((__mpz_struct *)(e_acsl_21)); - mpz_neg((__mpz_struct *)(e_acsl_21),(__mpz_struct const *)(e_acsl_20)); - e_acsl_22 = mpz_cmp((__mpz_struct const *)(e_acsl_19), - (__mpz_struct const *)(e_acsl_21)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_19),(long)123); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_20),(long)12); + __gmpz_init((__mpz_struct *)(e_acsl_21)); + __gmpz_neg((__mpz_struct *)(e_acsl_21),(__mpz_struct const *)(e_acsl_20)); + e_acsl_22 = __gmpz_cmp((__mpz_struct const *)(e_acsl_19), + (__mpz_struct const *)(e_acsl_21)); if (! (e_acsl_22 >= 0)) { e_acsl_fail((char *)"(123 >= -12)"); } - mpz_clear((__mpz_struct *)(e_acsl_19)); - mpz_clear((__mpz_struct *)(e_acsl_20)); - mpz_clear((__mpz_struct *)(e_acsl_21)); + __gmpz_clear((__mpz_struct *)(e_acsl_19)); + __gmpz_clear((__mpz_struct *)(e_acsl_20)); + __gmpz_clear((__mpz_struct *)(e_acsl_21)); } /*@ assert -0xff ≡ -0xff; */ ; @@ -462,14 +462,14 @@ int main(void) mpz_t e_acsl_23; mpz_t e_acsl_24; int e_acsl_25; - mpz_init_set_si((__mpz_struct *)(e_acsl_23),(long)0xff); - mpz_init((__mpz_struct *)(e_acsl_24)); - mpz_neg((__mpz_struct *)(e_acsl_24),(__mpz_struct const *)(e_acsl_23)); - e_acsl_25 = mpz_cmp((__mpz_struct const *)(e_acsl_24), - (__mpz_struct const *)(e_acsl_24)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_23),(long)0xff); + __gmpz_init((__mpz_struct *)(e_acsl_24)); + __gmpz_neg((__mpz_struct *)(e_acsl_24),(__mpz_struct const *)(e_acsl_23)); + e_acsl_25 = __gmpz_cmp((__mpz_struct const *)(e_acsl_24), + (__mpz_struct const *)(e_acsl_24)); if (! (e_acsl_25 == 0)) { e_acsl_fail((char *)"(-0xff == -0xff)"); } - mpz_clear((__mpz_struct *)(e_acsl_23)); - mpz_clear((__mpz_struct *)(e_acsl_24)); + __gmpz_clear((__mpz_struct *)(e_acsl_23)); + __gmpz_clear((__mpz_struct *)(e_acsl_24)); } /*@ assert 1 ≢ -2; */ ; @@ -478,16 +478,16 @@ int main(void) mpz_t e_acsl_27; mpz_t e_acsl_28; int e_acsl_29; - mpz_init_set_si((__mpz_struct *)(e_acsl_26),(long)1); - mpz_init_set_si((__mpz_struct *)(e_acsl_27),(long)2); - mpz_init((__mpz_struct *)(e_acsl_28)); - mpz_neg((__mpz_struct *)(e_acsl_28),(__mpz_struct const *)(e_acsl_27)); - e_acsl_29 = mpz_cmp((__mpz_struct const *)(e_acsl_26), - (__mpz_struct const *)(e_acsl_28)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_26),(long)1); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_27),(long)2); + __gmpz_init((__mpz_struct *)(e_acsl_28)); + __gmpz_neg((__mpz_struct *)(e_acsl_28),(__mpz_struct const *)(e_acsl_27)); + e_acsl_29 = __gmpz_cmp((__mpz_struct const *)(e_acsl_26), + (__mpz_struct const *)(e_acsl_28)); if (! (e_acsl_29 != 0)) { e_acsl_fail((char *)"(1 != -2)"); } - mpz_clear((__mpz_struct *)(e_acsl_26)); - mpz_clear((__mpz_struct *)(e_acsl_27)); - mpz_clear((__mpz_struct *)(e_acsl_28)); + __gmpz_clear((__mpz_struct *)(e_acsl_26)); + __gmpz_clear((__mpz_struct *)(e_acsl_27)); + __gmpz_clear((__mpz_struct *)(e_acsl_28)); } __retres = 0; diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/function_contract.res.oracle b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/function_contract.res.oracle index da4b9214c0a87d4b2fcc8a9bf660c9aded327f92..81b033ed0e004316a740cce92de16afc8fbb3aa5 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/function_contract.res.oracle +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/function_contract.res.oracle @@ -6,18 +6,18 @@ Y ∈ {2} [value] computing for function f <- main. Called from PROJECT_FILE.i:445. -[value] computing for function mpz_init_set_si <- f <- main. +[value] computing for function __gmpz_init_set_si <- f <- main. Called from PROJECT_FILE.i:141. -PROJECT_FILE.i:33:[value] Function mpz_init_set_si: postcondition got status valid. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- f <- main. +PROJECT_FILE.i:33:[value] Function __gmpz_init_set_si: postcondition got status valid. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- f <- main. Called from PROJECT_FILE.i:142. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- f <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- f <- main. Called from PROJECT_FILE.i:143. -PROJECT_FILE.i:49:[value] Function mpz_cmp: precondition got status valid. -PROJECT_FILE.i:50:[value] Function mpz_cmp: precondition got status valid. -[value] Done for function mpz_cmp +PROJECT_FILE.i:49:[value] Function __gmpz_cmp: precondition got status valid. +PROJECT_FILE.i:50:[value] Function __gmpz_cmp: precondition got status valid. +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- f <- main. Called from PROJECT_FILE.i:144. [value] computing for function printf <- e_acsl_fail <- f <- main. @@ -29,27 +29,27 @@ PROJECT_FILE.i:119:[value] Function exit: postcondition got status invalid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- f <- main. +[value] computing for function __gmpz_clear <- f <- main. Called from PROJECT_FILE.i:145. -PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- f <- main. +PROJECT_FILE.i:43:[value] Function __gmpz_clear: precondition got status valid. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- f <- main. Called from PROJECT_FILE.i:146. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:133:[value] Function f: postcondition got status valid. [value] Recording results for f [value] Done for function f [value] computing for function g <- main. Called from PROJECT_FILE.i:446. -[value] computing for function mpz_init_set_si <- g <- main. +[value] computing for function __gmpz_init_set_si <- g <- main. Called from PROJECT_FILE.i:163. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- g <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- g <- main. Called from PROJECT_FILE.i:164. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- g <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- g <- main. Called from PROJECT_FILE.i:165. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- g <- main. Called from PROJECT_FILE.i:166. [value] computing for function printf <- e_acsl_fail <- g <- main. @@ -60,12 +60,12 @@ PROJECT_FILE.i:133:[value] Function f: postcondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_init_set_si <- g <- main. +[value] computing for function __gmpz_init_set_si <- g <- main. Called from PROJECT_FILE.i:167. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- g <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- g <- main. Called from PROJECT_FILE.i:168. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- g <- main. Called from PROJECT_FILE.i:169. [value] computing for function printf <- e_acsl_fail <- g <- main. @@ -76,15 +76,15 @@ PROJECT_FILE.i:133:[value] Function f: postcondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- g <- main. +[value] computing for function __gmpz_clear <- g <- main. Called from PROJECT_FILE.i:170. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- g <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- g <- main. Called from PROJECT_FILE.i:171. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- g <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- g <- main. Called from PROJECT_FILE.i:172. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:152:[value] Function g: postcondition got status valid. PROJECT_FILE.i:153:[value] Function g: postcondition got status valid. [value] Recording results for g @@ -92,15 +92,15 @@ PROJECT_FILE.i:153:[value] Function g: postcondition got status valid. [value] computing for function h <- main. Called from PROJECT_FILE.i:447. PROJECT_FILE.i:178:[value] Function h: precondition got status valid. -[value] computing for function mpz_init_set_si <- h <- main. +[value] computing for function __gmpz_init_set_si <- h <- main. Called from PROJECT_FILE.i:185. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- h <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- h <- main. Called from PROJECT_FILE.i:186. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- h <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- h <- main. Called from PROJECT_FILE.i:187. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- h <- main. Called from PROJECT_FILE.i:188. [value] computing for function printf <- e_acsl_fail <- h <- main. @@ -111,27 +111,27 @@ PROJECT_FILE.i:178:[value] Function h: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- h <- main. +[value] computing for function __gmpz_clear <- h <- main. Called from PROJECT_FILE.i:189. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- h <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- h <- main. Called from PROJECT_FILE.i:190. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] Recording results for h [value] Done for function h [value] computing for function i <- main. Called from PROJECT_FILE.i:448. PROJECT_FILE.i:197:[value] Function i: precondition got status valid. PROJECT_FILE.i:198:[value] Function i: precondition got status valid. -[value] computing for function mpz_init_set_si <- i <- main. +[value] computing for function __gmpz_init_set_si <- i <- main. Called from PROJECT_FILE.i:208. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- i <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- i <- main. Called from PROJECT_FILE.i:209. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- i <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- i <- main. Called from PROJECT_FILE.i:210. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- i <- main. Called from PROJECT_FILE.i:211. [value] computing for function printf <- e_acsl_fail <- i <- main. @@ -142,15 +142,15 @@ PROJECT_FILE.i:198:[value] Function i: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_init_set_si <- i <- main. +[value] computing for function __gmpz_init_set_si <- i <- main. Called from PROJECT_FILE.i:212. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- i <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- i <- main. Called from PROJECT_FILE.i:213. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- i <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- i <- main. Called from PROJECT_FILE.i:214. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- i <- main. Called from PROJECT_FILE.i:215. [value] computing for function printf <- e_acsl_fail <- i <- main. @@ -161,18 +161,18 @@ PROJECT_FILE.i:198:[value] Function i: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- i <- main. +[value] computing for function __gmpz_clear <- i <- main. Called from PROJECT_FILE.i:216. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- i <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- i <- main. Called from PROJECT_FILE.i:217. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- i <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- i <- main. Called from PROJECT_FILE.i:218. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- i <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- i <- main. Called from PROJECT_FILE.i:219. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] Recording results for i [value] Done for function i [value] computing for function j <- main. @@ -180,15 +180,15 @@ PROJECT_FILE.i:198:[value] Function i: precondition got status valid. PROJECT_FILE.i:227:[value] Function j, behavior b1: precondition got status valid. PROJECT_FILE.i:231:[value] Function j, behavior b2: precondition got status valid. PROJECT_FILE.i:232:[value] Function j, behavior b2: precondition got status valid. -[value] computing for function mpz_init_set_si <- j <- main. +[value] computing for function __gmpz_init_set_si <- j <- main. Called from PROJECT_FILE.i:249. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- j <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- j <- main. Called from PROJECT_FILE.i:250. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- j <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- j <- main. Called from PROJECT_FILE.i:251. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- j <- main. Called from PROJECT_FILE.i:252. [value] computing for function printf <- e_acsl_fail <- j <- main. @@ -199,25 +199,25 @@ PROJECT_FILE.i:232:[value] Function j, behavior b2: precondition got status vali [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_init_set_si <- j <- main. +[value] computing for function __gmpz_init_set_si <- j <- main. Called from PROJECT_FILE.i:253. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- j <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- j <- main. Called from PROJECT_FILE.i:254. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- j <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- j <- main. Called from PROJECT_FILE.i:255. -PROJECT_FILE.i:21:[value] Function mpz_init: postcondition got status valid. -[value] Done for function mpz_init -[value] computing for function mpz_add <- j <- main. +PROJECT_FILE.i:21:[value] Function __gmpz_init: postcondition got status valid. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_add <- j <- main. Called from PROJECT_FILE.i:256. -PROJECT_FILE.i:64:[value] Function mpz_add: precondition got status valid. -PROJECT_FILE.i:65:[value] Function mpz_add: precondition got status valid. -PROJECT_FILE.i:66:[value] Function mpz_add: precondition got status valid. -[value] Done for function mpz_add -[value] computing for function mpz_cmp <- j <- main. +PROJECT_FILE.i:64:[value] Function __gmpz_add: precondition got status valid. +PROJECT_FILE.i:65:[value] Function __gmpz_add: precondition got status valid. +PROJECT_FILE.i:66:[value] Function __gmpz_add: precondition got status valid. +[value] Done for function __gmpz_add +[value] computing for function __gmpz_cmp <- j <- main. Called from PROJECT_FILE.i:257. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- j <- main. Called from PROJECT_FILE.i:258. [value] computing for function printf <- e_acsl_fail <- j <- main. @@ -228,12 +228,12 @@ PROJECT_FILE.i:66:[value] Function mpz_add: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_init_set_si <- j <- main. +[value] computing for function __gmpz_init_set_si <- j <- main. Called from PROJECT_FILE.i:259. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- j <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- j <- main. Called from PROJECT_FILE.i:260. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- j <- main. Called from PROJECT_FILE.i:261. [value] computing for function printf <- e_acsl_fail <- j <- main. @@ -244,33 +244,33 @@ PROJECT_FILE.i:66:[value] Function mpz_add: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- j <- main. +[value] computing for function __gmpz_clear <- j <- main. Called from PROJECT_FILE.i:262. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- j <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- j <- main. Called from PROJECT_FILE.i:263. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- j <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- j <- main. Called from PROJECT_FILE.i:264. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- j <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- j <- main. Called from PROJECT_FILE.i:265. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- j <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- j <- main. Called from PROJECT_FILE.i:266. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- j <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- j <- main. Called from PROJECT_FILE.i:267. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- j <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- j <- main. Called from PROJECT_FILE.i:279. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- j <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- j <- main. Called from PROJECT_FILE.i:280. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- j <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- j <- main. Called from PROJECT_FILE.i:281. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- j <- main. Called from PROJECT_FILE.i:282. [value] computing for function printf <- e_acsl_fail <- j <- main. @@ -281,21 +281,21 @@ PROJECT_FILE.i:66:[value] Function mpz_add: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_init_set_si <- j <- main. +[value] computing for function __gmpz_init_set_si <- j <- main. Called from PROJECT_FILE.i:283. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- j <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- j <- main. Called from PROJECT_FILE.i:284. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- j <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- j <- main. Called from PROJECT_FILE.i:285. -[value] Done for function mpz_init -[value] computing for function mpz_add <- j <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_add <- j <- main. Called from PROJECT_FILE.i:286. -[value] Done for function mpz_add -[value] computing for function mpz_cmp <- j <- main. +[value] Done for function __gmpz_add +[value] computing for function __gmpz_cmp <- j <- main. Called from PROJECT_FILE.i:287. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- j <- main. Called from PROJECT_FILE.i:288. [value] computing for function printf <- e_acsl_fail <- j <- main. @@ -306,21 +306,21 @@ PROJECT_FILE.i:66:[value] Function mpz_add: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- j <- main. +[value] computing for function __gmpz_clear <- j <- main. Called from PROJECT_FILE.i:289. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- j <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- j <- main. Called from PROJECT_FILE.i:290. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- j <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- j <- main. Called from PROJECT_FILE.i:291. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- j <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- j <- main. Called from PROJECT_FILE.i:292. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- j <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- j <- main. Called from PROJECT_FILE.i:293. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:228:[value] Function j, behavior b1: postcondition got status valid. PROJECT_FILE.i:233:[value] Function j, behavior b2: postcondition got status valid. [value] Recording results for j @@ -330,31 +330,31 @@ PROJECT_FILE.i:233:[value] Function j, behavior b2: postcondition got status val PROJECT_FILE.i:301:[value] Function k, behavior b1: assumption got status invalid; precondition not evaluated. PROJECT_FILE.i:306:[value] Function k, behavior b2: precondition got status valid. PROJECT_FILE.i:307:[value] Function k, behavior b2: precondition got status valid. -[value] computing for function mpz_init_set_si <- k <- main. +[value] computing for function __gmpz_init_set_si <- k <- main. Called from PROJECT_FILE.i:325. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- k <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- k <- main. Called from PROJECT_FILE.i:326. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- k <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- k <- main. Called from PROJECT_FILE.i:327. -[value] Done for function mpz_cmp -[value] computing for function mpz_init_set_si <- k <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_init_set_si <- k <- main. Called from PROJECT_FILE.i:333. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- k <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- k <- main. Called from PROJECT_FILE.i:334. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- k <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- k <- main. Called from PROJECT_FILE.i:335. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp PROJECT_FILE.i:336:[value] assigning non deterministic value for the first time -[value] computing for function mpz_clear <- k <- main. +[value] computing for function __gmpz_clear <- k <- main. Called from PROJECT_FILE.i:337. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- k <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- k <- main. Called from PROJECT_FILE.i:338. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] computing for function e_acsl_fail <- k <- main. Called from PROJECT_FILE.i:340. [value] computing for function printf <- e_acsl_fail <- k <- main. @@ -365,42 +365,42 @@ PROJECT_FILE.i:336:[value] assigning non deterministic value for the first time [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_init_set_si <- k <- main. +[value] computing for function __gmpz_init_set_si <- k <- main. Called from PROJECT_FILE.i:341. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- k <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- k <- main. Called from PROJECT_FILE.i:342. -[value] Done for function mpz_cmp -[value] computing for function mpz_init_set_si <- k <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_init_set_si <- k <- main. Called from PROJECT_FILE.i:347. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- k <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- k <- main. Called from PROJECT_FILE.i:348. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- k <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- k <- main. Called from PROJECT_FILE.i:349. -[value] Done for function mpz_cmp -[value] computing for function mpz_clear <- k <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_clear <- k <- main. Called from PROJECT_FILE.i:351. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- k <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- k <- main. Called from PROJECT_FILE.i:352. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- k <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- k <- main. Called from PROJECT_FILE.i:360. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- k <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- k <- main. Called from PROJECT_FILE.i:361. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- k <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- k <- main. Called from PROJECT_FILE.i:362. -[value] Done for function mpz_cmp -[value] computing for function mpz_clear <- k <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_clear <- k <- main. Called from PROJECT_FILE.i:364. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- k <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- k <- main. Called from PROJECT_FILE.i:365. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] computing for function e_acsl_fail <- k <- main. Called from PROJECT_FILE.i:367. [value] computing for function printf <- e_acsl_fail <- k <- main. @@ -411,54 +411,54 @@ PROJECT_FILE.i:336:[value] assigning non deterministic value for the first time [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_cmp <- k <- main. +[value] computing for function __gmpz_cmp <- k <- main. Called from PROJECT_FILE.i:368. -[value] Done for function mpz_cmp -[value] computing for function mpz_init_set_si <- k <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_init_set_si <- k <- main. Called from PROJECT_FILE.i:373. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- k <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- k <- main. Called from PROJECT_FILE.i:374. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- k <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- k <- main. Called from PROJECT_FILE.i:375. -[value] Done for function mpz_cmp -[value] computing for function mpz_clear <- k <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_clear <- k <- main. Called from PROJECT_FILE.i:377. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- k <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- k <- main. Called from PROJECT_FILE.i:378. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- k <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- k <- main. Called from PROJECT_FILE.i:388. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- k <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- k <- main. Called from PROJECT_FILE.i:389. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- k <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- k <- main. Called from PROJECT_FILE.i:390. -[value] Done for function mpz_init -[value] computing for function mpz_add <- k <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_add <- k <- main. Called from PROJECT_FILE.i:391. -[value] Done for function mpz_add -[value] computing for function mpz_init_set_si <- k <- main. +[value] Done for function __gmpz_add +[value] computing for function __gmpz_init_set_si <- k <- main. Called from PROJECT_FILE.i:392. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- k <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- k <- main. Called from PROJECT_FILE.i:393. -[value] Done for function mpz_cmp -[value] computing for function mpz_clear <- k <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_clear <- k <- main. Called from PROJECT_FILE.i:395. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- k <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- k <- main. Called from PROJECT_FILE.i:396. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- k <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- k <- main. Called from PROJECT_FILE.i:397. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- k <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- k <- main. Called from PROJECT_FILE.i:398. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] computing for function e_acsl_fail <- k <- main. Called from PROJECT_FILE.i:400. [value] computing for function printf <- e_acsl_fail <- k <- main. @@ -469,29 +469,29 @@ PROJECT_FILE.i:336:[value] assigning non deterministic value for the first time [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- k <- main. +[value] computing for function __gmpz_clear <- k <- main. Called from PROJECT_FILE.i:401. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- k <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- k <- main. Called from PROJECT_FILE.i:402. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- k <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- k <- main. Called from PROJECT_FILE.i:403. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] Recording results for k [value] Done for function k [value] computing for function l <- main. Called from PROJECT_FILE.i:451. PROJECT_FILE.i:413:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- l <- main. +[value] computing for function __gmpz_init_set_si <- l <- main. Called from PROJECT_FILE.i:418. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- l <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- l <- main. Called from PROJECT_FILE.i:419. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- l <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- l <- main. Called from PROJECT_FILE.i:420. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- l <- main. Called from PROJECT_FILE.i:421. [value] computing for function printf <- e_acsl_fail <- l <- main. @@ -502,21 +502,21 @@ PROJECT_FILE.i:413:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- l <- main. +[value] computing for function __gmpz_clear <- l <- main. Called from PROJECT_FILE.i:422. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- l <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- l <- main. Called from PROJECT_FILE.i:423. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- l <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- l <- main. Called from PROJECT_FILE.i:431. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- l <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- l <- main. Called from PROJECT_FILE.i:432. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- l <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- l <- main. Called from PROJECT_FILE.i:433. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- l <- main. Called from PROJECT_FILE.i:434. [value] computing for function printf <- e_acsl_fail <- l <- main. @@ -527,12 +527,12 @@ PROJECT_FILE.i:413:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- l <- main. +[value] computing for function __gmpz_clear <- l <- main. Called from PROJECT_FILE.i:435. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- l <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- l <- main. Called from PROJECT_FILE.i:436. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:410:[value] Function l: postcondition got status valid. [value] Recording results for l [value] Done for function l @@ -567,27 +567,27 @@ typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; /*@ ensures \valid(\old(x)); assigns *x; */ -extern void mpz_init(__mpz_struct * /*[1]*/ x); +extern void __gmpz_init(__mpz_struct * /*[1]*/ x); /*@ ensures \valid(\old(z)); assigns *z; assigns *z \from n; */ -extern void mpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); +extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); /*@ requires \valid(x); assigns *x; */ -extern void mpz_clear(__mpz_struct * /*[1]*/ x); +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); assigns \nothing; */ -extern int mpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ requires \valid(z1); requires \valid(z2); requires \valid(z3); assigns *z1; */ -extern void mpz_add(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); +extern void __gmpz_add(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2, + __mpz_struct const * /*[1]*/ z3); /*@ terminates \false; ensures \false; assigns \nothing; */ @@ -611,13 +611,13 @@ void f(void) mpz_t e_acsl_1; mpz_t e_acsl_2; int e_acsl_3; - mpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)X); - mpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)1); - e_acsl_3 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_2)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)X); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)1); + e_acsl_3 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_2)); if (! (e_acsl_3 == 0)) { e_acsl_fail((char *)"(X == 1)"); } - mpz_clear((__mpz_struct *)(e_acsl_1)); - mpz_clear((__mpz_struct *)(e_acsl_2)); + __gmpz_clear((__mpz_struct *)(e_acsl_1)); + __gmpz_clear((__mpz_struct *)(e_acsl_2)); return; } @@ -634,18 +634,18 @@ void g(void) int e_acsl_3; mpz_t e_acsl_4; int e_acsl_5; - mpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)X); - mpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)2); - e_acsl_3 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_2)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)X); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)2); + e_acsl_3 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_2)); if (! (e_acsl_3 == 0)) { e_acsl_fail((char *)"(X == 2)"); } - mpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)Y); - e_acsl_5 = mpz_cmp((__mpz_struct const *)(e_acsl_4), - (__mpz_struct const *)(e_acsl_2)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)Y); + e_acsl_5 = __gmpz_cmp((__mpz_struct const *)(e_acsl_4), + (__mpz_struct const *)(e_acsl_2)); if (! (e_acsl_5 == 0)) { e_acsl_fail((char *)"(Y == 2)"); } - mpz_clear((__mpz_struct *)(e_acsl_1)); - mpz_clear((__mpz_struct *)(e_acsl_2)); - mpz_clear((__mpz_struct *)(e_acsl_4)); + __gmpz_clear((__mpz_struct *)(e_acsl_1)); + __gmpz_clear((__mpz_struct *)(e_acsl_2)); + __gmpz_clear((__mpz_struct *)(e_acsl_4)); return; } @@ -658,13 +658,13 @@ void h(void) mpz_t e_acsl_1; mpz_t e_acsl_2; int e_acsl_3; - mpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)X); - mpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)2); - e_acsl_3 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_2)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)X); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)2); + e_acsl_3 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_2)); if (! (e_acsl_3 == 0)) { e_acsl_fail((char *)"(X == 2)"); } - mpz_clear((__mpz_struct *)(e_acsl_1)); - mpz_clear((__mpz_struct *)(e_acsl_2)); + __gmpz_clear((__mpz_struct *)(e_acsl_1)); + __gmpz_clear((__mpz_struct *)(e_acsl_2)); X ++; } @@ -682,20 +682,20 @@ void i(void) mpz_t e_acsl_4; mpz_t e_acsl_5; int e_acsl_6; - mpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)X); - mpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)3); - e_acsl_3 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_2)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)X); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)3); + e_acsl_3 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_2)); if (! (e_acsl_3 == 0)) { e_acsl_fail((char *)"(X == 3)"); } - mpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)Y); - mpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)2); - e_acsl_6 = mpz_cmp((__mpz_struct const *)(e_acsl_4), - (__mpz_struct const *)(e_acsl_5)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)Y); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)2); + e_acsl_6 = __gmpz_cmp((__mpz_struct const *)(e_acsl_4), + (__mpz_struct const *)(e_acsl_5)); if (! (e_acsl_6 == 0)) { e_acsl_fail((char *)"(Y == 2)"); } - mpz_clear((__mpz_struct *)(e_acsl_1)); - mpz_clear((__mpz_struct *)(e_acsl_2)); - mpz_clear((__mpz_struct *)(e_acsl_4)); - mpz_clear((__mpz_struct *)(e_acsl_5)); + __gmpz_clear((__mpz_struct *)(e_acsl_1)); + __gmpz_clear((__mpz_struct *)(e_acsl_2)); + __gmpz_clear((__mpz_struct *)(e_acsl_4)); + __gmpz_clear((__mpz_struct *)(e_acsl_5)); X += Y; } @@ -725,29 +725,29 @@ void j(void) int e_acsl_7; mpz_t e_acsl_8; int e_acsl_9; - mpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)X); - mpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)5); - e_acsl_3 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_2)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)X); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)5); + e_acsl_3 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_2)); if (! (e_acsl_3 == 0)) { e_acsl_fail((char *)"(X == 5)"); } - mpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)3); - mpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)Y); - mpz_init((__mpz_struct *)(e_acsl_6)); - mpz_add((__mpz_struct *)(e_acsl_6),(__mpz_struct const *)(e_acsl_4), - (__mpz_struct const *)(e_acsl_5)); - e_acsl_7 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_6)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)3); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)Y); + __gmpz_init((__mpz_struct *)(e_acsl_6)); + __gmpz_add((__mpz_struct *)(e_acsl_6),(__mpz_struct const *)(e_acsl_4), + (__mpz_struct const *)(e_acsl_5)); + e_acsl_7 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_6)); if (! (e_acsl_7 == 0)) { e_acsl_fail((char *)"(X == 3+Y)"); } - mpz_init_set_si((__mpz_struct *)(e_acsl_8),(long)2); - e_acsl_9 = mpz_cmp((__mpz_struct const *)(e_acsl_5), - (__mpz_struct const *)(e_acsl_8)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_8),(long)2); + e_acsl_9 = __gmpz_cmp((__mpz_struct const *)(e_acsl_5), + (__mpz_struct const *)(e_acsl_8)); if (! (e_acsl_9 == 0)) { e_acsl_fail((char *)"(Y == 2)"); } - mpz_clear((__mpz_struct *)(e_acsl_1)); - mpz_clear((__mpz_struct *)(e_acsl_2)); - mpz_clear((__mpz_struct *)(e_acsl_4)); - mpz_clear((__mpz_struct *)(e_acsl_5)); - mpz_clear((__mpz_struct *)(e_acsl_6)); - mpz_clear((__mpz_struct *)(e_acsl_8)); + __gmpz_clear((__mpz_struct *)(e_acsl_1)); + __gmpz_clear((__mpz_struct *)(e_acsl_2)); + __gmpz_clear((__mpz_struct *)(e_acsl_4)); + __gmpz_clear((__mpz_struct *)(e_acsl_5)); + __gmpz_clear((__mpz_struct *)(e_acsl_6)); + __gmpz_clear((__mpz_struct *)(e_acsl_8)); X = 3; } @@ -759,24 +759,24 @@ void j(void) mpz_t e_acsl_14; mpz_t e_acsl_15; int e_acsl_16; - mpz_init_set_si((__mpz_struct *)(e_acsl_10),(long)X); - mpz_init_set_si((__mpz_struct *)(e_acsl_11),(long)3); - e_acsl_12 = mpz_cmp((__mpz_struct const *)(e_acsl_10), - (__mpz_struct const *)(e_acsl_11)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_10),(long)X); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_11),(long)3); + e_acsl_12 = __gmpz_cmp((__mpz_struct const *)(e_acsl_10), + (__mpz_struct const *)(e_acsl_11)); if (! (e_acsl_12 == 0)) { e_acsl_fail((char *)"(X == 3)"); } - mpz_init_set_si((__mpz_struct *)(e_acsl_13),(long)Y); - mpz_init_set_si((__mpz_struct *)(e_acsl_14),(long)1); - mpz_init((__mpz_struct *)(e_acsl_15)); - mpz_add((__mpz_struct *)(e_acsl_15),(__mpz_struct const *)(e_acsl_13), - (__mpz_struct const *)(e_acsl_14)); - e_acsl_16 = mpz_cmp((__mpz_struct const *)(e_acsl_10), - (__mpz_struct const *)(e_acsl_15)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_13),(long)Y); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_14),(long)1); + __gmpz_init((__mpz_struct *)(e_acsl_15)); + __gmpz_add((__mpz_struct *)(e_acsl_15),(__mpz_struct const *)(e_acsl_13), + (__mpz_struct const *)(e_acsl_14)); + e_acsl_16 = __gmpz_cmp((__mpz_struct const *)(e_acsl_10), + (__mpz_struct const *)(e_acsl_15)); if (! (e_acsl_16 == 0)) { e_acsl_fail((char *)"(X == Y+1)"); } - mpz_clear((__mpz_struct *)(e_acsl_10)); - mpz_clear((__mpz_struct *)(e_acsl_11)); - mpz_clear((__mpz_struct *)(e_acsl_13)); - mpz_clear((__mpz_struct *)(e_acsl_14)); - mpz_clear((__mpz_struct *)(e_acsl_15)); + __gmpz_clear((__mpz_struct *)(e_acsl_10)); + __gmpz_clear((__mpz_struct *)(e_acsl_11)); + __gmpz_clear((__mpz_struct *)(e_acsl_13)); + __gmpz_clear((__mpz_struct *)(e_acsl_14)); + __gmpz_clear((__mpz_struct *)(e_acsl_15)); return; } @@ -808,38 +808,38 @@ void k(void) int e_acsl_18; int e_acsl_22; int e_acsl_28; - mpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)X); - mpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)1); - e_acsl_3 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_2)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)X); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)1); + e_acsl_3 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_2)); if (! (e_acsl_3 == 0)) { e_acsl_7 = 1; } else { mpz_t e_acsl_4; mpz_t e_acsl_5; int e_acsl_6; - mpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)X); - mpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)0); - e_acsl_6 = mpz_cmp((__mpz_struct const *)(e_acsl_4), - (__mpz_struct const *)(e_acsl_5)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)X); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)0); + e_acsl_6 = __gmpz_cmp((__mpz_struct const *)(e_acsl_4), + (__mpz_struct const *)(e_acsl_5)); e_acsl_7 = e_acsl_6 == 0; - mpz_clear((__mpz_struct *)(e_acsl_4)); - mpz_clear((__mpz_struct *)(e_acsl_5)); + __gmpz_clear((__mpz_struct *)(e_acsl_4)); + __gmpz_clear((__mpz_struct *)(e_acsl_5)); } if (! e_acsl_7) { e_acsl_fail((char *)"(X == 1 ==> X == 0)"); } - mpz_init_set_si((__mpz_struct *)(e_acsl_8),(long)3); - e_acsl_9 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_8)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_8),(long)3); + e_acsl_9 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_8)); if (e_acsl_9 == 0) { mpz_t e_acsl_10; mpz_t e_acsl_11; int e_acsl_12; - mpz_init_set_si((__mpz_struct *)(e_acsl_10),(long)Y); - mpz_init_set_si((__mpz_struct *)(e_acsl_11),(long)2); - e_acsl_12 = mpz_cmp((__mpz_struct const *)(e_acsl_10), - (__mpz_struct const *)(e_acsl_11)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_10),(long)Y); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_11),(long)2); + e_acsl_12 = __gmpz_cmp((__mpz_struct const *)(e_acsl_10), + (__mpz_struct const *)(e_acsl_11)); e_acsl_13 = e_acsl_12 == 0; - mpz_clear((__mpz_struct *)(e_acsl_10)); - mpz_clear((__mpz_struct *)(e_acsl_11)); + __gmpz_clear((__mpz_struct *)(e_acsl_10)); + __gmpz_clear((__mpz_struct *)(e_acsl_11)); } else { e_acsl_13 = 0; } if (! e_acsl_13) { e_acsl_17 = 1; } @@ -847,29 +847,29 @@ void k(void) mpz_t e_acsl_14; mpz_t e_acsl_15; int e_acsl_16; - mpz_init_set_si((__mpz_struct *)(e_acsl_14),(long)X); - mpz_init_set_si((__mpz_struct *)(e_acsl_15),(long)3); - e_acsl_16 = mpz_cmp((__mpz_struct const *)(e_acsl_14), - (__mpz_struct const *)(e_acsl_15)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_14),(long)X); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_15),(long)3); + e_acsl_16 = __gmpz_cmp((__mpz_struct const *)(e_acsl_14), + (__mpz_struct const *)(e_acsl_15)); e_acsl_17 = e_acsl_16 == 0; - mpz_clear((__mpz_struct *)(e_acsl_14)); - mpz_clear((__mpz_struct *)(e_acsl_15)); + __gmpz_clear((__mpz_struct *)(e_acsl_14)); + __gmpz_clear((__mpz_struct *)(e_acsl_15)); } if (! e_acsl_17) { e_acsl_fail((char *)"(X == 3 && Y == 2 ==> X == 3)"); } - e_acsl_18 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_8)); + e_acsl_18 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_8)); if (e_acsl_18 == 0) { mpz_t e_acsl_19; mpz_t e_acsl_20; int e_acsl_21; - mpz_init_set_si((__mpz_struct *)(e_acsl_19),(long)Y); - mpz_init_set_si((__mpz_struct *)(e_acsl_20),(long)2); - e_acsl_21 = mpz_cmp((__mpz_struct const *)(e_acsl_19), - (__mpz_struct const *)(e_acsl_20)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_19),(long)Y); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_20),(long)2); + e_acsl_21 = __gmpz_cmp((__mpz_struct const *)(e_acsl_19), + (__mpz_struct const *)(e_acsl_20)); e_acsl_22 = e_acsl_21 == 0; - mpz_clear((__mpz_struct *)(e_acsl_19)); - mpz_clear((__mpz_struct *)(e_acsl_20)); + __gmpz_clear((__mpz_struct *)(e_acsl_19)); + __gmpz_clear((__mpz_struct *)(e_acsl_20)); } else { e_acsl_22 = 0; } if (! e_acsl_22) { e_acsl_28 = 1; } @@ -879,26 +879,27 @@ void k(void) mpz_t e_acsl_25; mpz_t e_acsl_26; int e_acsl_27; - mpz_init_set_si((__mpz_struct *)(e_acsl_23),(long)X); - mpz_init_set_si((__mpz_struct *)(e_acsl_24),(long)Y); - mpz_init((__mpz_struct *)(e_acsl_25)); - mpz_add((__mpz_struct *)(e_acsl_25),(__mpz_struct const *)(e_acsl_23), - (__mpz_struct const *)(e_acsl_24)); - mpz_init_set_si((__mpz_struct *)(e_acsl_26),(long)5); - e_acsl_27 = mpz_cmp((__mpz_struct const *)(e_acsl_25), - (__mpz_struct const *)(e_acsl_26)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_23),(long)X); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_24),(long)Y); + __gmpz_init((__mpz_struct *)(e_acsl_25)); + __gmpz_add((__mpz_struct *)(e_acsl_25), + (__mpz_struct const *)(e_acsl_23), + (__mpz_struct const *)(e_acsl_24)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_26),(long)5); + e_acsl_27 = __gmpz_cmp((__mpz_struct const *)(e_acsl_25), + (__mpz_struct const *)(e_acsl_26)); e_acsl_28 = e_acsl_27 == 0; - mpz_clear((__mpz_struct *)(e_acsl_23)); - mpz_clear((__mpz_struct *)(e_acsl_24)); - mpz_clear((__mpz_struct *)(e_acsl_25)); - mpz_clear((__mpz_struct *)(e_acsl_26)); + __gmpz_clear((__mpz_struct *)(e_acsl_23)); + __gmpz_clear((__mpz_struct *)(e_acsl_24)); + __gmpz_clear((__mpz_struct *)(e_acsl_25)); + __gmpz_clear((__mpz_struct *)(e_acsl_26)); } if (! e_acsl_28) { e_acsl_fail((char *)"(X == 3 && Y == 2 ==> X+Y == 5)"); } - mpz_clear((__mpz_struct *)(e_acsl_1)); - mpz_clear((__mpz_struct *)(e_acsl_2)); - mpz_clear((__mpz_struct *)(e_acsl_8)); + __gmpz_clear((__mpz_struct *)(e_acsl_1)); + __gmpz_clear((__mpz_struct *)(e_acsl_2)); + __gmpz_clear((__mpz_struct *)(e_acsl_8)); X += Y; } @@ -913,26 +914,26 @@ int l(void) mpz_t e_acsl_1; mpz_t e_acsl_2; int e_acsl_3; - mpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)Y); - mpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)2); - e_acsl_3 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_2)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)Y); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)2); + e_acsl_3 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_2)); if (! (e_acsl_3 == 0)) { e_acsl_fail((char *)"(Y == 2)"); } - mpz_clear((__mpz_struct *)(e_acsl_1)); - mpz_clear((__mpz_struct *)(e_acsl_2)); + __gmpz_clear((__mpz_struct *)(e_acsl_1)); + __gmpz_clear((__mpz_struct *)(e_acsl_2)); } { mpz_t e_acsl_4; mpz_t e_acsl_5; int e_acsl_6; - mpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)X); - mpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)5); - e_acsl_6 = mpz_cmp((__mpz_struct const *)(e_acsl_4), - (__mpz_struct const *)(e_acsl_5)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)X); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)5); + e_acsl_6 = __gmpz_cmp((__mpz_struct const *)(e_acsl_4), + (__mpz_struct const *)(e_acsl_5)); if (! (e_acsl_6 == 0)) { e_acsl_fail((char *)"(X == 5)"); } - mpz_clear((__mpz_struct *)(e_acsl_4)); - mpz_clear((__mpz_struct *)(e_acsl_5)); + __gmpz_clear((__mpz_struct *)(e_acsl_4)); + __gmpz_clear((__mpz_struct *)(e_acsl_5)); return (X); } diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_addrOf.c b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_addrOf.c index cf297cbb4dcbd5ad237ace79793fe5a4a159b1b3..41ece2d75938588fdd9444592fca1f0966749368 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_addrOf.c +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_addrOf.c @@ -1,594 +1,10 @@ /* Generated by Frama-C */ -typedef unsigned long size_t; -typedef unsigned long mp_limb_t; -typedef unsigned long mp_bitcnt_t; -struct __anonstruct___mpz_struct_6 { - int _mp_alloc ; - int _mp_size ; - mp_limb_t *_mp_d ; -}; -typedef struct __anonstruct___mpz_struct_6 __mpz_struct; -typedef mp_limb_t *mp_ptr; -typedef mp_limb_t const *mp_srcptr; -typedef long mp_size_t; -struct __anonstruct___mpq_struct_7 { - __mpz_struct _mp_num ; - __mpz_struct _mp_den ; -}; -typedef struct __anonstruct___mpq_struct_7 __mpq_struct; -typedef __mpz_struct const *mpz_srcptr; -typedef __mpz_struct *mpz_ptr; -typedef __mpq_struct const *mpq_srcptr; -typedef __mpq_struct *mpq_ptr; -/* compiler builtin: - long __builtin_expect(long, long); */ -/*@ assigns \nothing; */ -extern int printf(char const * __restrict __format , ...); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -extern void __gmpz_set(mpz_ptr, mpz_srcptr); -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -/*@ requires \valid(z1); - requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -extern void __gmpq_set(mpq_ptr, mpq_srcptr); -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_add_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n); -extern int __gmpn_perfect_square_p(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -extern mp_bitcnt_t __gmpn_popcount(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_sub_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpz_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_size >= 0) { __gmp_w->_mp_size = __gmp_w->_mp_size; } - else { __gmp_w->_mp_size = - __gmp_w->_mp_size; } - return; -} - -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)(~ ((unsigned int)0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= ~ ((unsigned long)0)) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)((unsigned short)(~ 0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -/*@ requires \valid(z); - assigns \nothing; */ -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) -{ - mp_ptr __gmp_p; - mp_size_t __gmp_n; - mp_limb_t __gmp_l; - mp_limb_t tmp; - __gmp_p = z->_mp_d; - __gmp_n = (long)z->_mp_size; - __gmp_l = *(__gmp_p + 0); - if (__gmp_n != (mp_size_t)0) { tmp = __gmp_l; } - else { tmp = (unsigned long)0; } - return (tmp); -} - -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_result; - long tmp_1; - int tmp_0; - __gmp_result = (unsigned long)0; - { /*undefined sequence*/ - if (__gmp_n >= (mp_size_t)0) { - int tmp; - { /*undefined sequence*/ - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - ; - } - if (__gmp_n < (mp_size_t)tmp) { tmp_0 = 1; } - else { tmp_0 = 0; } - } - else { tmp_0 = 0; } - tmp_1 = __builtin_expect((long)(tmp_0 != 0),(long)1); - } - if (tmp_1) { __gmp_result = *(__gmp_z->_mp_d + __gmp_n); } - return (__gmp_result); -} - -/*@ requires \valid(z1); - requires \valid(z2); - assigns *z1; */ -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) -{ - if (z1 != z2) { __gmpz_set(z1,z2); } - z1->_mp_size = - z1->_mp_size; - return; -} - -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) -{ - mp_size_t __gmp_asize; - int __gmp_result; - long tmp; - __gmp_asize = (long)__gmp_a->_mp_size; - __gmp_result = __gmp_asize >= (mp_size_t)0; - tmp = __builtin_expect((long)((__gmp_asize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_perfect_square_p((mp_limb_t const *)__gmp_a->_mp_d, - __gmp_asize); - } - return (__gmp_result); -} - -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) -{ - mp_size_t __gmp_usize; - mp_bitcnt_t __gmp_result; - long tmp; - __gmp_usize = (long)__gmp_u->_mp_size; - if (__gmp_usize < (mp_size_t)0) { __gmp_result = ~ ((unsigned long)0); } - else { __gmp_result = (unsigned long)0; } - tmp = __builtin_expect((long)((__gmp_usize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_popcount((mp_limb_t const *)__gmp_u->_mp_d, - __gmp_usize); - } - return (__gmp_result); -} - -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - __gmpz_tdiv_q(__gmp_w,& __gmp_u->_mp_num,& __gmp_u->_mp_den); - return; -} - -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) -{ - size_t __retres; - int tmp; - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - __retres = (unsigned long)tmp; - return (__retres); -} - -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_num._mp_size >= 0) { - __gmp_w->_mp_num._mp_size = __gmp_w->_mp_num._mp_size; - } - else { __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; } - return; -} - -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; - return; -} - -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_1; - tmp_1 = __gmpn_add_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_1) { - while (1) { - mp_size_t tmp; - mp_limb_t tmp_0; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - tmp_0 = (__gmp_x + (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - *(__gmp_wp + tmp) = tmp_0; - } - if (! (tmp_0 == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x + __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_r < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x + (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_r < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) -{ - int __gmp_result; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_y; - __gmp_result = 0; - __gmp_i = __gmp_size; - while (1) { - __gmp_i -= (mp_size_t)1; - if (! (__gmp_i >= (mp_size_t)0)) { break; } - __gmp_x = *(__gmp_xp + __gmp_i); - __gmp_y = *(__gmp_yp + __gmp_i); - if (__gmp_x != __gmp_y) { - if (__gmp_x > __gmp_y) { __gmp_result = 1; } - else { __gmp_result = -1; } - break; - } - } - } - - break; - } - return (__gmp_result); -} - -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_0; - tmp_0 = __gmpn_sub_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_0) { - while (1) { - mp_size_t tmp; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - *(__gmp_wp + tmp) = (__gmp_x - (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - } - if (! (__gmp_x == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x - __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_x < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x - (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_x < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_ul; - mp_limb_t __gmp_cy; - __gmp_cy = (unsigned long)0; - while (1) { - { - mp_srcptr tmp; - mp_ptr tmp_0; - { /*undefined sequence*/ tmp = __gmp_up; __gmp_up ++; __gmp_ul = *tmp; - } - { /*undefined sequence*/ - tmp_0 = __gmp_rp; - __gmp_rp ++; - *tmp_0 = - __gmp_ul - __gmp_cy; - } - __gmp_cy |= (unsigned long)(__gmp_ul != (mp_limb_t)0); - } - - __gmp_n -= (mp_size_t)1; - if (! (__gmp_n != (mp_size_t)0)) { break; } - } - return (__gmp_cy); -} - /*@ terminates \false; ensures \false; assigns \nothing; */ extern void exit(int status); +/*@ assigns \nothing; */ +extern int printf(char const * , ...); void e_acsl_fail(char *msg) { printf("%s\n",msg); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_arith.c b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_arith.c index 5eea5f26608c01f44774cdf436d1019576707d3d..a5d5ff035ff4a4f6cbf0d522bace48a768408f45 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_arith.c +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_arith.c @@ -1,64 +1,11 @@ /* Generated by Frama-C */ -typedef unsigned long size_t; -typedef unsigned long mp_limb_t; -typedef unsigned long mp_bitcnt_t; -struct __anonstruct___mpz_struct_6 { +struct __anonstruct___mpz_struct_1 { int _mp_alloc ; int _mp_size ; - mp_limb_t *_mp_d ; + unsigned long *_mp_d ; }; -typedef struct __anonstruct___mpz_struct_6 __mpz_struct; +typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; -typedef mp_limb_t *mp_ptr; -typedef mp_limb_t const *mp_srcptr; -typedef long mp_size_t; -struct __anonstruct___mpq_struct_7 { - __mpz_struct _mp_num ; - __mpz_struct _mp_den ; -}; -typedef struct __anonstruct___mpq_struct_7 __mpq_struct; -typedef __mpz_struct const *mpz_srcptr; -typedef __mpz_struct *mpz_ptr; -typedef __mpq_struct const *mpq_srcptr; -typedef __mpq_struct *mpq_ptr; -/* compiler builtin: - long __builtin_expect(long, long); */ -/*@ assigns \nothing; */ -extern int printf(char const * __restrict __format , ...); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u); -/*@ requires \valid(z1); - requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_add(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -/*@ requires \valid(x); - assigns *x; */ -extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); -/*@ requires \valid(z1); - requires \valid(z2); - assigns \nothing; */ -extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) __attribute__(( -__pure__)); -extern void __gmpz_com(mpz_ptr, mpz_srcptr); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -/*@ requires \valid(z); - assigns \nothing; */ -extern long __gmpz_get_si(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); /*@ ensures \valid(\old(x)); assigns *x; */ extern void __gmpz_init(__mpz_struct * /*[1]*/ x); @@ -70,24 +17,27 @@ extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); assigns *z; */ extern int __gmpz_init_set_str(__mpz_struct * /*[1]*/ z, char const *str, int base); +/*@ requires \valid(x); + assigns *x; */ +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); +/*@ requires \valid(z1); + requires \valid(z2); + assigns \nothing; */ +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); +/*@ requires \valid(z1); + requires \valid(z2); + assigns *z1; */ +extern void __gmpz_neg(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ requires \valid(z1); requires \valid(z2); requires \valid(z3); assigns *z1; */ -extern void __gmpz_mul(__mpz_struct * /*[1]*/ z1, +extern void __gmpz_add(__mpz_struct * /*[1]*/ z1, __mpz_struct const * /*[1]*/ z2, __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -extern void __gmpz_set(mpz_ptr, mpz_srcptr); -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); /*@ requires \valid(z1); requires \valid(z2); requires \valid(z3); @@ -101,6 +51,14 @@ extern void __gmpz_sub(__mpz_struct * /*[1]*/ z1, requires \valid(z3); assigns *z1; */ +extern void __gmpz_mul(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2, + __mpz_struct const * /*[1]*/ z3); +/*@ requires \valid(z1); + requires \valid(z2); + requires \valid(z3); + assigns *z1; +*/ extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, __mpz_struct const * /*[1]*/ z2, __mpz_struct const * /*[1]*/ z3); @@ -112,541 +70,15 @@ extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, extern void __gmpz_tdiv_r(__mpz_struct * /*[1]*/ z1, __mpz_struct const * /*[1]*/ z2, __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -extern void __gmpq_set(mpq_ptr, mpq_srcptr); -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_add_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n); -extern int __gmpn_perfect_square_p(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -extern mp_bitcnt_t __gmpn_popcount(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_sub_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpz_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_size >= 0) { __gmp_w->_mp_size = __gmp_w->_mp_size; } - else { __gmp_w->_mp_size = - __gmp_w->_mp_size; } - return; -} - -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)(~ ((unsigned int)0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= ~ ((unsigned long)0)) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)((unsigned short)(~ 0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - /*@ requires \valid(z); assigns \nothing; */ -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) -{ - mp_ptr __gmp_p; - mp_size_t __gmp_n; - mp_limb_t __gmp_l; - mp_limb_t tmp; - __gmp_p = z->_mp_d; - __gmp_n = (long)z->_mp_size; - __gmp_l = *(__gmp_p + 0); - if (__gmp_n != (mp_size_t)0) { tmp = __gmp_l; } - else { tmp = (unsigned long)0; } - return (tmp); -} - -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_result; - long tmp_1; - int tmp_0; - __gmp_result = (unsigned long)0; - { /*undefined sequence*/ - if (__gmp_n >= (mp_size_t)0) { - int tmp; - { /*undefined sequence*/ - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - ; - } - if (__gmp_n < (mp_size_t)tmp) { tmp_0 = 1; } - else { tmp_0 = 0; } - } - else { tmp_0 = 0; } - tmp_1 = __builtin_expect((long)(tmp_0 != 0),(long)1); - } - if (tmp_1) { __gmp_result = *(__gmp_z->_mp_d + __gmp_n); } - return (__gmp_result); -} - -/*@ requires \valid(z1); - requires \valid(z2); - assigns *z1; */ -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) -{ - if (z1 != z2) { __gmpz_set(z1,z2); } - z1->_mp_size = - z1->_mp_size; - return; -} - -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) -{ - mp_size_t __gmp_asize; - int __gmp_result; - long tmp; - __gmp_asize = (long)__gmp_a->_mp_size; - __gmp_result = __gmp_asize >= (mp_size_t)0; - tmp = __builtin_expect((long)((__gmp_asize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_perfect_square_p((mp_limb_t const *)__gmp_a->_mp_d, - __gmp_asize); - } - return (__gmp_result); -} - -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) -{ - mp_size_t __gmp_usize; - mp_bitcnt_t __gmp_result; - long tmp; - __gmp_usize = (long)__gmp_u->_mp_size; - if (__gmp_usize < (mp_size_t)0) { __gmp_result = ~ ((unsigned long)0); } - else { __gmp_result = (unsigned long)0; } - tmp = __builtin_expect((long)((__gmp_usize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_popcount((mp_limb_t const *)__gmp_u->_mp_d, - __gmp_usize); - } - return (__gmp_result); -} - -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - __gmpz_tdiv_q(__gmp_w,& __gmp_u->_mp_num,& __gmp_u->_mp_den); - return; -} - -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) -{ - size_t __retres; - int tmp; - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - __retres = (unsigned long)tmp; - return (__retres); -} - -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_num._mp_size >= 0) { - __gmp_w->_mp_num._mp_size = __gmp_w->_mp_num._mp_size; - } - else { __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; } - return; -} - -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; - return; -} - -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_1; - tmp_1 = __gmpn_add_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_1) { - while (1) { - mp_size_t tmp; - mp_limb_t tmp_0; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - tmp_0 = (__gmp_x + (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - *(__gmp_wp + tmp) = tmp_0; - } - if (! (tmp_0 == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x + __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_r < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x + (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_r < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) -{ - int __gmp_result; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_y; - __gmp_result = 0; - __gmp_i = __gmp_size; - while (1) { - __gmp_i -= (mp_size_t)1; - if (! (__gmp_i >= (mp_size_t)0)) { break; } - __gmp_x = *(__gmp_xp + __gmp_i); - __gmp_y = *(__gmp_yp + __gmp_i); - if (__gmp_x != __gmp_y) { - if (__gmp_x > __gmp_y) { __gmp_result = 1; } - else { __gmp_result = -1; } - break; - } - } - } - - break; - } - return (__gmp_result); -} - -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_0; - tmp_0 = __gmpn_sub_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_0) { - while (1) { - mp_size_t tmp; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - *(__gmp_wp + tmp) = (__gmp_x - (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - } - if (! (__gmp_x == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x - __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_x < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x - (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_x < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_ul; - mp_limb_t __gmp_cy; - __gmp_cy = (unsigned long)0; - while (1) { - { - mp_srcptr tmp; - mp_ptr tmp_0; - { /*undefined sequence*/ tmp = __gmp_up; __gmp_up ++; __gmp_ul = *tmp; - } - { /*undefined sequence*/ - tmp_0 = __gmp_rp; - __gmp_rp ++; - *tmp_0 = - __gmp_ul - __gmp_cy; - } - __gmp_cy |= (unsigned long)(__gmp_ul != (mp_limb_t)0); - } - - __gmp_n -= (mp_size_t)1; - if (! (__gmp_n != (mp_size_t)0)) { break; } - } - return (__gmp_cy); -} - +extern long __gmpz_get_si(__mpz_struct const * /*[1]*/ z); /*@ terminates \false; ensures \false; assigns \nothing; */ extern void exit(int status); +/*@ assigns \nothing; */ +extern int printf(char const * , ...); void e_acsl_fail(char *msg) { printf("%s\n",msg); @@ -654,6 +86,7 @@ void e_acsl_fail(char *msg) return; } +extern int ( /* missing proto */ __gmpz_com)(); int main(void) { int __retres; @@ -704,7 +137,7 @@ int main(void) int e_acsl_11; __gmpz_init_set_si((__mpz_struct *)(e_acsl_9),(long)0); __gmpz_init((__mpz_struct *)(e_acsl_10)); - __gmpz_com(e_acsl_10,(__mpz_struct const *)(e_acsl_9)); + __gmpz_com(e_acsl_10,e_acsl_9); e_acsl_11 = __gmpz_cmp((__mpz_struct const *)(e_acsl_9), (__mpz_struct const *)(e_acsl_10)); if (! (e_acsl_11 != 0)) { e_acsl_fail((char *)"(0 != ~0)"); } diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_array.c b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_array.c index 7e92ababf3af85d03cdaceb4ca128a0cbcbf2086..bc099e27cecbbf09e3996f6af35709310339a71e 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_array.c +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_array.c @@ -1,594 +1,10 @@ /* Generated by Frama-C */ -typedef unsigned long size_t; -typedef unsigned long mp_limb_t; -typedef unsigned long mp_bitcnt_t; -struct __anonstruct___mpz_struct_6 { - int _mp_alloc ; - int _mp_size ; - mp_limb_t *_mp_d ; -}; -typedef struct __anonstruct___mpz_struct_6 __mpz_struct; -typedef mp_limb_t *mp_ptr; -typedef mp_limb_t const *mp_srcptr; -typedef long mp_size_t; -struct __anonstruct___mpq_struct_7 { - __mpz_struct _mp_num ; - __mpz_struct _mp_den ; -}; -typedef struct __anonstruct___mpq_struct_7 __mpq_struct; -typedef __mpz_struct const *mpz_srcptr; -typedef __mpz_struct *mpz_ptr; -typedef __mpq_struct const *mpq_srcptr; -typedef __mpq_struct *mpq_ptr; -/* compiler builtin: - long __builtin_expect(long, long); */ -/*@ assigns \nothing; */ -extern int printf(char const * __restrict __format , ...); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -extern void __gmpz_set(mpz_ptr, mpz_srcptr); -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -/*@ requires \valid(z1); - requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -extern void __gmpq_set(mpq_ptr, mpq_srcptr); -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_add_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n); -extern int __gmpn_perfect_square_p(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -extern mp_bitcnt_t __gmpn_popcount(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_sub_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpz_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_size >= 0) { __gmp_w->_mp_size = __gmp_w->_mp_size; } - else { __gmp_w->_mp_size = - __gmp_w->_mp_size; } - return; -} - -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)(~ ((unsigned int)0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= ~ ((unsigned long)0)) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)((unsigned short)(~ 0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -/*@ requires \valid(z); - assigns \nothing; */ -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) -{ - mp_ptr __gmp_p; - mp_size_t __gmp_n; - mp_limb_t __gmp_l; - mp_limb_t tmp; - __gmp_p = z->_mp_d; - __gmp_n = (long)z->_mp_size; - __gmp_l = *(__gmp_p + 0); - if (__gmp_n != (mp_size_t)0) { tmp = __gmp_l; } - else { tmp = (unsigned long)0; } - return (tmp); -} - -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_result; - long tmp_1; - int tmp_0; - __gmp_result = (unsigned long)0; - { /*undefined sequence*/ - if (__gmp_n >= (mp_size_t)0) { - int tmp; - { /*undefined sequence*/ - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - ; - } - if (__gmp_n < (mp_size_t)tmp) { tmp_0 = 1; } - else { tmp_0 = 0; } - } - else { tmp_0 = 0; } - tmp_1 = __builtin_expect((long)(tmp_0 != 0),(long)1); - } - if (tmp_1) { __gmp_result = *(__gmp_z->_mp_d + __gmp_n); } - return (__gmp_result); -} - -/*@ requires \valid(z1); - requires \valid(z2); - assigns *z1; */ -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) -{ - if (z1 != z2) { __gmpz_set(z1,z2); } - z1->_mp_size = - z1->_mp_size; - return; -} - -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) -{ - mp_size_t __gmp_asize; - int __gmp_result; - long tmp; - __gmp_asize = (long)__gmp_a->_mp_size; - __gmp_result = __gmp_asize >= (mp_size_t)0; - tmp = __builtin_expect((long)((__gmp_asize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_perfect_square_p((mp_limb_t const *)__gmp_a->_mp_d, - __gmp_asize); - } - return (__gmp_result); -} - -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) -{ - mp_size_t __gmp_usize; - mp_bitcnt_t __gmp_result; - long tmp; - __gmp_usize = (long)__gmp_u->_mp_size; - if (__gmp_usize < (mp_size_t)0) { __gmp_result = ~ ((unsigned long)0); } - else { __gmp_result = (unsigned long)0; } - tmp = __builtin_expect((long)((__gmp_usize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_popcount((mp_limb_t const *)__gmp_u->_mp_d, - __gmp_usize); - } - return (__gmp_result); -} - -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - __gmpz_tdiv_q(__gmp_w,& __gmp_u->_mp_num,& __gmp_u->_mp_den); - return; -} - -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) -{ - size_t __retres; - int tmp; - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - __retres = (unsigned long)tmp; - return (__retres); -} - -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_num._mp_size >= 0) { - __gmp_w->_mp_num._mp_size = __gmp_w->_mp_num._mp_size; - } - else { __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; } - return; -} - -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; - return; -} - -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_1; - tmp_1 = __gmpn_add_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_1) { - while (1) { - mp_size_t tmp; - mp_limb_t tmp_0; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - tmp_0 = (__gmp_x + (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - *(__gmp_wp + tmp) = tmp_0; - } - if (! (tmp_0 == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x + __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_r < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x + (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_r < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) -{ - int __gmp_result; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_y; - __gmp_result = 0; - __gmp_i = __gmp_size; - while (1) { - __gmp_i -= (mp_size_t)1; - if (! (__gmp_i >= (mp_size_t)0)) { break; } - __gmp_x = *(__gmp_xp + __gmp_i); - __gmp_y = *(__gmp_yp + __gmp_i); - if (__gmp_x != __gmp_y) { - if (__gmp_x > __gmp_y) { __gmp_result = 1; } - else { __gmp_result = -1; } - break; - } - } - } - - break; - } - return (__gmp_result); -} - -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_0; - tmp_0 = __gmpn_sub_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_0) { - while (1) { - mp_size_t tmp; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - *(__gmp_wp + tmp) = (__gmp_x - (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - } - if (! (__gmp_x == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x - __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_x < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x - (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_x < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_ul; - mp_limb_t __gmp_cy; - __gmp_cy = (unsigned long)0; - while (1) { - { - mp_srcptr tmp; - mp_ptr tmp_0; - { /*undefined sequence*/ tmp = __gmp_up; __gmp_up ++; __gmp_ul = *tmp; - } - { /*undefined sequence*/ - tmp_0 = __gmp_rp; - __gmp_rp ++; - *tmp_0 = - __gmp_ul - __gmp_cy; - } - __gmp_cy |= (unsigned long)(__gmp_ul != (mp_limb_t)0); - } - - __gmp_n -= (mp_size_t)1; - if (! (__gmp_n != (mp_size_t)0)) { break; } - } - return (__gmp_cy); -} - /*@ terminates \false; ensures \false; assigns \nothing; */ extern void exit(int status); +/*@ assigns \nothing; */ +extern int printf(char const * , ...); void e_acsl_fail(char *msg) { printf("%s\n",msg); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_at.c b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_at.c index 70db2542d422729cca6f23e892719892600de362..aa989e82a16e9aaa1a0e83faedcfe2503ced15a4 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_at.c +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_at.c @@ -1,59 +1,11 @@ /* Generated by Frama-C */ -typedef unsigned long size_t; -typedef unsigned long mp_limb_t; -typedef unsigned long mp_bitcnt_t; -struct __anonstruct___mpz_struct_6 { +struct __anonstruct___mpz_struct_1 { int _mp_alloc ; int _mp_size ; - mp_limb_t *_mp_d ; + unsigned long *_mp_d ; }; -typedef struct __anonstruct___mpz_struct_6 __mpz_struct; +typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; -typedef mp_limb_t *mp_ptr; -typedef mp_limb_t const *mp_srcptr; -typedef long mp_size_t; -struct __anonstruct___mpq_struct_7 { - __mpz_struct _mp_num ; - __mpz_struct _mp_den ; -}; -typedef struct __anonstruct___mpq_struct_7 __mpq_struct; -typedef __mpz_struct const *mpz_srcptr; -typedef __mpz_struct *mpz_ptr; -typedef __mpq_struct const *mpq_srcptr; -typedef __mpq_struct *mpq_ptr; -/* compiler builtin: - long __builtin_expect(long, long); */ -/*@ assigns \nothing; */ -extern int printf(char const * __restrict __format , ...); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u); -/*@ requires \valid(z1); - requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_add(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -/*@ requires \valid(x); - assigns *x; */ -extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); -/*@ requires \valid(z1); - requires \valid(z2); - assigns \nothing; */ -extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); /*@ ensures \valid(\old(x)); assigns *x; */ extern void __gmpz_init(__mpz_struct * /*[1]*/ x); @@ -65,559 +17,28 @@ extern void __gmpz_init_set(__mpz_struct * /*[1]*/ z, assigns *z; assigns *z \from n; */ extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -extern void __gmpz_set(mpz_ptr, mpz_srcptr); -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); +/*@ requires \valid(x); + assigns *x; */ +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -extern void __gmpq_set(mpq_ptr, mpq_srcptr); -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_add_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n); -extern int __gmpn_perfect_square_p(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -extern mp_bitcnt_t __gmpn_popcount(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_sub_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpz_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_size >= 0) { __gmp_w->_mp_size = __gmp_w->_mp_size; } - else { __gmp_w->_mp_size = - __gmp_w->_mp_size; } - return; -} - -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)(~ ((unsigned int)0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= ~ ((unsigned long)0)) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)((unsigned short)(~ 0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -/*@ requires \valid(z); assigns \nothing; */ -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) -{ - mp_ptr __gmp_p; - mp_size_t __gmp_n; - mp_limb_t __gmp_l; - mp_limb_t tmp; - __gmp_p = z->_mp_d; - __gmp_n = (long)z->_mp_size; - __gmp_l = *(__gmp_p + 0); - if (__gmp_n != (mp_size_t)0) { tmp = __gmp_l; } - else { tmp = (unsigned long)0; } - return (tmp); -} - -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_result; - long tmp_1; - int tmp_0; - __gmp_result = (unsigned long)0; - { /*undefined sequence*/ - if (__gmp_n >= (mp_size_t)0) { - int tmp; - { /*undefined sequence*/ - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - ; - } - if (__gmp_n < (mp_size_t)tmp) { tmp_0 = 1; } - else { tmp_0 = 0; } - } - else { tmp_0 = 0; } - tmp_1 = __builtin_expect((long)(tmp_0 != 0),(long)1); - } - if (tmp_1) { __gmp_result = *(__gmp_z->_mp_d + __gmp_n); } - return (__gmp_result); -} - +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ requires \valid(z1); requires \valid(z2); - assigns *z1; */ -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) -{ - if (z1 != z2) { __gmpz_set(z1,z2); } - z1->_mp_size = - z1->_mp_size; - return; -} - -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) -{ - mp_size_t __gmp_asize; - int __gmp_result; - long tmp; - __gmp_asize = (long)__gmp_a->_mp_size; - __gmp_result = __gmp_asize >= (mp_size_t)0; - tmp = __builtin_expect((long)((__gmp_asize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_perfect_square_p((mp_limb_t const *)__gmp_a->_mp_d, - __gmp_asize); - } - return (__gmp_result); -} - -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) -{ - mp_size_t __gmp_usize; - mp_bitcnt_t __gmp_result; - long tmp; - __gmp_usize = (long)__gmp_u->_mp_size; - if (__gmp_usize < (mp_size_t)0) { __gmp_result = ~ ((unsigned long)0); } - else { __gmp_result = (unsigned long)0; } - tmp = __builtin_expect((long)((__gmp_usize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_popcount((mp_limb_t const *)__gmp_u->_mp_d, - __gmp_usize); - } - return (__gmp_result); -} - -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - __gmpz_tdiv_q(__gmp_w,& __gmp_u->_mp_num,& __gmp_u->_mp_den); - return; -} - -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) -{ - size_t __retres; - int tmp; - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - __retres = (unsigned long)tmp; - return (__retres); -} - -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_num._mp_size >= 0) { - __gmp_w->_mp_num._mp_size = __gmp_w->_mp_num._mp_size; - } - else { __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; } - return; -} - -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; - return; -} - -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_1; - tmp_1 = __gmpn_add_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_1) { - while (1) { - mp_size_t tmp; - mp_limb_t tmp_0; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - tmp_0 = (__gmp_x + (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - *(__gmp_wp + tmp) = tmp_0; - } - if (! (tmp_0 == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x + __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_r < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x + (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_r < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) -{ - int __gmp_result; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_y; - __gmp_result = 0; - __gmp_i = __gmp_size; - while (1) { - __gmp_i -= (mp_size_t)1; - if (! (__gmp_i >= (mp_size_t)0)) { break; } - __gmp_x = *(__gmp_xp + __gmp_i); - __gmp_y = *(__gmp_yp + __gmp_i); - if (__gmp_x != __gmp_y) { - if (__gmp_x > __gmp_y) { __gmp_result = 1; } - else { __gmp_result = -1; } - break; - } - } - } - - break; - } - return (__gmp_result); -} - -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_0; - tmp_0 = __gmpn_sub_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_0) { - while (1) { - mp_size_t tmp; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - *(__gmp_wp + tmp) = (__gmp_x - (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - } - if (! (__gmp_x == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x - __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_x < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x - (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_x < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_ul; - mp_limb_t __gmp_cy; - __gmp_cy = (unsigned long)0; - while (1) { - { - mp_srcptr tmp; - mp_ptr tmp_0; - { /*undefined sequence*/ tmp = __gmp_up; __gmp_up ++; __gmp_ul = *tmp; - } - { /*undefined sequence*/ - tmp_0 = __gmp_rp; - __gmp_rp ++; - *tmp_0 = - __gmp_ul - __gmp_cy; - } - __gmp_cy |= (unsigned long)(__gmp_ul != (mp_limb_t)0); - } - - __gmp_n -= (mp_size_t)1; - if (! (__gmp_n != (mp_size_t)0)) { break; } - } - return (__gmp_cy); -} - + requires \valid(z3); + assigns *z1; +*/ +extern void __gmpz_add(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2, + __mpz_struct const * /*[1]*/ z3); /*@ terminates \false; ensures \false; assigns \nothing; */ extern void exit(int status); +/*@ assigns \nothing; */ +extern int printf(char const * , ...); void e_acsl_fail(char *msg) { printf("%s\n",msg); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_cast.c b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_cast.c index 44bce8d26f15e248a4f0e7e7c0ff90fcab0717ee..43b8b8d91c193b3ed3333ec5e1ff0f9566c0948a 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_cast.c +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_cast.c @@ -1,606 +1,30 @@ /* Generated by Frama-C */ -typedef unsigned long size_t; -typedef unsigned long mp_limb_t; -typedef unsigned long mp_bitcnt_t; -struct __anonstruct___mpz_struct_6 { +struct __anonstruct___mpz_struct_1 { int _mp_alloc ; int _mp_size ; - mp_limb_t *_mp_d ; + unsigned long *_mp_d ; }; -typedef struct __anonstruct___mpz_struct_6 __mpz_struct; +typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; -typedef mp_limb_t *mp_ptr; -typedef mp_limb_t const *mp_srcptr; -typedef long mp_size_t; -struct __anonstruct___mpq_struct_7 { - __mpz_struct _mp_num ; - __mpz_struct _mp_den ; -}; -typedef struct __anonstruct___mpq_struct_7 __mpq_struct; -typedef __mpz_struct const *mpz_srcptr; -typedef __mpz_struct *mpz_ptr; -typedef __mpq_struct const *mpq_srcptr; -typedef __mpq_struct *mpq_ptr; -/* compiler builtin: - long __builtin_expect(long, long); */ -/*@ assigns \nothing; */ -extern int printf(char const * __restrict __format , ...); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u); +/*@ ensures \valid(\old(z)); + assigns *z; */ +extern int __gmpz_init_set_str(__mpz_struct * /*[1]*/ z, char const *str, + int base); /*@ requires \valid(x); assigns *x; */ extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); /*@ requires \valid(z); assigns \nothing; */ -extern long __gmpz_get_si(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -/*@ ensures \valid(\old(z)); - assigns *z; */ -extern int __gmpz_init_set_str(__mpz_struct * /*[1]*/ z, char const *str, - int base); -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -extern void __gmpz_set(mpz_ptr, mpz_srcptr); -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -/*@ requires \valid(z1); - requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -extern void __gmpq_set(mpq_ptr, mpq_srcptr); -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_add_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n); -extern int __gmpn_perfect_square_p(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -extern mp_bitcnt_t __gmpn_popcount(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_sub_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpz_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_size >= 0) { __gmp_w->_mp_size = __gmp_w->_mp_size; } - else { __gmp_w->_mp_size = - __gmp_w->_mp_size; } - return; -} - -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)(~ ((unsigned int)0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= ~ ((unsigned long)0)) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)((unsigned short)(~ 0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - +extern long __gmpz_get_si(__mpz_struct const * /*[1]*/ z); /*@ requires \valid(z); assigns \nothing; */ -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) -{ - mp_ptr __gmp_p; - mp_size_t __gmp_n; - mp_limb_t __gmp_l; - mp_limb_t tmp; - __gmp_p = z->_mp_d; - __gmp_n = (long)z->_mp_size; - __gmp_l = *(__gmp_p + 0); - if (__gmp_n != (mp_size_t)0) { tmp = __gmp_l; } - else { tmp = (unsigned long)0; } - return (tmp); -} - -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_result; - long tmp_1; - int tmp_0; - __gmp_result = (unsigned long)0; - { /*undefined sequence*/ - if (__gmp_n >= (mp_size_t)0) { - int tmp; - { /*undefined sequence*/ - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - ; - } - if (__gmp_n < (mp_size_t)tmp) { tmp_0 = 1; } - else { tmp_0 = 0; } - } - else { tmp_0 = 0; } - tmp_1 = __builtin_expect((long)(tmp_0 != 0),(long)1); - } - if (tmp_1) { __gmp_result = *(__gmp_z->_mp_d + __gmp_n); } - return (__gmp_result); -} - -/*@ requires \valid(z1); - requires \valid(z2); - assigns *z1; */ -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) -{ - if (z1 != z2) { __gmpz_set(z1,z2); } - z1->_mp_size = - z1->_mp_size; - return; -} - -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) -{ - mp_size_t __gmp_asize; - int __gmp_result; - long tmp; - __gmp_asize = (long)__gmp_a->_mp_size; - __gmp_result = __gmp_asize >= (mp_size_t)0; - tmp = __builtin_expect((long)((__gmp_asize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_perfect_square_p((mp_limb_t const *)__gmp_a->_mp_d, - __gmp_asize); - } - return (__gmp_result); -} - -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) -{ - mp_size_t __gmp_usize; - mp_bitcnt_t __gmp_result; - long tmp; - __gmp_usize = (long)__gmp_u->_mp_size; - if (__gmp_usize < (mp_size_t)0) { __gmp_result = ~ ((unsigned long)0); } - else { __gmp_result = (unsigned long)0; } - tmp = __builtin_expect((long)((__gmp_usize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_popcount((mp_limb_t const *)__gmp_u->_mp_d, - __gmp_usize); - } - return (__gmp_result); -} - -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - __gmpz_tdiv_q(__gmp_w,& __gmp_u->_mp_num,& __gmp_u->_mp_den); - return; -} - -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) -{ - size_t __retres; - int tmp; - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - __retres = (unsigned long)tmp; - return (__retres); -} - -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_num._mp_size >= 0) { - __gmp_w->_mp_num._mp_size = __gmp_w->_mp_num._mp_size; - } - else { __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; } - return; -} - -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; - return; -} - -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_1; - tmp_1 = __gmpn_add_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_1) { - while (1) { - mp_size_t tmp; - mp_limb_t tmp_0; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - tmp_0 = (__gmp_x + (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - *(__gmp_wp + tmp) = tmp_0; - } - if (! (tmp_0 == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x + __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_r < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x + (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_r < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) -{ - int __gmp_result; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_y; - __gmp_result = 0; - __gmp_i = __gmp_size; - while (1) { - __gmp_i -= (mp_size_t)1; - if (! (__gmp_i >= (mp_size_t)0)) { break; } - __gmp_x = *(__gmp_xp + __gmp_i); - __gmp_y = *(__gmp_yp + __gmp_i); - if (__gmp_x != __gmp_y) { - if (__gmp_x > __gmp_y) { __gmp_result = 1; } - else { __gmp_result = -1; } - break; - } - } - } - - break; - } - return (__gmp_result); -} - -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_0; - tmp_0 = __gmpn_sub_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_0) { - while (1) { - mp_size_t tmp; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - *(__gmp_wp + tmp) = (__gmp_x - (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - } - if (! (__gmp_x == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x - __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_x < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x - (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_x < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_ul; - mp_limb_t __gmp_cy; - __gmp_cy = (unsigned long)0; - while (1) { - { - mp_srcptr tmp; - mp_ptr tmp_0; - { /*undefined sequence*/ tmp = __gmp_up; __gmp_up ++; __gmp_ul = *tmp; - } - { /*undefined sequence*/ - tmp_0 = __gmp_rp; - __gmp_rp ++; - *tmp_0 = - __gmp_ul - __gmp_cy; - } - __gmp_cy |= (unsigned long)(__gmp_ul != (mp_limb_t)0); - } - - __gmp_n -= (mp_size_t)1; - if (! (__gmp_n != (mp_size_t)0)) { break; } - } - return (__gmp_cy); -} - +extern unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z); /*@ terminates \false; ensures \false; assigns \nothing; */ extern void exit(int status); +/*@ assigns \nothing; */ +extern int printf(char const * , ...); void e_acsl_fail(char *msg) { printf("%s\n",msg); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_comparison.c b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_comparison.c index 4eea08ea3a2ea6e03a5436a79abf2ae3f7bbcf33..1f8f8bb40e520686e817f7c55a60e9dd33a7c77f 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_comparison.c +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_comparison.c @@ -1,51 +1,11 @@ /* Generated by Frama-C */ -typedef unsigned long size_t; -typedef unsigned long mp_limb_t; -typedef unsigned long mp_bitcnt_t; -struct __anonstruct___mpz_struct_6 { +struct __anonstruct___mpz_struct_1 { int _mp_alloc ; int _mp_size ; - mp_limb_t *_mp_d ; + unsigned long *_mp_d ; }; -typedef struct __anonstruct___mpz_struct_6 __mpz_struct; +typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; -typedef mp_limb_t *mp_ptr; -typedef mp_limb_t const *mp_srcptr; -typedef long mp_size_t; -struct __anonstruct___mpq_struct_7 { - __mpz_struct _mp_num ; - __mpz_struct _mp_den ; -}; -typedef struct __anonstruct___mpq_struct_7 __mpq_struct; -typedef __mpz_struct const *mpz_srcptr; -typedef __mpz_struct *mpz_ptr; -typedef __mpq_struct const *mpq_srcptr; -typedef __mpq_struct *mpq_ptr; -/* compiler builtin: - long __builtin_expect(long, long); */ -/*@ assigns \nothing; */ -extern int printf(char const * __restrict __format , ...); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u); -/*@ requires \valid(x); - assigns *x; */ -extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); -/*@ requires \valid(z1); - requires \valid(z2); - assigns \nothing; */ -extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); /*@ ensures \valid(\old(x)); assigns *x; */ extern void __gmpz_init(__mpz_struct * /*[1]*/ x); @@ -53,559 +13,25 @@ extern void __gmpz_init(__mpz_struct * /*[1]*/ x); assigns *z; assigns *z \from n; */ extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -extern void __gmpz_set(mpz_ptr, mpz_srcptr); -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); +/*@ requires \valid(x); + assigns *x; */ +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -extern void __gmpq_set(mpq_ptr, mpq_srcptr); -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_add_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n); -extern int __gmpn_perfect_square_p(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -extern mp_bitcnt_t __gmpn_popcount(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_sub_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpz_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_size >= 0) { __gmp_w->_mp_size = __gmp_w->_mp_size; } - else { __gmp_w->_mp_size = - __gmp_w->_mp_size; } - return; -} - -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)(~ ((unsigned int)0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= ~ ((unsigned long)0)) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)((unsigned short)(~ 0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -/*@ requires \valid(z); assigns \nothing; */ -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) -{ - mp_ptr __gmp_p; - mp_size_t __gmp_n; - mp_limb_t __gmp_l; - mp_limb_t tmp; - __gmp_p = z->_mp_d; - __gmp_n = (long)z->_mp_size; - __gmp_l = *(__gmp_p + 0); - if (__gmp_n != (mp_size_t)0) { tmp = __gmp_l; } - else { tmp = (unsigned long)0; } - return (tmp); -} - -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_result; - long tmp_1; - int tmp_0; - __gmp_result = (unsigned long)0; - { /*undefined sequence*/ - if (__gmp_n >= (mp_size_t)0) { - int tmp; - { /*undefined sequence*/ - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - ; - } - if (__gmp_n < (mp_size_t)tmp) { tmp_0 = 1; } - else { tmp_0 = 0; } - } - else { tmp_0 = 0; } - tmp_1 = __builtin_expect((long)(tmp_0 != 0),(long)1); - } - if (tmp_1) { __gmp_result = *(__gmp_z->_mp_d + __gmp_n); } - return (__gmp_result); -} - +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ requires \valid(z1); requires \valid(z2); assigns *z1; */ -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) -{ - if (z1 != z2) { __gmpz_set(z1,z2); } - z1->_mp_size = - z1->_mp_size; - return; -} - -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) -{ - mp_size_t __gmp_asize; - int __gmp_result; - long tmp; - __gmp_asize = (long)__gmp_a->_mp_size; - __gmp_result = __gmp_asize >= (mp_size_t)0; - tmp = __builtin_expect((long)((__gmp_asize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_perfect_square_p((mp_limb_t const *)__gmp_a->_mp_d, - __gmp_asize); - } - return (__gmp_result); -} - -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) -{ - mp_size_t __gmp_usize; - mp_bitcnt_t __gmp_result; - long tmp; - __gmp_usize = (long)__gmp_u->_mp_size; - if (__gmp_usize < (mp_size_t)0) { __gmp_result = ~ ((unsigned long)0); } - else { __gmp_result = (unsigned long)0; } - tmp = __builtin_expect((long)((__gmp_usize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_popcount((mp_limb_t const *)__gmp_u->_mp_d, - __gmp_usize); - } - return (__gmp_result); -} - -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - __gmpz_tdiv_q(__gmp_w,& __gmp_u->_mp_num,& __gmp_u->_mp_den); - return; -} - -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) -{ - size_t __retres; - int tmp; - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - __retres = (unsigned long)tmp; - return (__retres); -} - -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_num._mp_size >= 0) { - __gmp_w->_mp_num._mp_size = __gmp_w->_mp_num._mp_size; - } - else { __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; } - return; -} - -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; - return; -} - -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_1; - tmp_1 = __gmpn_add_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_1) { - while (1) { - mp_size_t tmp; - mp_limb_t tmp_0; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - tmp_0 = (__gmp_x + (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - *(__gmp_wp + tmp) = tmp_0; - } - if (! (tmp_0 == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x + __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_r < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x + (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_r < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) -{ - int __gmp_result; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_y; - __gmp_result = 0; - __gmp_i = __gmp_size; - while (1) { - __gmp_i -= (mp_size_t)1; - if (! (__gmp_i >= (mp_size_t)0)) { break; } - __gmp_x = *(__gmp_xp + __gmp_i); - __gmp_y = *(__gmp_yp + __gmp_i); - if (__gmp_x != __gmp_y) { - if (__gmp_x > __gmp_y) { __gmp_result = 1; } - else { __gmp_result = -1; } - break; - } - } - } - - break; - } - return (__gmp_result); -} - -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_0; - tmp_0 = __gmpn_sub_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_0) { - while (1) { - mp_size_t tmp; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - *(__gmp_wp + tmp) = (__gmp_x - (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - } - if (! (__gmp_x == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x - __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_x < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x - (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_x < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_ul; - mp_limb_t __gmp_cy; - __gmp_cy = (unsigned long)0; - while (1) { - { - mp_srcptr tmp; - mp_ptr tmp_0; - { /*undefined sequence*/ tmp = __gmp_up; __gmp_up ++; __gmp_ul = *tmp; - } - { /*undefined sequence*/ - tmp_0 = __gmp_rp; - __gmp_rp ++; - *tmp_0 = - __gmp_ul - __gmp_cy; - } - __gmp_cy |= (unsigned long)(__gmp_ul != (mp_limb_t)0); - } - - __gmp_n -= (mp_size_t)1; - if (! (__gmp_n != (mp_size_t)0)) { break; } - } - return (__gmp_cy); -} - +extern void __gmpz_neg(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ terminates \false; ensures \false; assigns \nothing; */ extern void exit(int status); +/*@ assigns \nothing; */ +extern int printf(char const * , ...); void e_acsl_fail(char *msg) { printf("%s\n",msg); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_false.c b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_false.c index 3aa800231de305d2d239fcf7c5e1d9c721baaedb..b6e10ed22858f8e0b1645db704ca2634272f9258 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_false.c +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_false.c @@ -1,594 +1,10 @@ /* Generated by Frama-C */ -typedef unsigned long size_t; -typedef unsigned long mp_limb_t; -typedef unsigned long mp_bitcnt_t; -struct __anonstruct___mpz_struct_6 { - int _mp_alloc ; - int _mp_size ; - mp_limb_t *_mp_d ; -}; -typedef struct __anonstruct___mpz_struct_6 __mpz_struct; -typedef mp_limb_t *mp_ptr; -typedef mp_limb_t const *mp_srcptr; -typedef long mp_size_t; -struct __anonstruct___mpq_struct_7 { - __mpz_struct _mp_num ; - __mpz_struct _mp_den ; -}; -typedef struct __anonstruct___mpq_struct_7 __mpq_struct; -typedef __mpz_struct const *mpz_srcptr; -typedef __mpz_struct *mpz_ptr; -typedef __mpq_struct const *mpq_srcptr; -typedef __mpq_struct *mpq_ptr; -/* compiler builtin: - long __builtin_expect(long, long); */ -/*@ assigns \nothing; */ -extern int printf(char const * __restrict __format , ...); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -extern void __gmpz_set(mpz_ptr, mpz_srcptr); -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -/*@ requires \valid(z1); - requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -extern void __gmpq_set(mpq_ptr, mpq_srcptr); -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_add_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n); -extern int __gmpn_perfect_square_p(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -extern mp_bitcnt_t __gmpn_popcount(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_sub_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpz_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_size >= 0) { __gmp_w->_mp_size = __gmp_w->_mp_size; } - else { __gmp_w->_mp_size = - __gmp_w->_mp_size; } - return; -} - -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)(~ ((unsigned int)0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= ~ ((unsigned long)0)) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)((unsigned short)(~ 0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -/*@ requires \valid(z); - assigns \nothing; */ -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) -{ - mp_ptr __gmp_p; - mp_size_t __gmp_n; - mp_limb_t __gmp_l; - mp_limb_t tmp; - __gmp_p = z->_mp_d; - __gmp_n = (long)z->_mp_size; - __gmp_l = *(__gmp_p + 0); - if (__gmp_n != (mp_size_t)0) { tmp = __gmp_l; } - else { tmp = (unsigned long)0; } - return (tmp); -} - -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_result; - long tmp_1; - int tmp_0; - __gmp_result = (unsigned long)0; - { /*undefined sequence*/ - if (__gmp_n >= (mp_size_t)0) { - int tmp; - { /*undefined sequence*/ - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - ; - } - if (__gmp_n < (mp_size_t)tmp) { tmp_0 = 1; } - else { tmp_0 = 0; } - } - else { tmp_0 = 0; } - tmp_1 = __builtin_expect((long)(tmp_0 != 0),(long)1); - } - if (tmp_1) { __gmp_result = *(__gmp_z->_mp_d + __gmp_n); } - return (__gmp_result); -} - -/*@ requires \valid(z1); - requires \valid(z2); - assigns *z1; */ -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) -{ - if (z1 != z2) { __gmpz_set(z1,z2); } - z1->_mp_size = - z1->_mp_size; - return; -} - -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) -{ - mp_size_t __gmp_asize; - int __gmp_result; - long tmp; - __gmp_asize = (long)__gmp_a->_mp_size; - __gmp_result = __gmp_asize >= (mp_size_t)0; - tmp = __builtin_expect((long)((__gmp_asize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_perfect_square_p((mp_limb_t const *)__gmp_a->_mp_d, - __gmp_asize); - } - return (__gmp_result); -} - -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) -{ - mp_size_t __gmp_usize; - mp_bitcnt_t __gmp_result; - long tmp; - __gmp_usize = (long)__gmp_u->_mp_size; - if (__gmp_usize < (mp_size_t)0) { __gmp_result = ~ ((unsigned long)0); } - else { __gmp_result = (unsigned long)0; } - tmp = __builtin_expect((long)((__gmp_usize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_popcount((mp_limb_t const *)__gmp_u->_mp_d, - __gmp_usize); - } - return (__gmp_result); -} - -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - __gmpz_tdiv_q(__gmp_w,& __gmp_u->_mp_num,& __gmp_u->_mp_den); - return; -} - -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) -{ - size_t __retres; - int tmp; - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - __retres = (unsigned long)tmp; - return (__retres); -} - -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_num._mp_size >= 0) { - __gmp_w->_mp_num._mp_size = __gmp_w->_mp_num._mp_size; - } - else { __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; } - return; -} - -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; - return; -} - -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_1; - tmp_1 = __gmpn_add_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_1) { - while (1) { - mp_size_t tmp; - mp_limb_t tmp_0; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - tmp_0 = (__gmp_x + (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - *(__gmp_wp + tmp) = tmp_0; - } - if (! (tmp_0 == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x + __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_r < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x + (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_r < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) -{ - int __gmp_result; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_y; - __gmp_result = 0; - __gmp_i = __gmp_size; - while (1) { - __gmp_i -= (mp_size_t)1; - if (! (__gmp_i >= (mp_size_t)0)) { break; } - __gmp_x = *(__gmp_xp + __gmp_i); - __gmp_y = *(__gmp_yp + __gmp_i); - if (__gmp_x != __gmp_y) { - if (__gmp_x > __gmp_y) { __gmp_result = 1; } - else { __gmp_result = -1; } - break; - } - } - } - - break; - } - return (__gmp_result); -} - -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_0; - tmp_0 = __gmpn_sub_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_0) { - while (1) { - mp_size_t tmp; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - *(__gmp_wp + tmp) = (__gmp_x - (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - } - if (! (__gmp_x == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x - __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_x < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x - (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_x < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_ul; - mp_limb_t __gmp_cy; - __gmp_cy = (unsigned long)0; - while (1) { - { - mp_srcptr tmp; - mp_ptr tmp_0; - { /*undefined sequence*/ tmp = __gmp_up; __gmp_up ++; __gmp_ul = *tmp; - } - { /*undefined sequence*/ - tmp_0 = __gmp_rp; - __gmp_rp ++; - *tmp_0 = - __gmp_ul - __gmp_cy; - } - __gmp_cy |= (unsigned long)(__gmp_ul != (mp_limb_t)0); - } - - __gmp_n -= (mp_size_t)1; - if (! (__gmp_n != (mp_size_t)0)) { break; } - } - return (__gmp_cy); -} - /*@ terminates \false; ensures \false; assigns \nothing; */ extern void exit(int status); +/*@ assigns \nothing; */ +extern int printf(char const * , ...); void e_acsl_fail(char *msg) { printf("%s\n",msg); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_function_contract.c b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_function_contract.c index ddfe3af68cfec11512ea924d04127e76782c8546..84f0c414e6641eb1a07e57f6ce66eeae5d0febf2 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_function_contract.c +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_function_contract.c @@ -1,59 +1,11 @@ /* Generated by Frama-C */ -typedef unsigned long size_t; -typedef unsigned long mp_limb_t; -typedef unsigned long mp_bitcnt_t; -struct __anonstruct___mpz_struct_6 { +struct __anonstruct___mpz_struct_1 { int _mp_alloc ; int _mp_size ; - mp_limb_t *_mp_d ; + unsigned long *_mp_d ; }; -typedef struct __anonstruct___mpz_struct_6 __mpz_struct; +typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; -typedef mp_limb_t *mp_ptr; -typedef mp_limb_t const *mp_srcptr; -typedef long mp_size_t; -struct __anonstruct___mpq_struct_7 { - __mpz_struct _mp_num ; - __mpz_struct _mp_den ; -}; -typedef struct __anonstruct___mpq_struct_7 __mpq_struct; -typedef __mpz_struct const *mpz_srcptr; -typedef __mpz_struct *mpz_ptr; -typedef __mpq_struct const *mpq_srcptr; -typedef __mpq_struct *mpq_ptr; -/* compiler builtin: - long __builtin_expect(long, long); */ -/*@ assigns \nothing; */ -extern int printf(char const * __restrict __format , ...); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u); -/*@ requires \valid(z1); - requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_add(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -/*@ requires \valid(x); - assigns *x; */ -extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); -/*@ requires \valid(z1); - requires \valid(z2); - assigns \nothing; */ -extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); /*@ ensures \valid(\old(x)); assigns *x; */ extern void __gmpz_init(__mpz_struct * /*[1]*/ x); @@ -61,559 +13,28 @@ extern void __gmpz_init(__mpz_struct * /*[1]*/ x); assigns *z; assigns *z \from n; */ extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -extern void __gmpz_set(mpz_ptr, mpz_srcptr); -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); +/*@ requires \valid(x); + assigns *x; */ +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -extern void __gmpq_set(mpq_ptr, mpq_srcptr); -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_add_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n); -extern int __gmpn_perfect_square_p(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -extern mp_bitcnt_t __gmpn_popcount(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_sub_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpz_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_size >= 0) { __gmp_w->_mp_size = __gmp_w->_mp_size; } - else { __gmp_w->_mp_size = - __gmp_w->_mp_size; } - return; -} - -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)(~ ((unsigned int)0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= ~ ((unsigned long)0)) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)((unsigned short)(~ 0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -/*@ requires \valid(z); assigns \nothing; */ -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) -{ - mp_ptr __gmp_p; - mp_size_t __gmp_n; - mp_limb_t __gmp_l; - mp_limb_t tmp; - __gmp_p = z->_mp_d; - __gmp_n = (long)z->_mp_size; - __gmp_l = *(__gmp_p + 0); - if (__gmp_n != (mp_size_t)0) { tmp = __gmp_l; } - else { tmp = (unsigned long)0; } - return (tmp); -} - -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_result; - long tmp_1; - int tmp_0; - __gmp_result = (unsigned long)0; - { /*undefined sequence*/ - if (__gmp_n >= (mp_size_t)0) { - int tmp; - { /*undefined sequence*/ - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - ; - } - if (__gmp_n < (mp_size_t)tmp) { tmp_0 = 1; } - else { tmp_0 = 0; } - } - else { tmp_0 = 0; } - tmp_1 = __builtin_expect((long)(tmp_0 != 0),(long)1); - } - if (tmp_1) { __gmp_result = *(__gmp_z->_mp_d + __gmp_n); } - return (__gmp_result); -} - +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ requires \valid(z1); requires \valid(z2); - assigns *z1; */ -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) -{ - if (z1 != z2) { __gmpz_set(z1,z2); } - z1->_mp_size = - z1->_mp_size; - return; -} - -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) -{ - mp_size_t __gmp_asize; - int __gmp_result; - long tmp; - __gmp_asize = (long)__gmp_a->_mp_size; - __gmp_result = __gmp_asize >= (mp_size_t)0; - tmp = __builtin_expect((long)((__gmp_asize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_perfect_square_p((mp_limb_t const *)__gmp_a->_mp_d, - __gmp_asize); - } - return (__gmp_result); -} - -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) -{ - mp_size_t __gmp_usize; - mp_bitcnt_t __gmp_result; - long tmp; - __gmp_usize = (long)__gmp_u->_mp_size; - if (__gmp_usize < (mp_size_t)0) { __gmp_result = ~ ((unsigned long)0); } - else { __gmp_result = (unsigned long)0; } - tmp = __builtin_expect((long)((__gmp_usize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_popcount((mp_limb_t const *)__gmp_u->_mp_d, - __gmp_usize); - } - return (__gmp_result); -} - -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - __gmpz_tdiv_q(__gmp_w,& __gmp_u->_mp_num,& __gmp_u->_mp_den); - return; -} - -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) -{ - size_t __retres; - int tmp; - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - __retres = (unsigned long)tmp; - return (__retres); -} - -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_num._mp_size >= 0) { - __gmp_w->_mp_num._mp_size = __gmp_w->_mp_num._mp_size; - } - else { __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; } - return; -} - -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; - return; -} - -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_1; - tmp_1 = __gmpn_add_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_1) { - while (1) { - mp_size_t tmp; - mp_limb_t tmp_0; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - tmp_0 = (__gmp_x + (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - *(__gmp_wp + tmp) = tmp_0; - } - if (! (tmp_0 == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x + __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_r < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x + (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_r < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) -{ - int __gmp_result; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_y; - __gmp_result = 0; - __gmp_i = __gmp_size; - while (1) { - __gmp_i -= (mp_size_t)1; - if (! (__gmp_i >= (mp_size_t)0)) { break; } - __gmp_x = *(__gmp_xp + __gmp_i); - __gmp_y = *(__gmp_yp + __gmp_i); - if (__gmp_x != __gmp_y) { - if (__gmp_x > __gmp_y) { __gmp_result = 1; } - else { __gmp_result = -1; } - break; - } - } - } - - break; - } - return (__gmp_result); -} - -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_0; - tmp_0 = __gmpn_sub_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_0) { - while (1) { - mp_size_t tmp; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - *(__gmp_wp + tmp) = (__gmp_x - (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - } - if (! (__gmp_x == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x - __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_x < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x - (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_x < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_ul; - mp_limb_t __gmp_cy; - __gmp_cy = (unsigned long)0; - while (1) { - { - mp_srcptr tmp; - mp_ptr tmp_0; - { /*undefined sequence*/ tmp = __gmp_up; __gmp_up ++; __gmp_ul = *tmp; - } - { /*undefined sequence*/ - tmp_0 = __gmp_rp; - __gmp_rp ++; - *tmp_0 = - __gmp_ul - __gmp_cy; - } - __gmp_cy |= (unsigned long)(__gmp_ul != (mp_limb_t)0); - } - - __gmp_n -= (mp_size_t)1; - if (! (__gmp_n != (mp_size_t)0)) { break; } - } - return (__gmp_cy); -} - + requires \valid(z3); + assigns *z1; +*/ +extern void __gmpz_add(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2, + __mpz_struct const * /*[1]*/ z3); /*@ terminates \false; ensures \false; assigns \nothing; */ extern void exit(int status); +/*@ assigns \nothing; */ +extern int printf(char const * , ...); void e_acsl_fail(char *msg) { printf("%s\n",msg); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_integer_constant.c b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_integer_constant.c index 497cf8ae7a3758f35f7e89315577ce5c3c2d8d79..2ca74e3aa20b1220c100b5497af0480d153238ba 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_integer_constant.c +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_integer_constant.c @@ -1,608 +1,29 @@ /* Generated by Frama-C */ -typedef unsigned long size_t; -typedef unsigned long mp_limb_t; -typedef unsigned long mp_bitcnt_t; -struct __anonstruct___mpz_struct_6 { +struct __anonstruct___mpz_struct_1 { int _mp_alloc ; int _mp_size ; - mp_limb_t *_mp_d ; + unsigned long *_mp_d ; }; -typedef struct __anonstruct___mpz_struct_6 __mpz_struct; +typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; -typedef mp_limb_t *mp_ptr; -typedef mp_limb_t const *mp_srcptr; -typedef long mp_size_t; -struct __anonstruct___mpq_struct_7 { - __mpz_struct _mp_num ; - __mpz_struct _mp_den ; -}; -typedef struct __anonstruct___mpq_struct_7 __mpq_struct; -typedef __mpz_struct const *mpz_srcptr; -typedef __mpz_struct *mpz_ptr; -typedef __mpq_struct const *mpq_srcptr; -typedef __mpq_struct *mpq_ptr; -/* compiler builtin: - long __builtin_expect(long, long); */ -/*@ assigns \nothing; */ -extern int printf(char const * __restrict __format , ...); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u); -/*@ requires \valid(x); - assigns *x; */ -extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); -/*@ requires \valid(z1); - requires \valid(z2); - assigns \nothing; */ -extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); /*@ ensures \valid(\old(z)); assigns *z; */ extern int __gmpz_init_set_str(__mpz_struct * /*[1]*/ z, char const *str, int base); -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -extern void __gmpz_set(mpz_ptr, mpz_srcptr); -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); +/*@ requires \valid(x); + assigns *x; */ +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -extern void __gmpq_set(mpq_ptr, mpq_srcptr); -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_add_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n); -extern int __gmpn_perfect_square_p(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -extern mp_bitcnt_t __gmpn_popcount(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_sub_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpz_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_size >= 0) { __gmp_w->_mp_size = __gmp_w->_mp_size; } - else { __gmp_w->_mp_size = - __gmp_w->_mp_size; } - return; -} - -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)(~ ((unsigned int)0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= ~ ((unsigned long)0)) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)((unsigned short)(~ 0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -/*@ requires \valid(z); assigns \nothing; */ -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) -{ - mp_ptr __gmp_p; - mp_size_t __gmp_n; - mp_limb_t __gmp_l; - mp_limb_t tmp; - __gmp_p = z->_mp_d; - __gmp_n = (long)z->_mp_size; - __gmp_l = *(__gmp_p + 0); - if (__gmp_n != (mp_size_t)0) { tmp = __gmp_l; } - else { tmp = (unsigned long)0; } - return (tmp); -} - -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_result; - long tmp_1; - int tmp_0; - __gmp_result = (unsigned long)0; - { /*undefined sequence*/ - if (__gmp_n >= (mp_size_t)0) { - int tmp; - { /*undefined sequence*/ - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - ; - } - if (__gmp_n < (mp_size_t)tmp) { tmp_0 = 1; } - else { tmp_0 = 0; } - } - else { tmp_0 = 0; } - tmp_1 = __builtin_expect((long)(tmp_0 != 0),(long)1); - } - if (tmp_1) { __gmp_result = *(__gmp_z->_mp_d + __gmp_n); } - return (__gmp_result); -} - -/*@ requires \valid(z1); - requires \valid(z2); - assigns *z1; */ -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) -{ - if (z1 != z2) { __gmpz_set(z1,z2); } - z1->_mp_size = - z1->_mp_size; - return; -} - -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) -{ - mp_size_t __gmp_asize; - int __gmp_result; - long tmp; - __gmp_asize = (long)__gmp_a->_mp_size; - __gmp_result = __gmp_asize >= (mp_size_t)0; - tmp = __builtin_expect((long)((__gmp_asize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_perfect_square_p((mp_limb_t const *)__gmp_a->_mp_d, - __gmp_asize); - } - return (__gmp_result); -} - -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) -{ - mp_size_t __gmp_usize; - mp_bitcnt_t __gmp_result; - long tmp; - __gmp_usize = (long)__gmp_u->_mp_size; - if (__gmp_usize < (mp_size_t)0) { __gmp_result = ~ ((unsigned long)0); } - else { __gmp_result = (unsigned long)0; } - tmp = __builtin_expect((long)((__gmp_usize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_popcount((mp_limb_t const *)__gmp_u->_mp_d, - __gmp_usize); - } - return (__gmp_result); -} - -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - __gmpz_tdiv_q(__gmp_w,& __gmp_u->_mp_num,& __gmp_u->_mp_den); - return; -} - -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) -{ - size_t __retres; - int tmp; - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - __retres = (unsigned long)tmp; - return (__retres); -} - -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_num._mp_size >= 0) { - __gmp_w->_mp_num._mp_size = __gmp_w->_mp_num._mp_size; - } - else { __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; } - return; -} - -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; - return; -} - -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_1; - tmp_1 = __gmpn_add_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_1) { - while (1) { - mp_size_t tmp; - mp_limb_t tmp_0; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - tmp_0 = (__gmp_x + (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - *(__gmp_wp + tmp) = tmp_0; - } - if (! (tmp_0 == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x + __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_r < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x + (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_r < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) -{ - int __gmp_result; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_y; - __gmp_result = 0; - __gmp_i = __gmp_size; - while (1) { - __gmp_i -= (mp_size_t)1; - if (! (__gmp_i >= (mp_size_t)0)) { break; } - __gmp_x = *(__gmp_xp + __gmp_i); - __gmp_y = *(__gmp_yp + __gmp_i); - if (__gmp_x != __gmp_y) { - if (__gmp_x > __gmp_y) { __gmp_result = 1; } - else { __gmp_result = -1; } - break; - } - } - } - - break; - } - return (__gmp_result); -} - -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_0; - tmp_0 = __gmpn_sub_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_0) { - while (1) { - mp_size_t tmp; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - *(__gmp_wp + tmp) = (__gmp_x - (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - } - if (! (__gmp_x == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x - __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_x < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x - (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_x < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_ul; - mp_limb_t __gmp_cy; - __gmp_cy = (unsigned long)0; - while (1) { - { - mp_srcptr tmp; - mp_ptr tmp_0; - { /*undefined sequence*/ tmp = __gmp_up; __gmp_up ++; __gmp_ul = *tmp; - } - { /*undefined sequence*/ - tmp_0 = __gmp_rp; - __gmp_rp ++; - *tmp_0 = - __gmp_ul - __gmp_cy; - } - __gmp_cy |= (unsigned long)(__gmp_ul != (mp_limb_t)0); - } - - __gmp_n -= (mp_size_t)1; - if (! (__gmp_n != (mp_size_t)0)) { break; } - } - return (__gmp_cy); -} - +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ terminates \false; ensures \false; assigns \nothing; */ extern void exit(int status); +/*@ assigns \nothing; */ +extern int printf(char const * , ...); void e_acsl_fail(char *msg) { printf("%s\n",msg); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_lazy.c b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_lazy.c index c920ee7bf2696b779a002e97ade9fc3a52ae1084..447aae04c8bfe3f8ab80db52866a4f36e1a27428 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_lazy.c +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_lazy.c @@ -1,608 +1,29 @@ /* Generated by Frama-C */ -typedef unsigned long size_t; -typedef unsigned long mp_limb_t; -typedef unsigned long mp_bitcnt_t; -struct __anonstruct___mpz_struct_6 { +struct __anonstruct___mpz_struct_1 { int _mp_alloc ; int _mp_size ; - mp_limb_t *_mp_d ; + unsigned long *_mp_d ; }; -typedef struct __anonstruct___mpz_struct_6 __mpz_struct; +typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; -typedef mp_limb_t *mp_ptr; -typedef mp_limb_t const *mp_srcptr; -typedef long mp_size_t; -struct __anonstruct___mpq_struct_7 { - __mpz_struct _mp_num ; - __mpz_struct _mp_den ; -}; -typedef struct __anonstruct___mpq_struct_7 __mpq_struct; -typedef __mpz_struct const *mpz_srcptr; -typedef __mpz_struct *mpz_ptr; -typedef __mpq_struct const *mpq_srcptr; -typedef __mpq_struct *mpq_ptr; -/* compiler builtin: - long __builtin_expect(long, long); */ -/*@ assigns \nothing; */ -extern int printf(char const * __restrict __format , ...); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u); -/*@ requires \valid(x); - assigns *x; */ -extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); -/*@ requires \valid(z1); - requires \valid(z2); - assigns \nothing; */ -extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); /*@ ensures \valid(\old(z)); assigns *z; assigns *z \from n; */ extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -extern void __gmpz_set(mpz_ptr, mpz_srcptr); -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); +/*@ requires \valid(x); + assigns *x; */ +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -extern void __gmpq_set(mpq_ptr, mpq_srcptr); -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_add_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n); -extern int __gmpn_perfect_square_p(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -extern mp_bitcnt_t __gmpn_popcount(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_sub_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpz_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_size >= 0) { __gmp_w->_mp_size = __gmp_w->_mp_size; } - else { __gmp_w->_mp_size = - __gmp_w->_mp_size; } - return; -} - -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)(~ ((unsigned int)0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= ~ ((unsigned long)0)) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)((unsigned short)(~ 0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -/*@ requires \valid(z); assigns \nothing; */ -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) -{ - mp_ptr __gmp_p; - mp_size_t __gmp_n; - mp_limb_t __gmp_l; - mp_limb_t tmp; - __gmp_p = z->_mp_d; - __gmp_n = (long)z->_mp_size; - __gmp_l = *(__gmp_p + 0); - if (__gmp_n != (mp_size_t)0) { tmp = __gmp_l; } - else { tmp = (unsigned long)0; } - return (tmp); -} - -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_result; - long tmp_1; - int tmp_0; - __gmp_result = (unsigned long)0; - { /*undefined sequence*/ - if (__gmp_n >= (mp_size_t)0) { - int tmp; - { /*undefined sequence*/ - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - ; - } - if (__gmp_n < (mp_size_t)tmp) { tmp_0 = 1; } - else { tmp_0 = 0; } - } - else { tmp_0 = 0; } - tmp_1 = __builtin_expect((long)(tmp_0 != 0),(long)1); - } - if (tmp_1) { __gmp_result = *(__gmp_z->_mp_d + __gmp_n); } - return (__gmp_result); -} - -/*@ requires \valid(z1); - requires \valid(z2); - assigns *z1; */ -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) -{ - if (z1 != z2) { __gmpz_set(z1,z2); } - z1->_mp_size = - z1->_mp_size; - return; -} - -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) -{ - mp_size_t __gmp_asize; - int __gmp_result; - long tmp; - __gmp_asize = (long)__gmp_a->_mp_size; - __gmp_result = __gmp_asize >= (mp_size_t)0; - tmp = __builtin_expect((long)((__gmp_asize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_perfect_square_p((mp_limb_t const *)__gmp_a->_mp_d, - __gmp_asize); - } - return (__gmp_result); -} - -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) -{ - mp_size_t __gmp_usize; - mp_bitcnt_t __gmp_result; - long tmp; - __gmp_usize = (long)__gmp_u->_mp_size; - if (__gmp_usize < (mp_size_t)0) { __gmp_result = ~ ((unsigned long)0); } - else { __gmp_result = (unsigned long)0; } - tmp = __builtin_expect((long)((__gmp_usize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_popcount((mp_limb_t const *)__gmp_u->_mp_d, - __gmp_usize); - } - return (__gmp_result); -} - -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - __gmpz_tdiv_q(__gmp_w,& __gmp_u->_mp_num,& __gmp_u->_mp_den); - return; -} - -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) -{ - size_t __retres; - int tmp; - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - __retres = (unsigned long)tmp; - return (__retres); -} - -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_num._mp_size >= 0) { - __gmp_w->_mp_num._mp_size = __gmp_w->_mp_num._mp_size; - } - else { __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; } - return; -} - -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; - return; -} - -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_1; - tmp_1 = __gmpn_add_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_1) { - while (1) { - mp_size_t tmp; - mp_limb_t tmp_0; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - tmp_0 = (__gmp_x + (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - *(__gmp_wp + tmp) = tmp_0; - } - if (! (tmp_0 == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x + __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_r < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x + (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_r < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) -{ - int __gmp_result; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_y; - __gmp_result = 0; - __gmp_i = __gmp_size; - while (1) { - __gmp_i -= (mp_size_t)1; - if (! (__gmp_i >= (mp_size_t)0)) { break; } - __gmp_x = *(__gmp_xp + __gmp_i); - __gmp_y = *(__gmp_yp + __gmp_i); - if (__gmp_x != __gmp_y) { - if (__gmp_x > __gmp_y) { __gmp_result = 1; } - else { __gmp_result = -1; } - break; - } - } - } - - break; - } - return (__gmp_result); -} - -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_0; - tmp_0 = __gmpn_sub_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_0) { - while (1) { - mp_size_t tmp; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - *(__gmp_wp + tmp) = (__gmp_x - (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - } - if (! (__gmp_x == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x - __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_x < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x - (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_x < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_ul; - mp_limb_t __gmp_cy; - __gmp_cy = (unsigned long)0; - while (1) { - { - mp_srcptr tmp; - mp_ptr tmp_0; - { /*undefined sequence*/ tmp = __gmp_up; __gmp_up ++; __gmp_ul = *tmp; - } - { /*undefined sequence*/ - tmp_0 = __gmp_rp; - __gmp_rp ++; - *tmp_0 = - __gmp_ul - __gmp_cy; - } - __gmp_cy |= (unsigned long)(__gmp_ul != (mp_limb_t)0); - } - - __gmp_n -= (mp_size_t)1; - if (! (__gmp_n != (mp_size_t)0)) { break; } - } - return (__gmp_cy); -} - +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ terminates \false; ensures \false; assigns \nothing; */ extern void exit(int status); +/*@ assigns \nothing; */ +extern int printf(char const * , ...); void e_acsl_fail(char *msg) { printf("%s\n",msg); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_nested_code_annot.c b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_nested_code_annot.c index 81d704652fdd433e7a86686d81bfe7d085f2440a..b105ed79e39cc555b674f1088901283bb6c2f180 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_nested_code_annot.c +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_nested_code_annot.c @@ -1,608 +1,29 @@ /* Generated by Frama-C */ -typedef unsigned long size_t; -typedef unsigned long mp_limb_t; -typedef unsigned long mp_bitcnt_t; -struct __anonstruct___mpz_struct_6 { +struct __anonstruct___mpz_struct_1 { int _mp_alloc ; int _mp_size ; - mp_limb_t *_mp_d ; + unsigned long *_mp_d ; }; -typedef struct __anonstruct___mpz_struct_6 __mpz_struct; +typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; -typedef mp_limb_t *mp_ptr; -typedef mp_limb_t const *mp_srcptr; -typedef long mp_size_t; -struct __anonstruct___mpq_struct_7 { - __mpz_struct _mp_num ; - __mpz_struct _mp_den ; -}; -typedef struct __anonstruct___mpq_struct_7 __mpq_struct; -typedef __mpz_struct const *mpz_srcptr; -typedef __mpz_struct *mpz_ptr; -typedef __mpq_struct const *mpq_srcptr; -typedef __mpq_struct *mpq_ptr; -/* compiler builtin: - long __builtin_expect(long, long); */ -/*@ assigns \nothing; */ -extern int printf(char const * __restrict __format , ...); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u); -/*@ requires \valid(x); - assigns *x; */ -extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); -/*@ requires \valid(z1); - requires \valid(z2); - assigns \nothing; */ -extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); /*@ ensures \valid(\old(z)); assigns *z; assigns *z \from n; */ extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -extern void __gmpz_set(mpz_ptr, mpz_srcptr); -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); +/*@ requires \valid(x); + assigns *x; */ +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -extern void __gmpq_set(mpq_ptr, mpq_srcptr); -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_add_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n); -extern int __gmpn_perfect_square_p(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -extern mp_bitcnt_t __gmpn_popcount(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_sub_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpz_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_size >= 0) { __gmp_w->_mp_size = __gmp_w->_mp_size; } - else { __gmp_w->_mp_size = - __gmp_w->_mp_size; } - return; -} - -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)(~ ((unsigned int)0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= ~ ((unsigned long)0)) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)((unsigned short)(~ 0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -/*@ requires \valid(z); assigns \nothing; */ -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) -{ - mp_ptr __gmp_p; - mp_size_t __gmp_n; - mp_limb_t __gmp_l; - mp_limb_t tmp; - __gmp_p = z->_mp_d; - __gmp_n = (long)z->_mp_size; - __gmp_l = *(__gmp_p + 0); - if (__gmp_n != (mp_size_t)0) { tmp = __gmp_l; } - else { tmp = (unsigned long)0; } - return (tmp); -} - -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_result; - long tmp_1; - int tmp_0; - __gmp_result = (unsigned long)0; - { /*undefined sequence*/ - if (__gmp_n >= (mp_size_t)0) { - int tmp; - { /*undefined sequence*/ - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - ; - } - if (__gmp_n < (mp_size_t)tmp) { tmp_0 = 1; } - else { tmp_0 = 0; } - } - else { tmp_0 = 0; } - tmp_1 = __builtin_expect((long)(tmp_0 != 0),(long)1); - } - if (tmp_1) { __gmp_result = *(__gmp_z->_mp_d + __gmp_n); } - return (__gmp_result); -} - -/*@ requires \valid(z1); - requires \valid(z2); - assigns *z1; */ -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) -{ - if (z1 != z2) { __gmpz_set(z1,z2); } - z1->_mp_size = - z1->_mp_size; - return; -} - -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) -{ - mp_size_t __gmp_asize; - int __gmp_result; - long tmp; - __gmp_asize = (long)__gmp_a->_mp_size; - __gmp_result = __gmp_asize >= (mp_size_t)0; - tmp = __builtin_expect((long)((__gmp_asize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_perfect_square_p((mp_limb_t const *)__gmp_a->_mp_d, - __gmp_asize); - } - return (__gmp_result); -} - -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) -{ - mp_size_t __gmp_usize; - mp_bitcnt_t __gmp_result; - long tmp; - __gmp_usize = (long)__gmp_u->_mp_size; - if (__gmp_usize < (mp_size_t)0) { __gmp_result = ~ ((unsigned long)0); } - else { __gmp_result = (unsigned long)0; } - tmp = __builtin_expect((long)((__gmp_usize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_popcount((mp_limb_t const *)__gmp_u->_mp_d, - __gmp_usize); - } - return (__gmp_result); -} - -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - __gmpz_tdiv_q(__gmp_w,& __gmp_u->_mp_num,& __gmp_u->_mp_den); - return; -} - -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) -{ - size_t __retres; - int tmp; - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - __retres = (unsigned long)tmp; - return (__retres); -} - -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_num._mp_size >= 0) { - __gmp_w->_mp_num._mp_size = __gmp_w->_mp_num._mp_size; - } - else { __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; } - return; -} - -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; - return; -} - -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_1; - tmp_1 = __gmpn_add_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_1) { - while (1) { - mp_size_t tmp; - mp_limb_t tmp_0; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - tmp_0 = (__gmp_x + (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - *(__gmp_wp + tmp) = tmp_0; - } - if (! (tmp_0 == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x + __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_r < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x + (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_r < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) -{ - int __gmp_result; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_y; - __gmp_result = 0; - __gmp_i = __gmp_size; - while (1) { - __gmp_i -= (mp_size_t)1; - if (! (__gmp_i >= (mp_size_t)0)) { break; } - __gmp_x = *(__gmp_xp + __gmp_i); - __gmp_y = *(__gmp_yp + __gmp_i); - if (__gmp_x != __gmp_y) { - if (__gmp_x > __gmp_y) { __gmp_result = 1; } - else { __gmp_result = -1; } - break; - } - } - } - - break; - } - return (__gmp_result); -} - -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_0; - tmp_0 = __gmpn_sub_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_0) { - while (1) { - mp_size_t tmp; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - *(__gmp_wp + tmp) = (__gmp_x - (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - } - if (! (__gmp_x == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x - __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_x < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x - (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_x < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_ul; - mp_limb_t __gmp_cy; - __gmp_cy = (unsigned long)0; - while (1) { - { - mp_srcptr tmp; - mp_ptr tmp_0; - { /*undefined sequence*/ tmp = __gmp_up; __gmp_up ++; __gmp_ul = *tmp; - } - { /*undefined sequence*/ - tmp_0 = __gmp_rp; - __gmp_rp ++; - *tmp_0 = - __gmp_ul - __gmp_cy; - } - __gmp_cy |= (unsigned long)(__gmp_ul != (mp_limb_t)0); - } - - __gmp_n -= (mp_size_t)1; - if (! (__gmp_n != (mp_size_t)0)) { break; } - } - return (__gmp_cy); -} - +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ terminates \false; ensures \false; assigns \nothing; */ extern void exit(int status); +/*@ assigns \nothing; */ +extern int printf(char const * , ...); void e_acsl_fail(char *msg) { printf("%s\n",msg); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_not.c b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_not.c index 87c89b1c2cdd063dadf17478392d23fb90392de9..73be4f6b637bcca7ebd23c677a48d55a3e7661b9 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_not.c +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_not.c @@ -1,594 +1,10 @@ /* Generated by Frama-C */ -typedef unsigned long size_t; -typedef unsigned long mp_limb_t; -typedef unsigned long mp_bitcnt_t; -struct __anonstruct___mpz_struct_6 { - int _mp_alloc ; - int _mp_size ; - mp_limb_t *_mp_d ; -}; -typedef struct __anonstruct___mpz_struct_6 __mpz_struct; -typedef mp_limb_t *mp_ptr; -typedef mp_limb_t const *mp_srcptr; -typedef long mp_size_t; -struct __anonstruct___mpq_struct_7 { - __mpz_struct _mp_num ; - __mpz_struct _mp_den ; -}; -typedef struct __anonstruct___mpq_struct_7 __mpq_struct; -typedef __mpz_struct const *mpz_srcptr; -typedef __mpz_struct *mpz_ptr; -typedef __mpq_struct const *mpq_srcptr; -typedef __mpq_struct *mpq_ptr; -/* compiler builtin: - long __builtin_expect(long, long); */ -/*@ assigns \nothing; */ -extern int printf(char const * __restrict __format , ...); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -extern void __gmpz_set(mpz_ptr, mpz_srcptr); -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -/*@ requires \valid(z1); - requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -extern void __gmpq_set(mpq_ptr, mpq_srcptr); -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_add_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n); -extern int __gmpn_perfect_square_p(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -extern mp_bitcnt_t __gmpn_popcount(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_sub_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpz_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_size >= 0) { __gmp_w->_mp_size = __gmp_w->_mp_size; } - else { __gmp_w->_mp_size = - __gmp_w->_mp_size; } - return; -} - -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)(~ ((unsigned int)0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= ~ ((unsigned long)0)) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)((unsigned short)(~ 0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -/*@ requires \valid(z); - assigns \nothing; */ -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) -{ - mp_ptr __gmp_p; - mp_size_t __gmp_n; - mp_limb_t __gmp_l; - mp_limb_t tmp; - __gmp_p = z->_mp_d; - __gmp_n = (long)z->_mp_size; - __gmp_l = *(__gmp_p + 0); - if (__gmp_n != (mp_size_t)0) { tmp = __gmp_l; } - else { tmp = (unsigned long)0; } - return (tmp); -} - -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_result; - long tmp_1; - int tmp_0; - __gmp_result = (unsigned long)0; - { /*undefined sequence*/ - if (__gmp_n >= (mp_size_t)0) { - int tmp; - { /*undefined sequence*/ - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - ; - } - if (__gmp_n < (mp_size_t)tmp) { tmp_0 = 1; } - else { tmp_0 = 0; } - } - else { tmp_0 = 0; } - tmp_1 = __builtin_expect((long)(tmp_0 != 0),(long)1); - } - if (tmp_1) { __gmp_result = *(__gmp_z->_mp_d + __gmp_n); } - return (__gmp_result); -} - -/*@ requires \valid(z1); - requires \valid(z2); - assigns *z1; */ -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) -{ - if (z1 != z2) { __gmpz_set(z1,z2); } - z1->_mp_size = - z1->_mp_size; - return; -} - -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) -{ - mp_size_t __gmp_asize; - int __gmp_result; - long tmp; - __gmp_asize = (long)__gmp_a->_mp_size; - __gmp_result = __gmp_asize >= (mp_size_t)0; - tmp = __builtin_expect((long)((__gmp_asize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_perfect_square_p((mp_limb_t const *)__gmp_a->_mp_d, - __gmp_asize); - } - return (__gmp_result); -} - -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) -{ - mp_size_t __gmp_usize; - mp_bitcnt_t __gmp_result; - long tmp; - __gmp_usize = (long)__gmp_u->_mp_size; - if (__gmp_usize < (mp_size_t)0) { __gmp_result = ~ ((unsigned long)0); } - else { __gmp_result = (unsigned long)0; } - tmp = __builtin_expect((long)((__gmp_usize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_popcount((mp_limb_t const *)__gmp_u->_mp_d, - __gmp_usize); - } - return (__gmp_result); -} - -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - __gmpz_tdiv_q(__gmp_w,& __gmp_u->_mp_num,& __gmp_u->_mp_den); - return; -} - -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) -{ - size_t __retres; - int tmp; - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - __retres = (unsigned long)tmp; - return (__retres); -} - -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_num._mp_size >= 0) { - __gmp_w->_mp_num._mp_size = __gmp_w->_mp_num._mp_size; - } - else { __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; } - return; -} - -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; - return; -} - -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_1; - tmp_1 = __gmpn_add_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_1) { - while (1) { - mp_size_t tmp; - mp_limb_t tmp_0; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - tmp_0 = (__gmp_x + (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - *(__gmp_wp + tmp) = tmp_0; - } - if (! (tmp_0 == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x + __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_r < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x + (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_r < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) -{ - int __gmp_result; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_y; - __gmp_result = 0; - __gmp_i = __gmp_size; - while (1) { - __gmp_i -= (mp_size_t)1; - if (! (__gmp_i >= (mp_size_t)0)) { break; } - __gmp_x = *(__gmp_xp + __gmp_i); - __gmp_y = *(__gmp_yp + __gmp_i); - if (__gmp_x != __gmp_y) { - if (__gmp_x > __gmp_y) { __gmp_result = 1; } - else { __gmp_result = -1; } - break; - } - } - } - - break; - } - return (__gmp_result); -} - -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_0; - tmp_0 = __gmpn_sub_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_0) { - while (1) { - mp_size_t tmp; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - *(__gmp_wp + tmp) = (__gmp_x - (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - } - if (! (__gmp_x == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x - __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_x < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x - (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_x < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_ul; - mp_limb_t __gmp_cy; - __gmp_cy = (unsigned long)0; - while (1) { - { - mp_srcptr tmp; - mp_ptr tmp_0; - { /*undefined sequence*/ tmp = __gmp_up; __gmp_up ++; __gmp_ul = *tmp; - } - { /*undefined sequence*/ - tmp_0 = __gmp_rp; - __gmp_rp ++; - *tmp_0 = - __gmp_ul - __gmp_cy; - } - __gmp_cy |= (unsigned long)(__gmp_ul != (mp_limb_t)0); - } - - __gmp_n -= (mp_size_t)1; - if (! (__gmp_n != (mp_size_t)0)) { break; } - } - return (__gmp_cy); -} - /*@ terminates \false; ensures \false; assigns \nothing; */ extern void exit(int status); +/*@ assigns \nothing; */ +extern int printf(char const * , ...); void e_acsl_fail(char *msg) { printf("%s\n",msg); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_null.c b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_null.c index 85497dcc151f3858ee174c5fcad56c3f87847d4a..80018634e1f0475f4ceef2e9d0beaf156a73b2ca 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_null.c +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_null.c @@ -1,594 +1,10 @@ /* Generated by Frama-C */ -typedef unsigned long size_t; -typedef unsigned long mp_limb_t; -typedef unsigned long mp_bitcnt_t; -struct __anonstruct___mpz_struct_6 { - int _mp_alloc ; - int _mp_size ; - mp_limb_t *_mp_d ; -}; -typedef struct __anonstruct___mpz_struct_6 __mpz_struct; -typedef mp_limb_t *mp_ptr; -typedef mp_limb_t const *mp_srcptr; -typedef long mp_size_t; -struct __anonstruct___mpq_struct_7 { - __mpz_struct _mp_num ; - __mpz_struct _mp_den ; -}; -typedef struct __anonstruct___mpq_struct_7 __mpq_struct; -typedef __mpz_struct const *mpz_srcptr; -typedef __mpz_struct *mpz_ptr; -typedef __mpq_struct const *mpq_srcptr; -typedef __mpq_struct *mpq_ptr; -/* compiler builtin: - long __builtin_expect(long, long); */ -/*@ assigns \nothing; */ -extern int printf(char const * __restrict __format , ...); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -extern void __gmpz_set(mpz_ptr, mpz_srcptr); -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -/*@ requires \valid(z1); - requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -extern void __gmpq_set(mpq_ptr, mpq_srcptr); -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_add_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n); -extern int __gmpn_perfect_square_p(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -extern mp_bitcnt_t __gmpn_popcount(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_sub_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpz_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_size >= 0) { __gmp_w->_mp_size = __gmp_w->_mp_size; } - else { __gmp_w->_mp_size = - __gmp_w->_mp_size; } - return; -} - -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)(~ ((unsigned int)0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= ~ ((unsigned long)0)) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)((unsigned short)(~ 0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -/*@ requires \valid(z); - assigns \nothing; */ -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) -{ - mp_ptr __gmp_p; - mp_size_t __gmp_n; - mp_limb_t __gmp_l; - mp_limb_t tmp; - __gmp_p = z->_mp_d; - __gmp_n = (long)z->_mp_size; - __gmp_l = *(__gmp_p + 0); - if (__gmp_n != (mp_size_t)0) { tmp = __gmp_l; } - else { tmp = (unsigned long)0; } - return (tmp); -} - -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_result; - long tmp_1; - int tmp_0; - __gmp_result = (unsigned long)0; - { /*undefined sequence*/ - if (__gmp_n >= (mp_size_t)0) { - int tmp; - { /*undefined sequence*/ - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - ; - } - if (__gmp_n < (mp_size_t)tmp) { tmp_0 = 1; } - else { tmp_0 = 0; } - } - else { tmp_0 = 0; } - tmp_1 = __builtin_expect((long)(tmp_0 != 0),(long)1); - } - if (tmp_1) { __gmp_result = *(__gmp_z->_mp_d + __gmp_n); } - return (__gmp_result); -} - -/*@ requires \valid(z1); - requires \valid(z2); - assigns *z1; */ -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) -{ - if (z1 != z2) { __gmpz_set(z1,z2); } - z1->_mp_size = - z1->_mp_size; - return; -} - -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) -{ - mp_size_t __gmp_asize; - int __gmp_result; - long tmp; - __gmp_asize = (long)__gmp_a->_mp_size; - __gmp_result = __gmp_asize >= (mp_size_t)0; - tmp = __builtin_expect((long)((__gmp_asize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_perfect_square_p((mp_limb_t const *)__gmp_a->_mp_d, - __gmp_asize); - } - return (__gmp_result); -} - -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) -{ - mp_size_t __gmp_usize; - mp_bitcnt_t __gmp_result; - long tmp; - __gmp_usize = (long)__gmp_u->_mp_size; - if (__gmp_usize < (mp_size_t)0) { __gmp_result = ~ ((unsigned long)0); } - else { __gmp_result = (unsigned long)0; } - tmp = __builtin_expect((long)((__gmp_usize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_popcount((mp_limb_t const *)__gmp_u->_mp_d, - __gmp_usize); - } - return (__gmp_result); -} - -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - __gmpz_tdiv_q(__gmp_w,& __gmp_u->_mp_num,& __gmp_u->_mp_den); - return; -} - -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) -{ - size_t __retres; - int tmp; - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - __retres = (unsigned long)tmp; - return (__retres); -} - -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_num._mp_size >= 0) { - __gmp_w->_mp_num._mp_size = __gmp_w->_mp_num._mp_size; - } - else { __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; } - return; -} - -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; - return; -} - -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_1; - tmp_1 = __gmpn_add_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_1) { - while (1) { - mp_size_t tmp; - mp_limb_t tmp_0; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - tmp_0 = (__gmp_x + (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - *(__gmp_wp + tmp) = tmp_0; - } - if (! (tmp_0 == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x + __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_r < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x + (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_r < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) -{ - int __gmp_result; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_y; - __gmp_result = 0; - __gmp_i = __gmp_size; - while (1) { - __gmp_i -= (mp_size_t)1; - if (! (__gmp_i >= (mp_size_t)0)) { break; } - __gmp_x = *(__gmp_xp + __gmp_i); - __gmp_y = *(__gmp_yp + __gmp_i); - if (__gmp_x != __gmp_y) { - if (__gmp_x > __gmp_y) { __gmp_result = 1; } - else { __gmp_result = -1; } - break; - } - } - } - - break; - } - return (__gmp_result); -} - -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_0; - tmp_0 = __gmpn_sub_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_0) { - while (1) { - mp_size_t tmp; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - *(__gmp_wp + tmp) = (__gmp_x - (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - } - if (! (__gmp_x == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x - __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_x < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x - (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_x < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_ul; - mp_limb_t __gmp_cy; - __gmp_cy = (unsigned long)0; - while (1) { - { - mp_srcptr tmp; - mp_ptr tmp_0; - { /*undefined sequence*/ tmp = __gmp_up; __gmp_up ++; __gmp_ul = *tmp; - } - { /*undefined sequence*/ - tmp_0 = __gmp_rp; - __gmp_rp ++; - *tmp_0 = - __gmp_ul - __gmp_cy; - } - __gmp_cy |= (unsigned long)(__gmp_ul != (mp_limb_t)0); - } - - __gmp_n -= (mp_size_t)1; - if (! (__gmp_n != (mp_size_t)0)) { break; } - } - return (__gmp_cy); -} - /*@ terminates \false; ensures \false; assigns \nothing; */ extern void exit(int status); +/*@ assigns \nothing; */ +extern int printf(char const * , ...); void e_acsl_fail(char *msg) { printf("%s\n",msg); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_other_constants.c b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_other_constants.c index 6b78bf90783e4b4ea6c5291dbdae8ef027e3a9b4..725e95c783c57f4c81fa0c9ac51c209895c64946 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_other_constants.c +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_other_constants.c @@ -1,612 +1,33 @@ /* Generated by Frama-C */ -typedef unsigned long size_t; -typedef unsigned long mp_limb_t; -typedef unsigned long mp_bitcnt_t; -struct __anonstruct___mpz_struct_6 { +struct __anonstruct___mpz_struct_1 { int _mp_alloc ; int _mp_size ; - mp_limb_t *_mp_d ; + unsigned long *_mp_d ; }; -typedef struct __anonstruct___mpz_struct_6 __mpz_struct; +typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; -typedef mp_limb_t *mp_ptr; -typedef mp_limb_t const *mp_srcptr; -typedef long mp_size_t; -struct __anonstruct___mpq_struct_7 { - __mpz_struct _mp_num ; - __mpz_struct _mp_den ; -}; -typedef struct __anonstruct___mpq_struct_7 __mpq_struct; -typedef __mpz_struct const *mpz_srcptr; -typedef __mpz_struct *mpz_ptr; -typedef __mpq_struct const *mpq_srcptr; -typedef __mpq_struct *mpq_ptr; enum bool { false = 0, true = 1 }; -/* compiler builtin: - long __builtin_expect(long, long); */ -/*@ assigns \nothing; */ -extern int printf(char const * __restrict __format , ...); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u); -/*@ requires \valid(x); - assigns *x; */ -extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); -/*@ requires \valid(z1); - requires \valid(z2); - assigns \nothing; */ -extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); /*@ ensures \valid(\old(z)); assigns *z; assigns *z \from n; */ extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -extern void __gmpz_set(mpz_ptr, mpz_srcptr); -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); +/*@ requires \valid(x); + assigns *x; */ +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -extern void __gmpq_set(mpq_ptr, mpq_srcptr); -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_add_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n); -extern int __gmpn_perfect_square_p(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -extern mp_bitcnt_t __gmpn_popcount(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_sub_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpz_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_size >= 0) { __gmp_w->_mp_size = __gmp_w->_mp_size; } - else { __gmp_w->_mp_size = - __gmp_w->_mp_size; } - return; -} - -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)(~ ((unsigned int)0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= ~ ((unsigned long)0)) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)((unsigned short)(~ 0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -/*@ requires \valid(z); assigns \nothing; */ -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) -{ - mp_ptr __gmp_p; - mp_size_t __gmp_n; - mp_limb_t __gmp_l; - mp_limb_t tmp; - __gmp_p = z->_mp_d; - __gmp_n = (long)z->_mp_size; - __gmp_l = *(__gmp_p + 0); - if (__gmp_n != (mp_size_t)0) { tmp = __gmp_l; } - else { tmp = (unsigned long)0; } - return (tmp); -} - -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_result; - long tmp_1; - int tmp_0; - __gmp_result = (unsigned long)0; - { /*undefined sequence*/ - if (__gmp_n >= (mp_size_t)0) { - int tmp; - { /*undefined sequence*/ - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - ; - } - if (__gmp_n < (mp_size_t)tmp) { tmp_0 = 1; } - else { tmp_0 = 0; } - } - else { tmp_0 = 0; } - tmp_1 = __builtin_expect((long)(tmp_0 != 0),(long)1); - } - if (tmp_1) { __gmp_result = *(__gmp_z->_mp_d + __gmp_n); } - return (__gmp_result); -} - -/*@ requires \valid(z1); - requires \valid(z2); - assigns *z1; */ -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) -{ - if (z1 != z2) { __gmpz_set(z1,z2); } - z1->_mp_size = - z1->_mp_size; - return; -} - -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) -{ - mp_size_t __gmp_asize; - int __gmp_result; - long tmp; - __gmp_asize = (long)__gmp_a->_mp_size; - __gmp_result = __gmp_asize >= (mp_size_t)0; - tmp = __builtin_expect((long)((__gmp_asize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_perfect_square_p((mp_limb_t const *)__gmp_a->_mp_d, - __gmp_asize); - } - return (__gmp_result); -} - -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) -{ - mp_size_t __gmp_usize; - mp_bitcnt_t __gmp_result; - long tmp; - __gmp_usize = (long)__gmp_u->_mp_size; - if (__gmp_usize < (mp_size_t)0) { __gmp_result = ~ ((unsigned long)0); } - else { __gmp_result = (unsigned long)0; } - tmp = __builtin_expect((long)((__gmp_usize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_popcount((mp_limb_t const *)__gmp_u->_mp_d, - __gmp_usize); - } - return (__gmp_result); -} - -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - __gmpz_tdiv_q(__gmp_w,& __gmp_u->_mp_num,& __gmp_u->_mp_den); - return; -} - -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) -{ - size_t __retres; - int tmp; - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - __retres = (unsigned long)tmp; - return (__retres); -} - -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_num._mp_size >= 0) { - __gmp_w->_mp_num._mp_size = __gmp_w->_mp_num._mp_size; - } - else { __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; } - return; -} - -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; - return; -} - -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_1; - tmp_1 = __gmpn_add_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_1) { - while (1) { - mp_size_t tmp; - mp_limb_t tmp_0; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - tmp_0 = (__gmp_x + (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - *(__gmp_wp + tmp) = tmp_0; - } - if (! (tmp_0 == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x + __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_r < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x + (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_r < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) -{ - int __gmp_result; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_y; - __gmp_result = 0; - __gmp_i = __gmp_size; - while (1) { - __gmp_i -= (mp_size_t)1; - if (! (__gmp_i >= (mp_size_t)0)) { break; } - __gmp_x = *(__gmp_xp + __gmp_i); - __gmp_y = *(__gmp_yp + __gmp_i); - if (__gmp_x != __gmp_y) { - if (__gmp_x > __gmp_y) { __gmp_result = 1; } - else { __gmp_result = -1; } - break; - } - } - } - - break; - } - return (__gmp_result); -} - -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_0; - tmp_0 = __gmpn_sub_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_0) { - while (1) { - mp_size_t tmp; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - *(__gmp_wp + tmp) = (__gmp_x - (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - } - if (! (__gmp_x == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x - __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_x < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x - (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_x < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_ul; - mp_limb_t __gmp_cy; - __gmp_cy = (unsigned long)0; - while (1) { - { - mp_srcptr tmp; - mp_ptr tmp_0; - { /*undefined sequence*/ tmp = __gmp_up; __gmp_up ++; __gmp_ul = *tmp; - } - { /*undefined sequence*/ - tmp_0 = __gmp_rp; - __gmp_rp ++; - *tmp_0 = - __gmp_ul - __gmp_cy; - } - __gmp_cy |= (unsigned long)(__gmp_ul != (mp_limb_t)0); - } - - __gmp_n -= (mp_size_t)1; - if (! (__gmp_n != (mp_size_t)0)) { break; } - } - return (__gmp_cy); -} - +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ terminates \false; ensures \false; assigns \nothing; */ extern void exit(int status); +/*@ assigns \nothing; */ +extern int printf(char const * , ...); void e_acsl_fail(char *msg) { printf("%s\n",msg); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_ptr.c b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_ptr.c index 6ab9d106e25fa55d1d047a97ae93a34c3cd36e0e..6174f6a082247822ee3ee51664a4c5e7db925bf0 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_ptr.c +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_ptr.c @@ -1,63 +1,11 @@ /* Generated by Frama-C */ -typedef unsigned long size_t; -typedef unsigned long mp_limb_t; -typedef unsigned long mp_bitcnt_t; -struct __anonstruct___mpz_struct_6 { +struct __anonstruct___mpz_struct_1 { int _mp_alloc ; int _mp_size ; - mp_limb_t *_mp_d ; + unsigned long *_mp_d ; }; -typedef struct __anonstruct___mpz_struct_6 __mpz_struct; +typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; -typedef mp_limb_t *mp_ptr; -typedef mp_limb_t const *mp_srcptr; -typedef long mp_size_t; -struct __anonstruct___mpq_struct_7 { - __mpz_struct _mp_num ; - __mpz_struct _mp_den ; -}; -typedef struct __anonstruct___mpq_struct_7 __mpq_struct; -typedef __mpz_struct const *mpz_srcptr; -typedef __mpz_struct *mpz_ptr; -typedef __mpq_struct const *mpq_srcptr; -typedef __mpq_struct *mpq_ptr; -/* compiler builtin: - long __builtin_expect(long, long); */ -/*@ assigns \nothing; */ -extern int printf(char const * __restrict __format , ...); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u); -/*@ requires \valid(z1); - requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_add(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -/*@ requires \valid(x); - assigns *x; */ -extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); -/*@ requires \valid(z1); - requires \valid(z2); - assigns \nothing; */ -extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -/*@ requires \valid(z); - assigns \nothing; */ -extern long __gmpz_get_si(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); /*@ ensures \valid(\old(x)); assigns *x; */ extern void __gmpz_init(__mpz_struct * /*[1]*/ x); @@ -65,24 +13,22 @@ extern void __gmpz_init(__mpz_struct * /*[1]*/ x); assigns *z; assigns *z \from n; */ extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); +/*@ requires \valid(x); + assigns *x; */ +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); +/*@ requires \valid(z1); + requires \valid(z2); + assigns \nothing; */ +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ requires \valid(z1); requires \valid(z2); requires \valid(z3); assigns *z1; */ -extern void __gmpz_mul(__mpz_struct * /*[1]*/ z1, +extern void __gmpz_add(__mpz_struct * /*[1]*/ z1, __mpz_struct const * /*[1]*/ z2, __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -extern void __gmpz_set(mpz_ptr, mpz_srcptr); -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); /*@ requires \valid(z1); requires \valid(z2); requires \valid(z3); @@ -96,544 +42,26 @@ extern void __gmpz_sub(__mpz_struct * /*[1]*/ z1, requires \valid(z3); assigns *z1; */ +extern void __gmpz_mul(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2, + __mpz_struct const * /*[1]*/ z3); +/*@ requires \valid(z1); + requires \valid(z2); + requires \valid(z3); + assigns *z1; +*/ extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, __mpz_struct const * /*[1]*/ z2, __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -extern void __gmpq_set(mpq_ptr, mpq_srcptr); -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_add_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n); -extern int __gmpn_perfect_square_p(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -extern mp_bitcnt_t __gmpn_popcount(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_sub_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpz_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_size >= 0) { __gmp_w->_mp_size = __gmp_w->_mp_size; } - else { __gmp_w->_mp_size = - __gmp_w->_mp_size; } - return; -} - -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)(~ ((unsigned int)0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= ~ ((unsigned long)0)) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)((unsigned short)(~ 0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - /*@ requires \valid(z); assigns \nothing; */ -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) -{ - mp_ptr __gmp_p; - mp_size_t __gmp_n; - mp_limb_t __gmp_l; - mp_limb_t tmp; - __gmp_p = z->_mp_d; - __gmp_n = (long)z->_mp_size; - __gmp_l = *(__gmp_p + 0); - if (__gmp_n != (mp_size_t)0) { tmp = __gmp_l; } - else { tmp = (unsigned long)0; } - return (tmp); -} - -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_result; - long tmp_1; - int tmp_0; - __gmp_result = (unsigned long)0; - { /*undefined sequence*/ - if (__gmp_n >= (mp_size_t)0) { - int tmp; - { /*undefined sequence*/ - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - ; - } - if (__gmp_n < (mp_size_t)tmp) { tmp_0 = 1; } - else { tmp_0 = 0; } - } - else { tmp_0 = 0; } - tmp_1 = __builtin_expect((long)(tmp_0 != 0),(long)1); - } - if (tmp_1) { __gmp_result = *(__gmp_z->_mp_d + __gmp_n); } - return (__gmp_result); -} - -/*@ requires \valid(z1); - requires \valid(z2); - assigns *z1; */ -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) -{ - if (z1 != z2) { __gmpz_set(z1,z2); } - z1->_mp_size = - z1->_mp_size; - return; -} - -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) -{ - mp_size_t __gmp_asize; - int __gmp_result; - long tmp; - __gmp_asize = (long)__gmp_a->_mp_size; - __gmp_result = __gmp_asize >= (mp_size_t)0; - tmp = __builtin_expect((long)((__gmp_asize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_perfect_square_p((mp_limb_t const *)__gmp_a->_mp_d, - __gmp_asize); - } - return (__gmp_result); -} - -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) -{ - mp_size_t __gmp_usize; - mp_bitcnt_t __gmp_result; - long tmp; - __gmp_usize = (long)__gmp_u->_mp_size; - if (__gmp_usize < (mp_size_t)0) { __gmp_result = ~ ((unsigned long)0); } - else { __gmp_result = (unsigned long)0; } - tmp = __builtin_expect((long)((__gmp_usize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_popcount((mp_limb_t const *)__gmp_u->_mp_d, - __gmp_usize); - } - return (__gmp_result); -} - -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - __gmpz_tdiv_q(__gmp_w,& __gmp_u->_mp_num,& __gmp_u->_mp_den); - return; -} - -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) -{ - size_t __retres; - int tmp; - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - __retres = (unsigned long)tmp; - return (__retres); -} - -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_num._mp_size >= 0) { - __gmp_w->_mp_num._mp_size = __gmp_w->_mp_num._mp_size; - } - else { __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; } - return; -} - -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; - return; -} - -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_1; - tmp_1 = __gmpn_add_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_1) { - while (1) { - mp_size_t tmp; - mp_limb_t tmp_0; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - tmp_0 = (__gmp_x + (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - *(__gmp_wp + tmp) = tmp_0; - } - if (! (tmp_0 == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x + __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_r < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x + (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_r < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) -{ - int __gmp_result; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_y; - __gmp_result = 0; - __gmp_i = __gmp_size; - while (1) { - __gmp_i -= (mp_size_t)1; - if (! (__gmp_i >= (mp_size_t)0)) { break; } - __gmp_x = *(__gmp_xp + __gmp_i); - __gmp_y = *(__gmp_yp + __gmp_i); - if (__gmp_x != __gmp_y) { - if (__gmp_x > __gmp_y) { __gmp_result = 1; } - else { __gmp_result = -1; } - break; - } - } - } - - break; - } - return (__gmp_result); -} - -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_0; - tmp_0 = __gmpn_sub_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_0) { - while (1) { - mp_size_t tmp; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - *(__gmp_wp + tmp) = (__gmp_x - (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - } - if (! (__gmp_x == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x - __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_x < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x - (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_x < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_ul; - mp_limb_t __gmp_cy; - __gmp_cy = (unsigned long)0; - while (1) { - { - mp_srcptr tmp; - mp_ptr tmp_0; - { /*undefined sequence*/ tmp = __gmp_up; __gmp_up ++; __gmp_ul = *tmp; - } - { /*undefined sequence*/ - tmp_0 = __gmp_rp; - __gmp_rp ++; - *tmp_0 = - __gmp_ul - __gmp_cy; - } - __gmp_cy |= (unsigned long)(__gmp_ul != (mp_limb_t)0); - } - - __gmp_n -= (mp_size_t)1; - if (! (__gmp_n != (mp_size_t)0)) { break; } - } - return (__gmp_cy); -} - +extern long __gmpz_get_si(__mpz_struct const * /*[1]*/ z); /*@ terminates \false; ensures \false; assigns \nothing; */ extern void exit(int status); +/*@ assigns \nothing; */ +extern int printf(char const * , ...); void e_acsl_fail(char *msg) { printf("%s\n",msg); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_result.c b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_result.c index 46b82c22313392c2acac1160f5fbd7f4b4f3db1c..7b7b4df213411e33f12ef704692ac4ff6fcdea17 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_result.c +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_result.c @@ -1,55 +1,11 @@ /* Generated by Frama-C */ -typedef unsigned long size_t; -typedef unsigned long mp_limb_t; -typedef unsigned long mp_bitcnt_t; -struct __anonstruct___mpz_struct_6 { +struct __anonstruct___mpz_struct_1 { int _mp_alloc ; int _mp_size ; - mp_limb_t *_mp_d ; + unsigned long *_mp_d ; }; -typedef struct __anonstruct___mpz_struct_6 __mpz_struct; +typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; -typedef mp_limb_t *mp_ptr; -typedef mp_limb_t const *mp_srcptr; -typedef long mp_size_t; -struct __anonstruct___mpq_struct_7 { - __mpz_struct _mp_num ; - __mpz_struct _mp_den ; -}; -typedef struct __anonstruct___mpq_struct_7 __mpq_struct; -typedef __mpz_struct const *mpz_srcptr; -typedef __mpz_struct *mpz_ptr; -typedef __mpq_struct const *mpq_srcptr; -typedef __mpq_struct *mpq_ptr; -/* compiler builtin: - long __builtin_expect(long, long); */ -/*@ assigns \nothing; */ -extern int printf(char const * __restrict __format , ...); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u); -/*@ requires \valid(x); - assigns *x; */ -extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); -/*@ requires \valid(z1); - requires \valid(z2); - assigns \nothing; */ -extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -/*@ requires \valid(z); - assigns \nothing; */ -extern long __gmpz_get_si(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); /*@ ensures \valid(\old(x)); assigns *x; */ extern void __gmpz_init(__mpz_struct * /*[1]*/ x); @@ -57,16 +13,14 @@ extern void __gmpz_init(__mpz_struct * /*[1]*/ x); assigns *z; assigns *z \from n; */ extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -extern void __gmpz_set(mpz_ptr, mpz_srcptr); -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); +/*@ requires \valid(x); + assigns *x; */ +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); +/*@ requires \valid(z1); + requires \valid(z2); + assigns \nothing; */ +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ requires \valid(z1); requires \valid(z2); requires \valid(z3); @@ -75,549 +29,15 @@ __pure__)); extern void __gmpz_sub(__mpz_struct * /*[1]*/ z1, __mpz_struct const * /*[1]*/ z2, __mpz_struct const * /*[1]*/ z3); -/*@ requires \valid(z1); - requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -extern void __gmpq_set(mpq_ptr, mpq_srcptr); -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_add_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n); -extern int __gmpn_perfect_square_p(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -extern mp_bitcnt_t __gmpn_popcount(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_sub_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpz_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_size >= 0) { __gmp_w->_mp_size = __gmp_w->_mp_size; } - else { __gmp_w->_mp_size = - __gmp_w->_mp_size; } - return; -} - -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)(~ ((unsigned int)0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= ~ ((unsigned long)0)) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)((unsigned short)(~ 0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - /*@ requires \valid(z); assigns \nothing; */ -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) -{ - mp_ptr __gmp_p; - mp_size_t __gmp_n; - mp_limb_t __gmp_l; - mp_limb_t tmp; - __gmp_p = z->_mp_d; - __gmp_n = (long)z->_mp_size; - __gmp_l = *(__gmp_p + 0); - if (__gmp_n != (mp_size_t)0) { tmp = __gmp_l; } - else { tmp = (unsigned long)0; } - return (tmp); -} - -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_result; - long tmp_1; - int tmp_0; - __gmp_result = (unsigned long)0; - { /*undefined sequence*/ - if (__gmp_n >= (mp_size_t)0) { - int tmp; - { /*undefined sequence*/ - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - ; - } - if (__gmp_n < (mp_size_t)tmp) { tmp_0 = 1; } - else { tmp_0 = 0; } - } - else { tmp_0 = 0; } - tmp_1 = __builtin_expect((long)(tmp_0 != 0),(long)1); - } - if (tmp_1) { __gmp_result = *(__gmp_z->_mp_d + __gmp_n); } - return (__gmp_result); -} - -/*@ requires \valid(z1); - requires \valid(z2); - assigns *z1; */ -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) -{ - if (z1 != z2) { __gmpz_set(z1,z2); } - z1->_mp_size = - z1->_mp_size; - return; -} - -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) -{ - mp_size_t __gmp_asize; - int __gmp_result; - long tmp; - __gmp_asize = (long)__gmp_a->_mp_size; - __gmp_result = __gmp_asize >= (mp_size_t)0; - tmp = __builtin_expect((long)((__gmp_asize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_perfect_square_p((mp_limb_t const *)__gmp_a->_mp_d, - __gmp_asize); - } - return (__gmp_result); -} - -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) -{ - mp_size_t __gmp_usize; - mp_bitcnt_t __gmp_result; - long tmp; - __gmp_usize = (long)__gmp_u->_mp_size; - if (__gmp_usize < (mp_size_t)0) { __gmp_result = ~ ((unsigned long)0); } - else { __gmp_result = (unsigned long)0; } - tmp = __builtin_expect((long)((__gmp_usize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_popcount((mp_limb_t const *)__gmp_u->_mp_d, - __gmp_usize); - } - return (__gmp_result); -} - -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - __gmpz_tdiv_q(__gmp_w,& __gmp_u->_mp_num,& __gmp_u->_mp_den); - return; -} - -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) -{ - size_t __retres; - int tmp; - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - __retres = (unsigned long)tmp; - return (__retres); -} - -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_num._mp_size >= 0) { - __gmp_w->_mp_num._mp_size = __gmp_w->_mp_num._mp_size; - } - else { __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; } - return; -} - -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; - return; -} - -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_1; - tmp_1 = __gmpn_add_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_1) { - while (1) { - mp_size_t tmp; - mp_limb_t tmp_0; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - tmp_0 = (__gmp_x + (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - *(__gmp_wp + tmp) = tmp_0; - } - if (! (tmp_0 == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x + __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_r < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x + (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_r < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) -{ - int __gmp_result; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_y; - __gmp_result = 0; - __gmp_i = __gmp_size; - while (1) { - __gmp_i -= (mp_size_t)1; - if (! (__gmp_i >= (mp_size_t)0)) { break; } - __gmp_x = *(__gmp_xp + __gmp_i); - __gmp_y = *(__gmp_yp + __gmp_i); - if (__gmp_x != __gmp_y) { - if (__gmp_x > __gmp_y) { __gmp_result = 1; } - else { __gmp_result = -1; } - break; - } - } - } - - break; - } - return (__gmp_result); -} - -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_0; - tmp_0 = __gmpn_sub_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_0) { - while (1) { - mp_size_t tmp; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - *(__gmp_wp + tmp) = (__gmp_x - (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - } - if (! (__gmp_x == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x - __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_x < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x - (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_x < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_ul; - mp_limb_t __gmp_cy; - __gmp_cy = (unsigned long)0; - while (1) { - { - mp_srcptr tmp; - mp_ptr tmp_0; - { /*undefined sequence*/ tmp = __gmp_up; __gmp_up ++; __gmp_ul = *tmp; - } - { /*undefined sequence*/ - tmp_0 = __gmp_rp; - __gmp_rp ++; - *tmp_0 = - __gmp_ul - __gmp_cy; - } - __gmp_cy |= (unsigned long)(__gmp_ul != (mp_limb_t)0); - } - - __gmp_n -= (mp_size_t)1; - if (! (__gmp_n != (mp_size_t)0)) { break; } - } - return (__gmp_cy); -} - +extern long __gmpz_get_si(__mpz_struct const * /*[1]*/ z); /*@ terminates \false; ensures \false; assigns \nothing; */ extern void exit(int status); +/*@ assigns \nothing; */ +extern int printf(char const * , ...); void e_acsl_fail(char *msg) { printf("%s\n",msg); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_sizeof.c b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_sizeof.c index c77c7327b72fd4ab69a793639a7c3e72c6634e05..0357a9b29850279fdd0973f2dff5be8674d529cf 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_sizeof.c +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_sizeof.c @@ -1,608 +1,29 @@ /* Generated by Frama-C */ -typedef unsigned long size_t; -typedef unsigned long mp_limb_t; -typedef unsigned long mp_bitcnt_t; -struct __anonstruct___mpz_struct_6 { +struct __anonstruct___mpz_struct_1 { int _mp_alloc ; int _mp_size ; - mp_limb_t *_mp_d ; + unsigned long *_mp_d ; }; -typedef struct __anonstruct___mpz_struct_6 __mpz_struct; +typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; -typedef mp_limb_t *mp_ptr; -typedef mp_limb_t const *mp_srcptr; -typedef long mp_size_t; -struct __anonstruct___mpq_struct_7 { - __mpz_struct _mp_num ; - __mpz_struct _mp_den ; -}; -typedef struct __anonstruct___mpq_struct_7 __mpq_struct; -typedef __mpz_struct const *mpz_srcptr; -typedef __mpz_struct *mpz_ptr; -typedef __mpq_struct const *mpq_srcptr; -typedef __mpq_struct *mpq_ptr; -/* compiler builtin: - long __builtin_expect(long, long); */ -/*@ assigns \nothing; */ -extern int printf(char const * __restrict __format , ...); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u); -/*@ requires \valid(x); - assigns *x; */ -extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); -/*@ requires \valid(z1); - requires \valid(z2); - assigns \nothing; */ -extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); /*@ ensures \valid(\old(z)); assigns *z; assigns *z \from n; */ extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -extern void __gmpz_set(mpz_ptr, mpz_srcptr); -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); +/*@ requires \valid(x); + assigns *x; */ +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -extern void __gmpq_set(mpq_ptr, mpq_srcptr); -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_add_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n); -extern int __gmpn_perfect_square_p(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -extern mp_bitcnt_t __gmpn_popcount(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_sub_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpz_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_size >= 0) { __gmp_w->_mp_size = __gmp_w->_mp_size; } - else { __gmp_w->_mp_size = - __gmp_w->_mp_size; } - return; -} - -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)(~ ((unsigned int)0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= ~ ((unsigned long)0)) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)((unsigned short)(~ 0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -/*@ requires \valid(z); assigns \nothing; */ -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) -{ - mp_ptr __gmp_p; - mp_size_t __gmp_n; - mp_limb_t __gmp_l; - mp_limb_t tmp; - __gmp_p = z->_mp_d; - __gmp_n = (long)z->_mp_size; - __gmp_l = *(__gmp_p + 0); - if (__gmp_n != (mp_size_t)0) { tmp = __gmp_l; } - else { tmp = (unsigned long)0; } - return (tmp); -} - -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_result; - long tmp_1; - int tmp_0; - __gmp_result = (unsigned long)0; - { /*undefined sequence*/ - if (__gmp_n >= (mp_size_t)0) { - int tmp; - { /*undefined sequence*/ - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - ; - } - if (__gmp_n < (mp_size_t)tmp) { tmp_0 = 1; } - else { tmp_0 = 0; } - } - else { tmp_0 = 0; } - tmp_1 = __builtin_expect((long)(tmp_0 != 0),(long)1); - } - if (tmp_1) { __gmp_result = *(__gmp_z->_mp_d + __gmp_n); } - return (__gmp_result); -} - -/*@ requires \valid(z1); - requires \valid(z2); - assigns *z1; */ -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) -{ - if (z1 != z2) { __gmpz_set(z1,z2); } - z1->_mp_size = - z1->_mp_size; - return; -} - -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) -{ - mp_size_t __gmp_asize; - int __gmp_result; - long tmp; - __gmp_asize = (long)__gmp_a->_mp_size; - __gmp_result = __gmp_asize >= (mp_size_t)0; - tmp = __builtin_expect((long)((__gmp_asize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_perfect_square_p((mp_limb_t const *)__gmp_a->_mp_d, - __gmp_asize); - } - return (__gmp_result); -} - -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) -{ - mp_size_t __gmp_usize; - mp_bitcnt_t __gmp_result; - long tmp; - __gmp_usize = (long)__gmp_u->_mp_size; - if (__gmp_usize < (mp_size_t)0) { __gmp_result = ~ ((unsigned long)0); } - else { __gmp_result = (unsigned long)0; } - tmp = __builtin_expect((long)((__gmp_usize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_popcount((mp_limb_t const *)__gmp_u->_mp_d, - __gmp_usize); - } - return (__gmp_result); -} - -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - __gmpz_tdiv_q(__gmp_w,& __gmp_u->_mp_num,& __gmp_u->_mp_den); - return; -} - -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) -{ - size_t __retres; - int tmp; - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - __retres = (unsigned long)tmp; - return (__retres); -} - -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_num._mp_size >= 0) { - __gmp_w->_mp_num._mp_size = __gmp_w->_mp_num._mp_size; - } - else { __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; } - return; -} - -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; - return; -} - -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_1; - tmp_1 = __gmpn_add_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_1) { - while (1) { - mp_size_t tmp; - mp_limb_t tmp_0; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - tmp_0 = (__gmp_x + (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - *(__gmp_wp + tmp) = tmp_0; - } - if (! (tmp_0 == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x + __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_r < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x + (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_r < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) -{ - int __gmp_result; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_y; - __gmp_result = 0; - __gmp_i = __gmp_size; - while (1) { - __gmp_i -= (mp_size_t)1; - if (! (__gmp_i >= (mp_size_t)0)) { break; } - __gmp_x = *(__gmp_xp + __gmp_i); - __gmp_y = *(__gmp_yp + __gmp_i); - if (__gmp_x != __gmp_y) { - if (__gmp_x > __gmp_y) { __gmp_result = 1; } - else { __gmp_result = -1; } - break; - } - } - } - - break; - } - return (__gmp_result); -} - -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_0; - tmp_0 = __gmpn_sub_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_0) { - while (1) { - mp_size_t tmp; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - *(__gmp_wp + tmp) = (__gmp_x - (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - } - if (! (__gmp_x == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x - __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_x < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x - (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_x < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_ul; - mp_limb_t __gmp_cy; - __gmp_cy = (unsigned long)0; - while (1) { - { - mp_srcptr tmp; - mp_ptr tmp_0; - { /*undefined sequence*/ tmp = __gmp_up; __gmp_up ++; __gmp_ul = *tmp; - } - { /*undefined sequence*/ - tmp_0 = __gmp_rp; - __gmp_rp ++; - *tmp_0 = - __gmp_ul - __gmp_cy; - } - __gmp_cy |= (unsigned long)(__gmp_ul != (mp_limb_t)0); - } - - __gmp_n -= (mp_size_t)1; - if (! (__gmp_n != (mp_size_t)0)) { break; } - } - return (__gmp_cy); -} - +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ terminates \false; ensures \false; assigns \nothing; */ extern void exit(int status); +/*@ assigns \nothing; */ +extern int printf(char const * , ...); void e_acsl_fail(char *msg) { printf("%s\n",msg); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_stmt_contract.c b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_stmt_contract.c index bdefe538f1ef79f7d0b97f2c9012e9d14fc84d0b..b8c8db76241e845ec1addb2b6cbe83425805b820 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_stmt_contract.c +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_stmt_contract.c @@ -1,59 +1,11 @@ /* Generated by Frama-C */ -typedef unsigned long size_t; -typedef unsigned long mp_limb_t; -typedef unsigned long mp_bitcnt_t; -struct __anonstruct___mpz_struct_6 { +struct __anonstruct___mpz_struct_1 { int _mp_alloc ; int _mp_size ; - mp_limb_t *_mp_d ; + unsigned long *_mp_d ; }; -typedef struct __anonstruct___mpz_struct_6 __mpz_struct; +typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; -typedef mp_limb_t *mp_ptr; -typedef mp_limb_t const *mp_srcptr; -typedef long mp_size_t; -struct __anonstruct___mpq_struct_7 { - __mpz_struct _mp_num ; - __mpz_struct _mp_den ; -}; -typedef struct __anonstruct___mpq_struct_7 __mpq_struct; -typedef __mpz_struct const *mpz_srcptr; -typedef __mpz_struct *mpz_ptr; -typedef __mpq_struct const *mpq_srcptr; -typedef __mpq_struct *mpq_ptr; -/* compiler builtin: - long __builtin_expect(long, long); */ -/*@ assigns \nothing; */ -extern int printf(char const * __restrict __format , ...); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u); -/*@ requires \valid(z1); - requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_add(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -/*@ requires \valid(x); - assigns *x; */ -extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); -/*@ requires \valid(z1); - requires \valid(z2); - assigns \nothing; */ -extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); /*@ ensures \valid(\old(x)); assigns *x; */ extern void __gmpz_init(__mpz_struct * /*[1]*/ x); @@ -61,559 +13,28 @@ extern void __gmpz_init(__mpz_struct * /*[1]*/ x); assigns *z; assigns *z \from n; */ extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -extern void __gmpz_set(mpz_ptr, mpz_srcptr); -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); +/*@ requires \valid(x); + assigns *x; */ +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -extern void __gmpq_set(mpq_ptr, mpq_srcptr); -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_add_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n); -extern int __gmpn_perfect_square_p(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -extern mp_bitcnt_t __gmpn_popcount(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_sub_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpz_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_size >= 0) { __gmp_w->_mp_size = __gmp_w->_mp_size; } - else { __gmp_w->_mp_size = - __gmp_w->_mp_size; } - return; -} - -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)(~ ((unsigned int)0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= ~ ((unsigned long)0)) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)((unsigned short)(~ 0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -/*@ requires \valid(z); assigns \nothing; */ -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) -{ - mp_ptr __gmp_p; - mp_size_t __gmp_n; - mp_limb_t __gmp_l; - mp_limb_t tmp; - __gmp_p = z->_mp_d; - __gmp_n = (long)z->_mp_size; - __gmp_l = *(__gmp_p + 0); - if (__gmp_n != (mp_size_t)0) { tmp = __gmp_l; } - else { tmp = (unsigned long)0; } - return (tmp); -} - -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_result; - long tmp_1; - int tmp_0; - __gmp_result = (unsigned long)0; - { /*undefined sequence*/ - if (__gmp_n >= (mp_size_t)0) { - int tmp; - { /*undefined sequence*/ - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - ; - } - if (__gmp_n < (mp_size_t)tmp) { tmp_0 = 1; } - else { tmp_0 = 0; } - } - else { tmp_0 = 0; } - tmp_1 = __builtin_expect((long)(tmp_0 != 0),(long)1); - } - if (tmp_1) { __gmp_result = *(__gmp_z->_mp_d + __gmp_n); } - return (__gmp_result); -} - +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ requires \valid(z1); requires \valid(z2); - assigns *z1; */ -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) -{ - if (z1 != z2) { __gmpz_set(z1,z2); } - z1->_mp_size = - z1->_mp_size; - return; -} - -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) -{ - mp_size_t __gmp_asize; - int __gmp_result; - long tmp; - __gmp_asize = (long)__gmp_a->_mp_size; - __gmp_result = __gmp_asize >= (mp_size_t)0; - tmp = __builtin_expect((long)((__gmp_asize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_perfect_square_p((mp_limb_t const *)__gmp_a->_mp_d, - __gmp_asize); - } - return (__gmp_result); -} - -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) -{ - mp_size_t __gmp_usize; - mp_bitcnt_t __gmp_result; - long tmp; - __gmp_usize = (long)__gmp_u->_mp_size; - if (__gmp_usize < (mp_size_t)0) { __gmp_result = ~ ((unsigned long)0); } - else { __gmp_result = (unsigned long)0; } - tmp = __builtin_expect((long)((__gmp_usize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_popcount((mp_limb_t const *)__gmp_u->_mp_d, - __gmp_usize); - } - return (__gmp_result); -} - -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - __gmpz_tdiv_q(__gmp_w,& __gmp_u->_mp_num,& __gmp_u->_mp_den); - return; -} - -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) -{ - size_t __retres; - int tmp; - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - __retres = (unsigned long)tmp; - return (__retres); -} - -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_num._mp_size >= 0) { - __gmp_w->_mp_num._mp_size = __gmp_w->_mp_num._mp_size; - } - else { __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; } - return; -} - -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; - return; -} - -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_1; - tmp_1 = __gmpn_add_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_1) { - while (1) { - mp_size_t tmp; - mp_limb_t tmp_0; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - tmp_0 = (__gmp_x + (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - *(__gmp_wp + tmp) = tmp_0; - } - if (! (tmp_0 == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x + __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_r < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x + (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_r < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) -{ - int __gmp_result; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_y; - __gmp_result = 0; - __gmp_i = __gmp_size; - while (1) { - __gmp_i -= (mp_size_t)1; - if (! (__gmp_i >= (mp_size_t)0)) { break; } - __gmp_x = *(__gmp_xp + __gmp_i); - __gmp_y = *(__gmp_yp + __gmp_i); - if (__gmp_x != __gmp_y) { - if (__gmp_x > __gmp_y) { __gmp_result = 1; } - else { __gmp_result = -1; } - break; - } - } - } - - break; - } - return (__gmp_result); -} - -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_0; - tmp_0 = __gmpn_sub_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_0) { - while (1) { - mp_size_t tmp; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - *(__gmp_wp + tmp) = (__gmp_x - (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - } - if (! (__gmp_x == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x - __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_x < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x - (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_x < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_ul; - mp_limb_t __gmp_cy; - __gmp_cy = (unsigned long)0; - while (1) { - { - mp_srcptr tmp; - mp_ptr tmp_0; - { /*undefined sequence*/ tmp = __gmp_up; __gmp_up ++; __gmp_ul = *tmp; - } - { /*undefined sequence*/ - tmp_0 = __gmp_rp; - __gmp_rp ++; - *tmp_0 = - __gmp_ul - __gmp_cy; - } - __gmp_cy |= (unsigned long)(__gmp_ul != (mp_limb_t)0); - } - - __gmp_n -= (mp_size_t)1; - if (! (__gmp_n != (mp_size_t)0)) { break; } - } - return (__gmp_cy); -} - + requires \valid(z3); + assigns *z1; +*/ +extern void __gmpz_add(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2, + __mpz_struct const * /*[1]*/ z3); /*@ terminates \false; ensures \false; assigns \nothing; */ extern void exit(int status); +/*@ assigns \nothing; */ +extern int printf(char const * , ...); void e_acsl_fail(char *msg) { printf("%s\n",msg); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_true.c b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_true.c index d24b4fa8b8b6d6f0829dae758ec09eba582581d0..4e81852c13afffb8b200281fd52ef52cacb116ea 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_true.c +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/gen_true.c @@ -1,594 +1,10 @@ /* Generated by Frama-C */ -typedef unsigned long size_t; -typedef unsigned long mp_limb_t; -typedef unsigned long mp_bitcnt_t; -struct __anonstruct___mpz_struct_6 { - int _mp_alloc ; - int _mp_size ; - mp_limb_t *_mp_d ; -}; -typedef struct __anonstruct___mpz_struct_6 __mpz_struct; -typedef mp_limb_t *mp_ptr; -typedef mp_limb_t const *mp_srcptr; -typedef long mp_size_t; -struct __anonstruct___mpq_struct_7 { - __mpz_struct _mp_num ; - __mpz_struct _mp_den ; -}; -typedef struct __anonstruct___mpq_struct_7 __mpq_struct; -typedef __mpz_struct const *mpz_srcptr; -typedef __mpz_struct *mpz_ptr; -typedef __mpq_struct const *mpq_srcptr; -typedef __mpq_struct *mpq_ptr; -/* compiler builtin: - long __builtin_expect(long, long); */ -/*@ assigns \nothing; */ -extern int printf(char const * __restrict __format , ...); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -extern void __gmpz_set(mpz_ptr, mpz_srcptr); -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -/*@ requires \valid(z1); - requires \valid(z2); - requires \valid(z3); - assigns *z1; -*/ -extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u); -extern void __gmpq_set(mpq_ptr, mpq_srcptr); -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_add_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n); -extern int __gmpn_perfect_square_p(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -extern mp_bitcnt_t __gmpn_popcount(mp_srcptr, mp_size_t) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize); -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n); -extern mp_limb_t __gmpn_sub_n(mp_ptr, mp_srcptr, mp_srcptr, mp_size_t); -__inline static void __gmpz_abs(mpz_ptr __gmp_w, mpz_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpz_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_size >= 0) { __gmp_w->_mp_size = __gmp_w->_mp_size; } - else { __gmp_w->_mp_size = - __gmp_w->_mp_size; } - return; -} - -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_uint_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)(~ ((unsigned int)0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ulong_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= ~ ((unsigned long)0)) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static int __gmpz_fits_ushort_p(mpz_srcptr __gmp_z) -{ - int __retres; - mp_size_t __gmp_n; - mp_ptr __gmp_p; - int tmp; - __gmp_n = (long)__gmp_z->_mp_size; - __gmp_p = __gmp_z->_mp_d; - if (__gmp_n == (mp_size_t)0) { tmp = 1; } - else { - if (__gmp_n == (mp_size_t)1) { - if (*(__gmp_p + 0) <= (mp_limb_t)((unsigned short)(~ 0))) { tmp = 1; } - else { tmp = 0; } - } - else { tmp = 0; } - } - __retres = tmp; - goto return_label; - return_label: /* internal */ - return (__retres); -} - -/*@ requires \valid(z); - assigns \nothing; */ -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) __attribute__(( -__pure__)); -__inline static unsigned long __gmpz_get_ui(__mpz_struct const * /*[1]*/ z) -{ - mp_ptr __gmp_p; - mp_size_t __gmp_n; - mp_limb_t __gmp_l; - mp_limb_t tmp; - __gmp_p = z->_mp_d; - __gmp_n = (long)z->_mp_size; - __gmp_l = *(__gmp_p + 0); - if (__gmp_n != (mp_size_t)0) { tmp = __gmp_l; } - else { tmp = (unsigned long)0; } - return (tmp); -} - -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) __attribute__(( -__pure__)); -__inline static mp_limb_t __gmpz_getlimbn(mpz_srcptr __gmp_z, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_result; - long tmp_1; - int tmp_0; - __gmp_result = (unsigned long)0; - { /*undefined sequence*/ - if (__gmp_n >= (mp_size_t)0) { - int tmp; - { /*undefined sequence*/ - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - ; - } - if (__gmp_n < (mp_size_t)tmp) { tmp_0 = 1; } - else { tmp_0 = 0; } - } - else { tmp_0 = 0; } - tmp_1 = __builtin_expect((long)(tmp_0 != 0),(long)1); - } - if (tmp_1) { __gmp_result = *(__gmp_z->_mp_d + __gmp_n); } - return (__gmp_result); -} - -/*@ requires \valid(z1); - requires \valid(z2); - assigns *z1; */ -__inline static void __gmpz_neg(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2) -{ - if (z1 != z2) { __gmpz_set(z1,z2); } - z1->_mp_size = - z1->_mp_size; - return; -} - -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) __attribute__(( -__pure__)); -__inline static int __gmpz_perfect_square_p(mpz_srcptr __gmp_a) -{ - mp_size_t __gmp_asize; - int __gmp_result; - long tmp; - __gmp_asize = (long)__gmp_a->_mp_size; - __gmp_result = __gmp_asize >= (mp_size_t)0; - tmp = __builtin_expect((long)((__gmp_asize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_perfect_square_p((mp_limb_t const *)__gmp_a->_mp_d, - __gmp_asize); - } - return (__gmp_result); -} - -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) __attribute__(( -__pure__)); -__inline static mp_bitcnt_t __gmpz_popcount(mpz_srcptr __gmp_u) -{ - mp_size_t __gmp_usize; - mp_bitcnt_t __gmp_result; - long tmp; - __gmp_usize = (long)__gmp_u->_mp_size; - if (__gmp_usize < (mp_size_t)0) { __gmp_result = ~ ((unsigned long)0); } - else { __gmp_result = (unsigned long)0; } - tmp = __builtin_expect((long)((__gmp_usize > (mp_size_t)0) != 0),(long)1); - if (tmp) { - __gmp_result = __gmpn_popcount((mp_limb_t const *)__gmp_u->_mp_d, - __gmp_usize); - } - return (__gmp_result); -} - -__inline static void __gmpz_set_q(mpz_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - __gmpz_tdiv_q(__gmp_w,& __gmp_u->_mp_num,& __gmp_u->_mp_den); - return; -} - -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) __attribute__(( -__pure__)); -__inline static size_t __gmpz_size(mpz_srcptr __gmp_z) -{ - size_t __retres; - int tmp; - if (__gmp_z->_mp_size >= 0) { tmp = __gmp_z->_mp_size; } - else { tmp = - __gmp_z->_mp_size; } - __retres = (unsigned long)tmp; - return (__retres); -} - -__inline static void __gmpq_abs(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - if (__gmp_w->_mp_num._mp_size >= 0) { - __gmp_w->_mp_num._mp_size = __gmp_w->_mp_num._mp_size; - } - else { __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; } - return; -} - -__inline static void __gmpq_neg(mpq_ptr __gmp_w, mpq_srcptr __gmp_u) -{ - if (__gmp_w != __gmp_u) { __gmpq_set(__gmp_w,__gmp_u); } - __gmp_w->_mp_num._mp_size = - __gmp_w->_mp_num._mp_size; - return; -} - -__inline static mp_limb_t __gmpn_add(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_1; - tmp_1 = __gmpn_add_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_1) { - while (1) { - mp_size_t tmp; - mp_limb_t tmp_0; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - tmp_0 = (__gmp_x + (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - *(__gmp_wp + tmp) = tmp_0; - } - if (! (tmp_0 == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_add_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x + __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_r < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x + (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_r < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) __attribute__((__pure__)); -__inline static int __gmpn_cmp(mp_srcptr __gmp_xp, mp_srcptr __gmp_yp, - mp_size_t __gmp_size) -{ - int __gmp_result; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_y; - __gmp_result = 0; - __gmp_i = __gmp_size; - while (1) { - __gmp_i -= (mp_size_t)1; - if (! (__gmp_i >= (mp_size_t)0)) { break; } - __gmp_x = *(__gmp_xp + __gmp_i); - __gmp_y = *(__gmp_yp + __gmp_i); - if (__gmp_x != __gmp_y) { - if (__gmp_x > __gmp_y) { __gmp_result = 1; } - else { __gmp_result = -1; } - break; - } - } - } - - break; - } - return (__gmp_result); -} - -__inline static mp_limb_t __gmpn_sub(mp_ptr __gmp_wp, mp_srcptr __gmp_xp, - mp_size_t __gmp_xsize, - mp_srcptr __gmp_yp, - mp_size_t __gmp_ysize) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - __gmp_i = __gmp_ysize; - if (__gmp_i != (mp_size_t)0) { - mp_limb_t tmp_0; - tmp_0 = __gmpn_sub_n(__gmp_wp,__gmp_xp,__gmp_yp,__gmp_i); - if (tmp_0) { - while (1) { - mp_size_t tmp; - if (__gmp_i >= __gmp_xsize) { - __gmp_c = (unsigned long)1; - goto __gmp_done; - } - __gmp_x = *(__gmp_xp + __gmp_i); - { /*undefined sequence*/ - tmp = __gmp_i; - __gmp_i += (mp_size_t)1; - *(__gmp_wp + tmp) = (__gmp_x - (mp_limb_t)1) & (~ ((unsigned long)0) >> 0); - } - if (! (__gmp_x == (mp_limb_t)0)) { break; } - } - } - } - if (__gmp_wp != __gmp_xp) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_xsize) { - *(__gmp_wp + __gmp_j) = *(__gmp_xp + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - __gmp_done: ; - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_sub_1(mp_ptr __gmp_dst, mp_srcptr __gmp_src, - mp_size_t __gmp_size, - mp_limb_t __gmp_n) -{ - mp_limb_t __gmp_c; - while (1) { - { - mp_size_t __gmp_i; - mp_limb_t __gmp_x; - mp_limb_t __gmp_r; - __gmp_x = *(__gmp_src + 0); - __gmp_r = __gmp_x - __gmp_n; - *(__gmp_dst + 0) = __gmp_r; - if (__gmp_x < __gmp_n) { - __gmp_c = (unsigned long)1; - __gmp_i = (long)1; - while (__gmp_i < __gmp_size) { - __gmp_x = *(__gmp_src + __gmp_i); - __gmp_r = __gmp_x - (mp_limb_t)1; - *(__gmp_dst + __gmp_i) = __gmp_r; - __gmp_i += (mp_size_t)1; - if (! (__gmp_x < (mp_limb_t)1)) { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j; - __gmp_j = __gmp_i; - while (__gmp_j < __gmp_size) { - *(__gmp_dst + __gmp_j) = *(__gmp_src + __gmp_j); - __gmp_j += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - break; - } - } - } - else { - if (__gmp_src != __gmp_dst) { - while (1) { - { - mp_size_t __gmp_j_0; - __gmp_j_0 = (long)1; - while (__gmp_j_0 < __gmp_size) { - *(__gmp_dst + __gmp_j_0) = *(__gmp_src + __gmp_j_0); - __gmp_j_0 += (mp_size_t)1; - } - } - - break; - } - } - __gmp_c = (unsigned long)0; - } - } - - break; - } - return (__gmp_c); -} - -__inline static mp_limb_t __gmpn_neg(mp_ptr __gmp_rp, mp_srcptr __gmp_up, - mp_size_t __gmp_n) -{ - mp_limb_t __gmp_ul; - mp_limb_t __gmp_cy; - __gmp_cy = (unsigned long)0; - while (1) { - { - mp_srcptr tmp; - mp_ptr tmp_0; - { /*undefined sequence*/ tmp = __gmp_up; __gmp_up ++; __gmp_ul = *tmp; - } - { /*undefined sequence*/ - tmp_0 = __gmp_rp; - __gmp_rp ++; - *tmp_0 = - __gmp_ul - __gmp_cy; - } - __gmp_cy |= (unsigned long)(__gmp_ul != (mp_limb_t)0); - } - - __gmp_n -= (mp_size_t)1; - if (! (__gmp_n != (mp_size_t)0)) { break; } - } - return (__gmp_cy); -} - /*@ terminates \false; ensures \false; assigns \nothing; */ extern void exit(int status); +/*@ assigns \nothing; */ +extern int printf(char const * , ...); void e_acsl_fail(char *msg) { printf("%s\n",msg); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/integer_constant.res.oracle b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/integer_constant.res.oracle index a43ccbfae6cca799d80c5cdd492129ae80b19cb6..06d34e6faeb48fbef2e412ea87666c53c1242093 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/integer_constant.res.oracle +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/integer_constant.res.oracle @@ -5,15 +5,15 @@ PROJECT_FILE.i:135:[value] Assertion got status valid. PROJECT_FILE.i:139:[value] Assertion got status valid. PROJECT_FILE.i:142:[value] Assertion got status valid. -[value] computing for function mpz_init_set_str <- main. +[value] computing for function __gmpz_init_set_str <- main. Called from PROJECT_FILE.i:146. -PROJECT_FILE.i:37:[value] Function mpz_init_set_str: postcondition got status valid. -[value] Done for function mpz_init_set_str -[value] computing for function mpz_cmp <- main. +PROJECT_FILE.i:37:[value] Function __gmpz_init_set_str: postcondition got status valid. +[value] Done for function __gmpz_init_set_str +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:147. -PROJECT_FILE.i:49:[value] Function mpz_cmp: precondition got status valid. -PROJECT_FILE.i:50:[value] Function mpz_cmp: precondition got status valid. -[value] Done for function mpz_cmp +PROJECT_FILE.i:49:[value] Function __gmpz_cmp: precondition got status valid. +PROJECT_FILE.i:50:[value] Function __gmpz_cmp: precondition got status valid. +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:149. [value] computing for function printf <- e_acsl_fail <- main. @@ -25,10 +25,10 @@ PROJECT_FILE.i:119:[value] Function exit: postcondition got status invalid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:151. -PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. -[value] Done for function mpz_clear +PROJECT_FILE.i:43:[value] Function __gmpz_clear: precondition got status valid. +[value] Done for function __gmpz_clear [value] Recording results for main [value] done for function main [value] ====== VALUES COMPUTED ====== @@ -47,16 +47,16 @@ typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; /*@ ensures \valid(\old(z)); assigns *z; */ -extern int mpz_init_set_str(__mpz_struct * /*[1]*/ z, char const *str, - int base); +extern int __gmpz_init_set_str(__mpz_struct * /*[1]*/ z, char const *str, + int base); /*@ requires \valid(x); assigns *x; */ -extern void mpz_clear(__mpz_struct * /*[1]*/ x); +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); assigns \nothing; */ -extern int mpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ terminates \false; ensures \false; assigns \nothing; */ @@ -83,13 +83,13 @@ int main(void) { mpz_t e_acsl_1; int e_acsl_2; - mpz_init_set_str((__mpz_struct *)(e_acsl_1),"1152921504606846975",10); - e_acsl_2 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_1)); + __gmpz_init_set_str((__mpz_struct *)(e_acsl_1),"1152921504606846975",10); + e_acsl_2 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_1)); if (! (e_acsl_2 == 0)) { e_acsl_fail((char *)"(1152921504606846975 == 0xfffffffffffffff)"); } - mpz_clear((__mpz_struct *)(e_acsl_1)); + __gmpz_clear((__mpz_struct *)(e_acsl_1)); } __retres = 0; diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/lazy.res.oracle b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/lazy.res.oracle index 18fd2c7eeb3e8f046cb62342f1df22096a77df70..fb826c17cb217d1e087d080788cd605b48b778d6 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/lazy.res.oracle +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/lazy.res.oracle @@ -3,35 +3,35 @@ [value] Initial state computed [value] Values of globals at initialization PROJECT_FILE.i:138:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:144. -PROJECT_FILE.i:33:[value] Function mpz_init_set_si: postcondition got status valid. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +PROJECT_FILE.i:33:[value] Function __gmpz_init_set_si: postcondition got status valid. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:145. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:146. -PROJECT_FILE.i:49:[value] Function mpz_cmp: precondition got status valid. -PROJECT_FILE.i:50:[value] Function mpz_cmp: precondition got status valid. -[value] Done for function mpz_cmp -[value] computing for function mpz_init_set_si <- main. +PROJECT_FILE.i:49:[value] Function __gmpz_cmp: precondition got status valid. +PROJECT_FILE.i:50:[value] Function __gmpz_cmp: precondition got status valid. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:151. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:152. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:153. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp PROJECT_FILE.i:154:[value] assigning non deterministic value for the first time -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:155. -PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +PROJECT_FILE.i:43:[value] Function __gmpz_clear: precondition got status valid. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:156. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:159. [value] computing for function printf <- e_acsl_fail <- main. @@ -43,57 +43,57 @@ PROJECT_FILE.i:119:[value] Function exit: postcondition got status invalid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:160. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:161. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:165:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:171. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:172. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:173. -[value] Done for function mpz_cmp -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:179. -[value] Done for function mpz_init_set_si +[value] Done for function __gmpz_init_set_si PROJECT_FILE.i:180:[value] Assertion got status invalid (stopping propagation). -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:191. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:192. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:196:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:202. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:203. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:204. -[value] Done for function mpz_cmp -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:210. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:211. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:212. -[value] Done for function mpz_cmp -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:214. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:215. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:217. [value] computing for function printf <- e_acsl_fail <- main. @@ -104,57 +104,57 @@ PROJECT_FILE.i:196:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:218. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:219. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:223:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:229. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:230. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:231. -[value] Done for function mpz_cmp -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:238. -[value] Done for function mpz_init_set_si +[value] Done for function __gmpz_init_set_si PROJECT_FILE.i:239:[value] Assertion got status invalid (stopping propagation). -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:249. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:250. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:254:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:260. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:261. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:262. -[value] Done for function mpz_cmp -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:268. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:269. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:270. -[value] Done for function mpz_cmp -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:272. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:273. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:275. [value] computing for function printf <- e_acsl_fail <- main. @@ -165,32 +165,32 @@ PROJECT_FILE.i:254:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:276. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:277. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:281:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:287. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:288. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:289. -[value] Done for function mpz_cmp -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:296. -[value] Done for function mpz_init_set_si +[value] Done for function __gmpz_init_set_si PROJECT_FILE.i:297:[value] Assertion got status invalid (stopping propagation). -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:307. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:308. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] Recording results for main [value] done for function main [value] ====== VALUES COMPUTED ====== @@ -211,15 +211,15 @@ typedef __mpz_struct mpz_t[1]; /*@ ensures \valid(\old(z)); assigns *z; assigns *z \from n; */ -extern void mpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); +extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); /*@ requires \valid(x); assigns *x; */ -extern void mpz_clear(__mpz_struct * /*[1]*/ x); +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); assigns \nothing; */ -extern int mpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ terminates \false; ensures \false; assigns \nothing; */ @@ -246,26 +246,26 @@ int main(void) mpz_t e_acsl_2; int e_acsl_3; int e_acsl_7; - mpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)0); - e_acsl_3 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_2)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)0); + e_acsl_3 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_2)); if (e_acsl_3 == 0) { mpz_t e_acsl_4; mpz_t e_acsl_5; int e_acsl_6; - mpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)y); - mpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)1); - e_acsl_6 = mpz_cmp((__mpz_struct const *)(e_acsl_4), - (__mpz_struct const *)(e_acsl_5)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)y); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)1); + e_acsl_6 = __gmpz_cmp((__mpz_struct const *)(e_acsl_4), + (__mpz_struct const *)(e_acsl_5)); e_acsl_7 = e_acsl_6 == 0; - mpz_clear((__mpz_struct *)(e_acsl_4)); - mpz_clear((__mpz_struct *)(e_acsl_5)); + __gmpz_clear((__mpz_struct *)(e_acsl_4)); + __gmpz_clear((__mpz_struct *)(e_acsl_5)); } else { e_acsl_7 = 0; } if (! e_acsl_7) { e_acsl_fail((char *)"(x == 0 && y == 1)"); } - mpz_clear((__mpz_struct *)(e_acsl_1)); - mpz_clear((__mpz_struct *)(e_acsl_2)); + __gmpz_clear((__mpz_struct *)(e_acsl_1)); + __gmpz_clear((__mpz_struct *)(e_acsl_2)); } /*@ assert ¬(x ≢ 0 ∧ y ≡ 1/0); */ ; @@ -274,30 +274,30 @@ int main(void) mpz_t e_acsl_9; int e_acsl_10; int e_acsl_15; - mpz_init_set_si((__mpz_struct *)(e_acsl_8),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_9),(long)0); - e_acsl_10 = mpz_cmp((__mpz_struct const *)(e_acsl_8), - (__mpz_struct const *)(e_acsl_9)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_8),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_9),(long)0); + e_acsl_10 = __gmpz_cmp((__mpz_struct const *)(e_acsl_8), + (__mpz_struct const *)(e_acsl_9)); if (e_acsl_10 != 0) { mpz_t e_acsl_11; int e_acsl_12; mpz_t e_acsl_13; int e_acsl_14; - mpz_init_set_si((__mpz_struct *)(e_acsl_11),(long)y); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_11),(long)y); /*@ assert 0 ≢ 0; */ ; if (0 == 0) { e_acsl_fail((char *)"(0 == 0)"); } e_acsl_12 = 1 / 0; - mpz_init_set_si((__mpz_struct *)(e_acsl_13),(long)e_acsl_12); - e_acsl_14 = mpz_cmp((__mpz_struct const *)(e_acsl_11), - (__mpz_struct const *)(e_acsl_13)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_13),(long)e_acsl_12); + e_acsl_14 = __gmpz_cmp((__mpz_struct const *)(e_acsl_11), + (__mpz_struct const *)(e_acsl_13)); e_acsl_15 = e_acsl_14 == 0; - mpz_clear((__mpz_struct *)(e_acsl_11)); - mpz_clear((__mpz_struct *)(e_acsl_13)); + __gmpz_clear((__mpz_struct *)(e_acsl_11)); + __gmpz_clear((__mpz_struct *)(e_acsl_13)); } else { e_acsl_15 = 0; } if (! (! e_acsl_15)) { e_acsl_fail((char *)"(!(x != 0 && y == 1/0))"); } - mpz_clear((__mpz_struct *)(e_acsl_8)); - mpz_clear((__mpz_struct *)(e_acsl_9)); + __gmpz_clear((__mpz_struct *)(e_acsl_8)); + __gmpz_clear((__mpz_struct *)(e_acsl_9)); } /*@ assert y ≡ 1 ∨ x ≡ 1; */ ; @@ -306,26 +306,26 @@ int main(void) mpz_t e_acsl_17; int e_acsl_18; int e_acsl_22; - mpz_init_set_si((__mpz_struct *)(e_acsl_16),(long)y); - mpz_init_set_si((__mpz_struct *)(e_acsl_17),(long)1); - e_acsl_18 = mpz_cmp((__mpz_struct const *)(e_acsl_16), - (__mpz_struct const *)(e_acsl_17)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_16),(long)y); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_17),(long)1); + e_acsl_18 = __gmpz_cmp((__mpz_struct const *)(e_acsl_16), + (__mpz_struct const *)(e_acsl_17)); if (e_acsl_18 == 0) { e_acsl_22 = 1; } else { mpz_t e_acsl_19; mpz_t e_acsl_20; int e_acsl_21; - mpz_init_set_si((__mpz_struct *)(e_acsl_19),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_20),(long)1); - e_acsl_21 = mpz_cmp((__mpz_struct const *)(e_acsl_19), - (__mpz_struct const *)(e_acsl_20)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_19),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_20),(long)1); + e_acsl_21 = __gmpz_cmp((__mpz_struct const *)(e_acsl_19), + (__mpz_struct const *)(e_acsl_20)); e_acsl_22 = e_acsl_21 == 0; - mpz_clear((__mpz_struct *)(e_acsl_19)); - mpz_clear((__mpz_struct *)(e_acsl_20)); + __gmpz_clear((__mpz_struct *)(e_acsl_19)); + __gmpz_clear((__mpz_struct *)(e_acsl_20)); } if (! e_acsl_22) { e_acsl_fail((char *)"(y == 1 || x == 1)"); } - mpz_clear((__mpz_struct *)(e_acsl_16)); - mpz_clear((__mpz_struct *)(e_acsl_17)); + __gmpz_clear((__mpz_struct *)(e_acsl_16)); + __gmpz_clear((__mpz_struct *)(e_acsl_17)); } /*@ assert x ≡ 0 ∨ y ≡ 1/0; */ ; @@ -334,30 +334,30 @@ int main(void) mpz_t e_acsl_24; int e_acsl_25; int e_acsl_30; - mpz_init_set_si((__mpz_struct *)(e_acsl_23),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_24),(long)0); - e_acsl_25 = mpz_cmp((__mpz_struct const *)(e_acsl_23), - (__mpz_struct const *)(e_acsl_24)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_23),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_24),(long)0); + e_acsl_25 = __gmpz_cmp((__mpz_struct const *)(e_acsl_23), + (__mpz_struct const *)(e_acsl_24)); if (e_acsl_25 == 0) { e_acsl_30 = 1; } else { mpz_t e_acsl_26; int e_acsl_27; mpz_t e_acsl_28; int e_acsl_29; - mpz_init_set_si((__mpz_struct *)(e_acsl_26),(long)y); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_26),(long)y); /*@ assert 0 ≢ 0; */ ; if (0 == 0) { e_acsl_fail((char *)"(0 == 0)"); } e_acsl_27 = 1 / 0; - mpz_init_set_si((__mpz_struct *)(e_acsl_28),(long)e_acsl_27); - e_acsl_29 = mpz_cmp((__mpz_struct const *)(e_acsl_26), - (__mpz_struct const *)(e_acsl_28)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_28),(long)e_acsl_27); + e_acsl_29 = __gmpz_cmp((__mpz_struct const *)(e_acsl_26), + (__mpz_struct const *)(e_acsl_28)); e_acsl_30 = e_acsl_29 == 0; - mpz_clear((__mpz_struct *)(e_acsl_26)); - mpz_clear((__mpz_struct *)(e_acsl_28)); + __gmpz_clear((__mpz_struct *)(e_acsl_26)); + __gmpz_clear((__mpz_struct *)(e_acsl_28)); } if (! e_acsl_30) { e_acsl_fail((char *)"(x == 0 || y == 1/0)"); } - mpz_clear((__mpz_struct *)(e_acsl_23)); - mpz_clear((__mpz_struct *)(e_acsl_24)); + __gmpz_clear((__mpz_struct *)(e_acsl_23)); + __gmpz_clear((__mpz_struct *)(e_acsl_24)); } /*@ assert x ≡ 0 ⇒ y ≡ 1; */ ; @@ -366,26 +366,26 @@ int main(void) mpz_t e_acsl_32; int e_acsl_33; int e_acsl_37; - mpz_init_set_si((__mpz_struct *)(e_acsl_31),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_32),(long)0); - e_acsl_33 = mpz_cmp((__mpz_struct const *)(e_acsl_31), - (__mpz_struct const *)(e_acsl_32)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_31),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_32),(long)0); + e_acsl_33 = __gmpz_cmp((__mpz_struct const *)(e_acsl_31), + (__mpz_struct const *)(e_acsl_32)); if (! (e_acsl_33 == 0)) { e_acsl_37 = 1; } else { mpz_t e_acsl_34; mpz_t e_acsl_35; int e_acsl_36; - mpz_init_set_si((__mpz_struct *)(e_acsl_34),(long)y); - mpz_init_set_si((__mpz_struct *)(e_acsl_35),(long)1); - e_acsl_36 = mpz_cmp((__mpz_struct const *)(e_acsl_34), - (__mpz_struct const *)(e_acsl_35)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_34),(long)y); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_35),(long)1); + e_acsl_36 = __gmpz_cmp((__mpz_struct const *)(e_acsl_34), + (__mpz_struct const *)(e_acsl_35)); e_acsl_37 = e_acsl_36 == 0; - mpz_clear((__mpz_struct *)(e_acsl_34)); - mpz_clear((__mpz_struct *)(e_acsl_35)); + __gmpz_clear((__mpz_struct *)(e_acsl_34)); + __gmpz_clear((__mpz_struct *)(e_acsl_35)); } if (! e_acsl_37) { e_acsl_fail((char *)"(x == 0 ==> y == 1)"); } - mpz_clear((__mpz_struct *)(e_acsl_31)); - mpz_clear((__mpz_struct *)(e_acsl_32)); + __gmpz_clear((__mpz_struct *)(e_acsl_31)); + __gmpz_clear((__mpz_struct *)(e_acsl_32)); } /*@ assert x ≡ 1 ⇒ y ≡ 1/0; */ ; @@ -394,30 +394,30 @@ int main(void) mpz_t e_acsl_39; int e_acsl_40; int e_acsl_45; - mpz_init_set_si((__mpz_struct *)(e_acsl_38),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_39),(long)1); - e_acsl_40 = mpz_cmp((__mpz_struct const *)(e_acsl_38), - (__mpz_struct const *)(e_acsl_39)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_38),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_39),(long)1); + e_acsl_40 = __gmpz_cmp((__mpz_struct const *)(e_acsl_38), + (__mpz_struct const *)(e_acsl_39)); if (! (e_acsl_40 == 0)) { e_acsl_45 = 1; } else { mpz_t e_acsl_41; int e_acsl_42; mpz_t e_acsl_43; int e_acsl_44; - mpz_init_set_si((__mpz_struct *)(e_acsl_41),(long)y); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_41),(long)y); /*@ assert 0 ≢ 0; */ ; if (0 == 0) { e_acsl_fail((char *)"(0 == 0)"); } e_acsl_42 = 1 / 0; - mpz_init_set_si((__mpz_struct *)(e_acsl_43),(long)e_acsl_42); - e_acsl_44 = mpz_cmp((__mpz_struct const *)(e_acsl_41), - (__mpz_struct const *)(e_acsl_43)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_43),(long)e_acsl_42); + e_acsl_44 = __gmpz_cmp((__mpz_struct const *)(e_acsl_41), + (__mpz_struct const *)(e_acsl_43)); e_acsl_45 = e_acsl_44 == 0; - mpz_clear((__mpz_struct *)(e_acsl_41)); - mpz_clear((__mpz_struct *)(e_acsl_43)); + __gmpz_clear((__mpz_struct *)(e_acsl_41)); + __gmpz_clear((__mpz_struct *)(e_acsl_43)); } if (! e_acsl_45) { e_acsl_fail((char *)"(x == 1 ==> y == 1/0)"); } - mpz_clear((__mpz_struct *)(e_acsl_38)); - mpz_clear((__mpz_struct *)(e_acsl_39)); + __gmpz_clear((__mpz_struct *)(e_acsl_38)); + __gmpz_clear((__mpz_struct *)(e_acsl_39)); } __retres = 0; diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/nested_code_annot.res.oracle b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/nested_code_annot.res.oracle index b371921de35c5fdc09353f5f78ad05fe1eec4ec2..132e58469233fc1d8bb57fa60560227ac6f4fa81 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/nested_code_annot.res.oracle +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/nested_code_annot.res.oracle @@ -3,18 +3,18 @@ [value] Initial state computed [value] Values of globals at initialization PROJECT_FILE.i:138:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:151. -PROJECT_FILE.i:33:[value] Function mpz_init_set_si: postcondition got status valid. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +PROJECT_FILE.i:33:[value] Function __gmpz_init_set_si: postcondition got status valid. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:152. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:153. -PROJECT_FILE.i:49:[value] Function mpz_cmp: precondition got status valid. -PROJECT_FILE.i:50:[value] Function mpz_cmp: precondition got status valid. -[value] Done for function mpz_cmp +PROJECT_FILE.i:49:[value] Function __gmpz_cmp: precondition got status valid. +PROJECT_FILE.i:50:[value] Function __gmpz_cmp: precondition got status valid. +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:154. [value] computing for function printf <- e_acsl_fail <- main. @@ -26,22 +26,22 @@ PROJECT_FILE.i:119:[value] Function exit: postcondition got status invalid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:155. -PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +PROJECT_FILE.i:43:[value] Function __gmpz_clear: precondition got status valid. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:156. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:172. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:173. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:174. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:175. [value] computing for function printf <- e_acsl_fail <- main. @@ -52,21 +52,21 @@ PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:176. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:177. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:181. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:182. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:183. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:184. [value] computing for function printf <- e_acsl_fail <- main. @@ -77,21 +77,21 @@ PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:185. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:186. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:200. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:201. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:202. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:203. [value] computing for function printf <- e_acsl_fail <- main. @@ -102,21 +102,21 @@ PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:204. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:205. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:209. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:210. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:211. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:212. [value] computing for function printf <- e_acsl_fail <- main. @@ -127,21 +127,21 @@ PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:213. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:214. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:225. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:226. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:227. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:228. [value] computing for function printf <- e_acsl_fail <- main. @@ -152,12 +152,12 @@ PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:229. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:230. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] Recording results for main [value] done for function main [value] ====== VALUES COMPUTED ====== @@ -178,15 +178,15 @@ typedef __mpz_struct mpz_t[1]; /*@ ensures \valid(\old(z)); assigns *z; assigns *z \from n; */ -extern void mpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); +extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); /*@ requires \valid(x); assigns *x; */ -extern void mpz_clear(__mpz_struct * /*[1]*/ x); +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); assigns \nothing; */ -extern int mpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ terminates \false; ensures \false; assigns \nothing; */ @@ -219,13 +219,13 @@ int main(void) mpz_t e_acsl_1; mpz_t e_acsl_2; int e_acsl_3; - mpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)0); - e_acsl_3 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_2)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)0); + e_acsl_3 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_2)); if (! (e_acsl_3 == 0)) { e_acsl_fail((char *)"(x == 0)"); } - mpz_clear((__mpz_struct *)(e_acsl_1)); - mpz_clear((__mpz_struct *)(e_acsl_2)); + __gmpz_clear((__mpz_struct *)(e_acsl_1)); + __gmpz_clear((__mpz_struct *)(e_acsl_2)); if (x) { /*@ assert \false; */ ; e_acsl_fail((char *)"(\\false)"); } @@ -240,23 +240,23 @@ int main(void) mpz_t e_acsl_4; mpz_t e_acsl_5; int e_acsl_6; - mpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)0); - e_acsl_6 = mpz_cmp((__mpz_struct const *)(e_acsl_4), - (__mpz_struct const *)(e_acsl_5)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)0); + e_acsl_6 = __gmpz_cmp((__mpz_struct const *)(e_acsl_4), + (__mpz_struct const *)(e_acsl_5)); if (! (e_acsl_6 == 0)) { e_acsl_fail((char *)"(x == 0)"); } - mpz_clear((__mpz_struct *)(e_acsl_4)); - mpz_clear((__mpz_struct *)(e_acsl_5)); + __gmpz_clear((__mpz_struct *)(e_acsl_4)); + __gmpz_clear((__mpz_struct *)(e_acsl_5)); x ++; } - mpz_init_set_si((__mpz_struct *)(e_acsl_7),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_8),(long)1); - e_acsl_9 = mpz_cmp((__mpz_struct const *)(e_acsl_7), - (__mpz_struct const *)(e_acsl_8)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_7),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_8),(long)1); + e_acsl_9 = __gmpz_cmp((__mpz_struct const *)(e_acsl_7), + (__mpz_struct const *)(e_acsl_8)); if (! (e_acsl_9 == 0)) { e_acsl_fail((char *)"(x == 1)"); } - mpz_clear((__mpz_struct *)(e_acsl_7)); - mpz_clear((__mpz_struct *)(e_acsl_8)); + __gmpz_clear((__mpz_struct *)(e_acsl_7)); + __gmpz_clear((__mpz_struct *)(e_acsl_8)); } if (x) { @@ -270,23 +270,23 @@ int main(void) mpz_t e_acsl_10; mpz_t e_acsl_11; int e_acsl_12; - mpz_init_set_si((__mpz_struct *)(e_acsl_10),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_11),(long)1); - e_acsl_12 = mpz_cmp((__mpz_struct const *)(e_acsl_10), - (__mpz_struct const *)(e_acsl_11)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_10),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_11),(long)1); + e_acsl_12 = __gmpz_cmp((__mpz_struct const *)(e_acsl_10), + (__mpz_struct const *)(e_acsl_11)); if (! (e_acsl_12 == 0)) { e_acsl_fail((char *)"(x == 1)"); } - mpz_clear((__mpz_struct *)(e_acsl_10)); - mpz_clear((__mpz_struct *)(e_acsl_11)); + __gmpz_clear((__mpz_struct *)(e_acsl_10)); + __gmpz_clear((__mpz_struct *)(e_acsl_11)); x ++; } - mpz_init_set_si((__mpz_struct *)(e_acsl_13),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_14),(long)2); - e_acsl_15 = mpz_cmp((__mpz_struct const *)(e_acsl_13), - (__mpz_struct const *)(e_acsl_14)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_13),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_14),(long)2); + e_acsl_15 = __gmpz_cmp((__mpz_struct const *)(e_acsl_13), + (__mpz_struct const *)(e_acsl_14)); if (! (e_acsl_15 == 0)) { e_acsl_fail((char *)"(x == 2)"); } - mpz_clear((__mpz_struct *)(e_acsl_13)); - mpz_clear((__mpz_struct *)(e_acsl_14)); + __gmpz_clear((__mpz_struct *)(e_acsl_13)); + __gmpz_clear((__mpz_struct *)(e_acsl_14)); } } @@ -296,13 +296,13 @@ int main(void) } } - mpz_init_set_si((__mpz_struct *)(e_acsl_16),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_17),(long)1); - e_acsl_18 = mpz_cmp((__mpz_struct const *)(e_acsl_16), - (__mpz_struct const *)(e_acsl_17)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_16),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_17),(long)1); + e_acsl_18 = __gmpz_cmp((__mpz_struct const *)(e_acsl_16), + (__mpz_struct const *)(e_acsl_17)); if (! (e_acsl_18 >= 0)) { e_acsl_fail((char *)"(x >= 1)"); } - mpz_clear((__mpz_struct *)(e_acsl_16)); - mpz_clear((__mpz_struct *)(e_acsl_17)); + __gmpz_clear((__mpz_struct *)(e_acsl_16)); + __gmpz_clear((__mpz_struct *)(e_acsl_17)); } __retres = 0; diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/other_constants.res.oracle b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/other_constants.res.oracle index 9dd5837b9b37bf8df4144853ca589d7ea5caf4c4..bd930837970fa6a638fbe65a217fe7a1ab996ab8 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/other_constants.res.oracle +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/other_constants.res.oracle @@ -4,15 +4,15 @@ [value] Values of globals at initialization PROJECT_FILE.i:138:[value] Assertion got status unknown. PROJECT_FILE.i:141:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:145. -PROJECT_FILE.i:33:[value] Function mpz_init_set_si: postcondition got status valid. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +PROJECT_FILE.i:33:[value] Function __gmpz_init_set_si: postcondition got status valid. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:146. -PROJECT_FILE.i:49:[value] Function mpz_cmp: precondition got status valid. -PROJECT_FILE.i:50:[value] Function mpz_cmp: precondition got status valid. -[value] Done for function mpz_cmp +PROJECT_FILE.i:49:[value] Function __gmpz_cmp: precondition got status valid. +PROJECT_FILE.i:50:[value] Function __gmpz_cmp: precondition got status valid. +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:147. [value] computing for function printf <- e_acsl_fail <- main. @@ -24,10 +24,10 @@ PROJECT_FILE.i:119:[value] Function exit: postcondition got status invalid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:148. -PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. -[value] Done for function mpz_clear +PROJECT_FILE.i:43:[value] Function __gmpz_clear: precondition got status valid. +[value] Done for function __gmpz_clear PROJECT_FILE.i:152:[value] Assertion got status valid. [value] Recording results for main [value] done for function main @@ -51,15 +51,15 @@ enum bool { /*@ ensures \valid(\old(z)); assigns *z; assigns *z \from n; */ -extern void mpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); +extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); /*@ requires \valid(x); assigns *x; */ -extern void mpz_clear(__mpz_struct * /*[1]*/ x); +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); assigns \nothing; */ -extern int mpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ terminates \false; ensures \false; assigns \nothing; */ @@ -83,11 +83,11 @@ int main(void) { mpz_t e_acsl_1; int e_acsl_2; - mpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)'c'); - e_acsl_2 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_1)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)'c'); + e_acsl_2 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_1)); if (! (e_acsl_2 == 0)) { e_acsl_fail((char *)"(\'c\' == \'c\')"); } - mpz_clear((__mpz_struct *)(e_acsl_1)); + __gmpz_clear((__mpz_struct *)(e_acsl_1)); } /*@ assert false ≢ true; */ ; diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/ptr.res.oracle b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/ptr.res.oracle index ec9898e4f3b25f24c01fc2f0d513ab467f9db0e5..2a420a7925665366a84e3eafe75ee5f1ef3c1f08 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/ptr.res.oracle +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/ptr.res.oracle @@ -15,18 +15,18 @@ tests/e-acsl-runtime/ptr.i:26:[e-acsl] warning: missing guard for ensuring that [value] Initial state computed [value] Values of globals at initialization PROJECT_FILE.i:142:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:147. -PROJECT_FILE.i:33:[value] Function mpz_init_set_si: postcondition got status valid. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +PROJECT_FILE.i:33:[value] Function __gmpz_init_set_si: postcondition got status valid. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:148. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:149. -PROJECT_FILE.i:49:[value] Function mpz_cmp: precondition got status valid. -PROJECT_FILE.i:50:[value] Function mpz_cmp: precondition got status valid. -[value] Done for function mpz_cmp +PROJECT_FILE.i:49:[value] Function __gmpz_cmp: precondition got status valid. +PROJECT_FILE.i:50:[value] Function __gmpz_cmp: precondition got status valid. +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:150. [value] computing for function printf <- e_acsl_fail <- main. @@ -38,23 +38,23 @@ PROJECT_FILE.i:119:[value] Function exit: postcondition got status invalid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:151. -PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +PROJECT_FILE.i:43:[value] Function __gmpz_clear: precondition got status valid. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:152. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:156:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:161. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:162. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:163. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:164. [value] computing for function printf <- e_acsl_fail <- main. @@ -65,22 +65,22 @@ PROJECT_FILE.i:156:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:165. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:166. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:170:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:175. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:176. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:177. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:178. [value] computing for function printf <- e_acsl_fail <- main. @@ -91,41 +91,41 @@ PROJECT_FILE.i:170:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:179. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:180. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:184:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:197. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:198. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:199. -PROJECT_FILE.i:21:[value] Function mpz_init: postcondition got status valid. -[value] Done for function mpz_init -[value] computing for function mpz_mul <- main. +PROJECT_FILE.i:21:[value] Function __gmpz_init: postcondition got status valid. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_mul <- main. Called from PROJECT_FILE.i:200. -PROJECT_FILE.i:76:[value] Function mpz_mul: precondition got status valid. -PROJECT_FILE.i:77:[value] Function mpz_mul: precondition got status valid. -PROJECT_FILE.i:78:[value] Function mpz_mul: precondition got status valid. -[value] Done for function mpz_mul -[value] computing for function mpz_init_set_si <- main. +PROJECT_FILE.i:76:[value] Function __gmpz_mul: precondition got status valid. +PROJECT_FILE.i:77:[value] Function __gmpz_mul: precondition got status valid. +PROJECT_FILE.i:78:[value] Function __gmpz_mul: precondition got status valid. +[value] Done for function __gmpz_mul +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:201. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:202. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:203. -[value] Done for function mpz_cmp -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:204. -[value] Done for function mpz_init +[value] Done for function __gmpz_init PROJECT_FILE.i:205:[value] Assertion got status valid. [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:206. @@ -137,27 +137,27 @@ PROJECT_FILE.i:205:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_tdiv_q <- main. +[value] computing for function __gmpz_tdiv_q <- main. Called from PROJECT_FILE.i:207. -PROJECT_FILE.i:82:[value] Function mpz_tdiv_q: precondition got status valid. -PROJECT_FILE.i:83:[value] Function mpz_tdiv_q: precondition got status valid. -PROJECT_FILE.i:84:[value] Function mpz_tdiv_q: precondition got status valid. -[value] Done for function mpz_tdiv_q -[value] computing for function mpz_get_si <- main. +PROJECT_FILE.i:82:[value] Function __gmpz_tdiv_q: precondition got status valid. +PROJECT_FILE.i:83:[value] Function __gmpz_tdiv_q: precondition got status valid. +PROJECT_FILE.i:84:[value] Function __gmpz_tdiv_q: precondition got status valid. +[value] Done for function __gmpz_tdiv_q +[value] computing for function __gmpz_get_si <- main. Called from PROJECT_FILE.i:208. -PROJECT_FILE.i:96:[value] Function mpz_get_si: precondition got status valid. -[value] Done for function mpz_get_si +PROJECT_FILE.i:96:[value] Function __gmpz_get_si: precondition got status valid. +[value] Done for function __gmpz_get_si PROJECT_FILE.i:209:[kernel] warning: accessing out of bounds index [-2147483648..2147483647]. assert 0 ≤ e_acsl_17 ∧ e_acsl_17 < 3; -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:209. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:210. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:211. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:213. [value] computing for function printf <- e_acsl_fail <- main. @@ -168,53 +168,53 @@ PROJECT_FILE.i:209:[kernel] warning: accessing out of bounds index [-2147483648. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:215. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:216. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:217. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:218. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:219. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:220. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:221. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:222. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:229:[value] entering loop for the first time PROJECT_FILE.i:232:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:239. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:240. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:241. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:242. -[value] Done for function mpz_init -[value] computing for function mpz_add <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_add <- main. Called from PROJECT_FILE.i:243. -PROJECT_FILE.i:64:[value] Function mpz_add: precondition got status valid. -PROJECT_FILE.i:65:[value] Function mpz_add: precondition got status valid. -PROJECT_FILE.i:66:[value] Function mpz_add: precondition got status valid. -[value] Done for function mpz_add -[value] computing for function mpz_cmp <- main. +PROJECT_FILE.i:64:[value] Function __gmpz_add: precondition got status valid. +PROJECT_FILE.i:65:[value] Function __gmpz_add: precondition got status valid. +PROJECT_FILE.i:66:[value] Function __gmpz_add: precondition got status valid. +[value] Done for function __gmpz_add +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:244. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:245. [value] computing for function printf <- e_acsl_fail <- main. @@ -225,54 +225,54 @@ PROJECT_FILE.i:66:[value] Function mpz_add: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:246. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:247. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:248. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:249. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:253:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:263. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:264. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:265. -[value] Done for function mpz_init -[value] computing for function mpz_sub <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_sub <- main. Called from PROJECT_FILE.i:266. -PROJECT_FILE.i:70:[value] Function mpz_sub: precondition got status valid. -PROJECT_FILE.i:71:[value] Function mpz_sub: precondition got status valid. -PROJECT_FILE.i:72:[value] Function mpz_sub: precondition got status valid. -[value] Done for function mpz_sub -[value] computing for function mpz_get_si <- main. +PROJECT_FILE.i:70:[value] Function __gmpz_sub: precondition got status valid. +PROJECT_FILE.i:71:[value] Function __gmpz_sub: precondition got status valid. +PROJECT_FILE.i:72:[value] Function __gmpz_sub: precondition got status valid. +[value] Done for function __gmpz_sub +[value] computing for function __gmpz_get_si <- main. Called from PROJECT_FILE.i:267. -[value] Done for function mpz_get_si +[value] Done for function __gmpz_get_si PROJECT_FILE.i:268:[kernel] warning: accessing out of bounds index [-2147483648..2147483647]. assert 0 ≤ e_acsl_29 ∧ e_acsl_29 < 3; -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:268. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:269. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:270. -[value] Done for function mpz_init -[value] computing for function mpz_sub <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_sub <- main. Called from PROJECT_FILE.i:271. -[value] Done for function mpz_sub -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_sub +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:272. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:273. [value] computing for function printf <- e_acsl_fail <- main. @@ -283,43 +283,43 @@ PROJECT_FILE.i:268:[kernel] warning: accessing out of bounds index [-2147483648. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:274. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:275. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:276. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:277. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:278. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:279. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:283:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:290. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:291. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:292. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:293. -[value] Done for function mpz_init -[value] computing for function mpz_sub <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_sub <- main. Called from PROJECT_FILE.i:294. -[value] Done for function mpz_sub -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_sub +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:295. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:296. [value] computing for function printf <- e_acsl_fail <- main. @@ -330,37 +330,37 @@ PROJECT_FILE.i:283:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:297. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:298. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:299. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:300. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:232:[value] Assertion got status unknown. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:239. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:240. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:241. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:242. -[value] Done for function mpz_init -[value] computing for function mpz_add <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_add <- main. Called from PROJECT_FILE.i:243. -[value] Done for function mpz_add -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_add +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:244. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:245. [value] computing for function printf <- e_acsl_fail <- main. @@ -371,50 +371,50 @@ PROJECT_FILE.i:232:[value] Assertion got status unknown. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:246. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:247. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:248. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:249. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:253:[value] Assertion got status unknown. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:263. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:264. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:265. -[value] Done for function mpz_init -[value] computing for function mpz_sub <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_sub <- main. Called from PROJECT_FILE.i:266. -[value] Done for function mpz_sub -[value] computing for function mpz_get_si <- main. +[value] Done for function __gmpz_sub +[value] computing for function __gmpz_get_si <- main. Called from PROJECT_FILE.i:267. -[value] Done for function mpz_get_si +[value] Done for function __gmpz_get_si PROJECT_FILE.i:268:[value] Assertion got status unknown. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:268. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:269. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:270. -[value] Done for function mpz_init -[value] computing for function mpz_sub <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_sub <- main. Called from PROJECT_FILE.i:271. -[value] Done for function mpz_sub -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_sub +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:272. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:273. [value] computing for function printf <- e_acsl_fail <- main. @@ -425,43 +425,43 @@ PROJECT_FILE.i:268:[value] Assertion got status unknown. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:274. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:275. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:276. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:277. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:278. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:279. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:283:[value] Assertion got status unknown. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:290. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:291. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:292. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:293. -[value] Done for function mpz_init -[value] computing for function mpz_sub <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_sub <- main. Called from PROJECT_FILE.i:294. -[value] Done for function mpz_sub -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_sub +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:295. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:296. [value] computing for function printf <- e_acsl_fail <- main. @@ -472,29 +472,29 @@ PROJECT_FILE.i:283:[value] Assertion got status unknown. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:297. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:298. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:299. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:300. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:304:[value] assigning non deterministic value for the first time PROJECT_FILE.i:310:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:315. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:316. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:317. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:318. [value] computing for function printf <- e_acsl_fail <- main. @@ -505,12 +505,12 @@ PROJECT_FILE.i:310:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:319. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:320. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] Recording results for main [value] done for function main [value] ====== VALUES COMPUTED ====== @@ -533,54 +533,54 @@ typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; /*@ ensures \valid(\old(x)); assigns *x; */ -extern void mpz_init(__mpz_struct * /*[1]*/ x); +extern void __gmpz_init(__mpz_struct * /*[1]*/ x); /*@ ensures \valid(\old(z)); assigns *z; assigns *z \from n; */ -extern void mpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); +extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); /*@ requires \valid(x); assigns *x; */ -extern void mpz_clear(__mpz_struct * /*[1]*/ x); +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); assigns \nothing; */ -extern int mpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ requires \valid(z1); requires \valid(z2); requires \valid(z3); assigns *z1; */ -extern void mpz_add(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); +extern void __gmpz_add(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2, + __mpz_struct const * /*[1]*/ z3); /*@ requires \valid(z1); requires \valid(z2); requires \valid(z3); assigns *z1; */ -extern void mpz_sub(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); +extern void __gmpz_sub(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2, + __mpz_struct const * /*[1]*/ z3); /*@ requires \valid(z1); requires \valid(z2); requires \valid(z3); assigns *z1; */ -extern void mpz_mul(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); +extern void __gmpz_mul(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2, + __mpz_struct const * /*[1]*/ z3); /*@ requires \valid(z1); requires \valid(z2); requires \valid(z3); assigns *z1; */ -extern void mpz_tdiv_q(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); +extern void __gmpz_tdiv_q(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2, + __mpz_struct const * /*[1]*/ z3); /*@ requires \valid(z); assigns \nothing; */ -extern long mpz_get_si(__mpz_struct const * /*[1]*/ z); +extern long __gmpz_get_si(__mpz_struct const * /*[1]*/ z); /*@ terminates \false; ensures \false; assigns \nothing; */ @@ -610,13 +610,13 @@ int main(void) mpz_t e_acsl_1; mpz_t e_acsl_2; int e_acsl_3; - mpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)*p); - mpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)1); - e_acsl_3 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_2)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)*p); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)1); + e_acsl_3 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_2)); if (! (e_acsl_3 == 0)) { e_acsl_fail((char *)"(*p == 1)"); } - mpz_clear((__mpz_struct *)(e_acsl_1)); - mpz_clear((__mpz_struct *)(e_acsl_2)); + __gmpz_clear((__mpz_struct *)(e_acsl_1)); + __gmpz_clear((__mpz_struct *)(e_acsl_2)); } /*@ assert t[0] ≡ 2; */ ; @@ -624,13 +624,13 @@ int main(void) mpz_t e_acsl_4; mpz_t e_acsl_5; int e_acsl_6; - mpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)t[0]); - mpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)2); - e_acsl_6 = mpz_cmp((__mpz_struct const *)(e_acsl_4), - (__mpz_struct const *)(e_acsl_5)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)t[0]); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)2); + e_acsl_6 = __gmpz_cmp((__mpz_struct const *)(e_acsl_4), + (__mpz_struct const *)(e_acsl_5)); if (! (e_acsl_6 == 0)) { e_acsl_fail((char *)"(t[0] == 2)"); } - mpz_clear((__mpz_struct *)(e_acsl_4)); - mpz_clear((__mpz_struct *)(e_acsl_5)); + __gmpz_clear((__mpz_struct *)(e_acsl_4)); + __gmpz_clear((__mpz_struct *)(e_acsl_5)); } /*@ assert t[2] ≡ 4; */ ; @@ -638,13 +638,13 @@ int main(void) mpz_t e_acsl_7; mpz_t e_acsl_8; int e_acsl_9; - mpz_init_set_si((__mpz_struct *)(e_acsl_7),(long)t[2]); - mpz_init_set_si((__mpz_struct *)(e_acsl_8),(long)4); - e_acsl_9 = mpz_cmp((__mpz_struct const *)(e_acsl_7), - (__mpz_struct const *)(e_acsl_8)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_7),(long)t[2]); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_8),(long)4); + e_acsl_9 = __gmpz_cmp((__mpz_struct const *)(e_acsl_7), + (__mpz_struct const *)(e_acsl_8)); if (! (e_acsl_9 == 0)) { e_acsl_fail((char *)"(t[2] == 4)"); } - mpz_clear((__mpz_struct *)(e_acsl_7)); - mpz_clear((__mpz_struct *)(e_acsl_8)); + __gmpz_clear((__mpz_struct *)(e_acsl_7)); + __gmpz_clear((__mpz_struct *)(e_acsl_8)); } /*@ assert t[(2*sizeof(int))/sizeof((int)0x0)] ≡ 4; */ ; @@ -660,39 +660,40 @@ int main(void) mpz_t e_acsl_18; mpz_t e_acsl_19; int e_acsl_20; - mpz_init_set_si((__mpz_struct *)(e_acsl_10),(long)2); - mpz_init_set_si((__mpz_struct *)(e_acsl_11),(long)4); - mpz_init((__mpz_struct *)(e_acsl_12)); - mpz_mul((__mpz_struct *)(e_acsl_12),(__mpz_struct const *)(e_acsl_10), - (__mpz_struct const *)(e_acsl_11)); - mpz_init_set_si((__mpz_struct *)(e_acsl_13),(long)4); - mpz_init_set_si((__mpz_struct *)(e_acsl_14),(long)0); - e_acsl_15 = mpz_cmp((__mpz_struct const *)(e_acsl_13), - (__mpz_struct const *)(e_acsl_14)); - mpz_init((__mpz_struct *)(e_acsl_16)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_10),(long)2); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_11),(long)4); + __gmpz_init((__mpz_struct *)(e_acsl_12)); + __gmpz_mul((__mpz_struct *)(e_acsl_12),(__mpz_struct const *)(e_acsl_10), + (__mpz_struct const *)(e_acsl_11)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_13),(long)4); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_14),(long)0); + e_acsl_15 = __gmpz_cmp((__mpz_struct const *)(e_acsl_13), + (__mpz_struct const *)(e_acsl_14)); + __gmpz_init((__mpz_struct *)(e_acsl_16)); /*@ assert sizeof((int)0x0) ≢ 0; */ ; if (e_acsl_15 == 0) { e_acsl_fail((char *)"(sizeof((int)0x0) == 0)"); } - mpz_tdiv_q((__mpz_struct *)(e_acsl_16),(__mpz_struct const *)(e_acsl_12), - (__mpz_struct const *)(e_acsl_13)); - e_acsl_17 = (int)mpz_get_si((__mpz_struct const *)(e_acsl_16)); + __gmpz_tdiv_q((__mpz_struct *)(e_acsl_16), + (__mpz_struct const *)(e_acsl_12), + (__mpz_struct const *)(e_acsl_13)); + e_acsl_17 = (int)__gmpz_get_si((__mpz_struct const *)(e_acsl_16)); /*@ assert 0 ≤ e_acsl_17 ∧ e_acsl_17 < 3; // synthesized */ - mpz_init_set_si((__mpz_struct *)(e_acsl_18),(long)t[e_acsl_17]); - mpz_init_set_si((__mpz_struct *)(e_acsl_19),(long)4); - e_acsl_20 = mpz_cmp((__mpz_struct const *)(e_acsl_18), - (__mpz_struct const *)(e_acsl_19)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_18),(long)t[e_acsl_17]); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_19),(long)4); + e_acsl_20 = __gmpz_cmp((__mpz_struct const *)(e_acsl_18), + (__mpz_struct const *)(e_acsl_19)); if (! (e_acsl_20 == 0)) { e_acsl_fail((char *)"(t[(2*sizeof(int))/sizeof((int)0x0)] == 4)"); } - mpz_clear((__mpz_struct *)(e_acsl_10)); - mpz_clear((__mpz_struct *)(e_acsl_11)); - mpz_clear((__mpz_struct *)(e_acsl_12)); - mpz_clear((__mpz_struct *)(e_acsl_13)); - mpz_clear((__mpz_struct *)(e_acsl_14)); - mpz_clear((__mpz_struct *)(e_acsl_16)); - mpz_clear((__mpz_struct *)(e_acsl_18)); - mpz_clear((__mpz_struct *)(e_acsl_19)); + __gmpz_clear((__mpz_struct *)(e_acsl_10)); + __gmpz_clear((__mpz_struct *)(e_acsl_11)); + __gmpz_clear((__mpz_struct *)(e_acsl_12)); + __gmpz_clear((__mpz_struct *)(e_acsl_13)); + __gmpz_clear((__mpz_struct *)(e_acsl_14)); + __gmpz_clear((__mpz_struct *)(e_acsl_16)); + __gmpz_clear((__mpz_struct *)(e_acsl_18)); + __gmpz_clear((__mpz_struct *)(e_acsl_19)); } { @@ -707,20 +708,20 @@ int main(void) mpz_t e_acsl_23; mpz_t e_acsl_24; int e_acsl_25; - mpz_init_set_si((__mpz_struct *)(e_acsl_21),(long)t[i]); - mpz_init_set_si((__mpz_struct *)(e_acsl_22),(long)i); - mpz_init_set_si((__mpz_struct *)(e_acsl_23),(long)2); - mpz_init((__mpz_struct *)(e_acsl_24)); - mpz_add((__mpz_struct *)(e_acsl_24), - (__mpz_struct const *)(e_acsl_22), - (__mpz_struct const *)(e_acsl_23)); - e_acsl_25 = mpz_cmp((__mpz_struct const *)(e_acsl_21), - (__mpz_struct const *)(e_acsl_24)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_21),(long)t[i]); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_22),(long)i); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_23),(long)2); + __gmpz_init((__mpz_struct *)(e_acsl_24)); + __gmpz_add((__mpz_struct *)(e_acsl_24), + (__mpz_struct const *)(e_acsl_22), + (__mpz_struct const *)(e_acsl_23)); + e_acsl_25 = __gmpz_cmp((__mpz_struct const *)(e_acsl_21), + (__mpz_struct const *)(e_acsl_24)); if (! (e_acsl_25 == 0)) { e_acsl_fail((char *)"(t[i] == i+2)"); } - mpz_clear((__mpz_struct *)(e_acsl_21)); - mpz_clear((__mpz_struct *)(e_acsl_22)); - mpz_clear((__mpz_struct *)(e_acsl_23)); - mpz_clear((__mpz_struct *)(e_acsl_24)); + __gmpz_clear((__mpz_struct *)(e_acsl_21)); + __gmpz_clear((__mpz_struct *)(e_acsl_22)); + __gmpz_clear((__mpz_struct *)(e_acsl_23)); + __gmpz_clear((__mpz_struct *)(e_acsl_24)); } /*@ assert t[2-i] ≡ 4-i; */ ; @@ -733,31 +734,31 @@ int main(void) mpz_t e_acsl_31; mpz_t e_acsl_32; int e_acsl_33; - mpz_init_set_si((__mpz_struct *)(e_acsl_26),(long)2); - mpz_init_set_si((__mpz_struct *)(e_acsl_27),(long)i); - mpz_init((__mpz_struct *)(e_acsl_28)); - mpz_sub((__mpz_struct *)(e_acsl_28), - (__mpz_struct const *)(e_acsl_26), - (__mpz_struct const *)(e_acsl_27)); - e_acsl_29 = (int)mpz_get_si((__mpz_struct const *)(e_acsl_28)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_26),(long)2); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_27),(long)i); + __gmpz_init((__mpz_struct *)(e_acsl_28)); + __gmpz_sub((__mpz_struct *)(e_acsl_28), + (__mpz_struct const *)(e_acsl_26), + (__mpz_struct const *)(e_acsl_27)); + e_acsl_29 = (int)__gmpz_get_si((__mpz_struct const *)(e_acsl_28)); /*@ assert 0 ≤ e_acsl_29 ∧ e_acsl_29 < 3; // synthesized */ - mpz_init_set_si((__mpz_struct *)(e_acsl_30),(long)t[e_acsl_29]); - mpz_init_set_si((__mpz_struct *)(e_acsl_31),(long)4); - mpz_init((__mpz_struct *)(e_acsl_32)); - mpz_sub((__mpz_struct *)(e_acsl_32), - (__mpz_struct const *)(e_acsl_31), - (__mpz_struct const *)(e_acsl_27)); - e_acsl_33 = mpz_cmp((__mpz_struct const *)(e_acsl_30), - (__mpz_struct const *)(e_acsl_32)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_30),(long)t[e_acsl_29]); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_31),(long)4); + __gmpz_init((__mpz_struct *)(e_acsl_32)); + __gmpz_sub((__mpz_struct *)(e_acsl_32), + (__mpz_struct const *)(e_acsl_31), + (__mpz_struct const *)(e_acsl_27)); + e_acsl_33 = __gmpz_cmp((__mpz_struct const *)(e_acsl_30), + (__mpz_struct const *)(e_acsl_32)); if (! (e_acsl_33 == 0)) { e_acsl_fail((char *)"(t[2-i] == 4-i)"); } - mpz_clear((__mpz_struct *)(e_acsl_26)); - mpz_clear((__mpz_struct *)(e_acsl_27)); - mpz_clear((__mpz_struct *)(e_acsl_28)); - mpz_clear((__mpz_struct *)(e_acsl_30)); - mpz_clear((__mpz_struct *)(e_acsl_31)); - mpz_clear((__mpz_struct *)(e_acsl_32)); + __gmpz_clear((__mpz_struct *)(e_acsl_26)); + __gmpz_clear((__mpz_struct *)(e_acsl_27)); + __gmpz_clear((__mpz_struct *)(e_acsl_28)); + __gmpz_clear((__mpz_struct *)(e_acsl_30)); + __gmpz_clear((__mpz_struct *)(e_acsl_31)); + __gmpz_clear((__mpz_struct *)(e_acsl_32)); } /*@ assert *(&t[2]-i) ≡ 4-i; */ ; @@ -767,21 +768,21 @@ int main(void) mpz_t e_acsl_36; mpz_t e_acsl_37; int e_acsl_38; - mpz_init_set_si((__mpz_struct *)(e_acsl_34),(long)*(& t[2] - i)); - mpz_init_set_si((__mpz_struct *)(e_acsl_35),(long)4); - mpz_init_set_si((__mpz_struct *)(e_acsl_36),(long)i); - mpz_init((__mpz_struct *)(e_acsl_37)); - mpz_sub((__mpz_struct *)(e_acsl_37), - (__mpz_struct const *)(e_acsl_35), - (__mpz_struct const *)(e_acsl_36)); - e_acsl_38 = mpz_cmp((__mpz_struct const *)(e_acsl_34), - (__mpz_struct const *)(e_acsl_37)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_34),(long)*(& t[2] - i)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_35),(long)4); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_36),(long)i); + __gmpz_init((__mpz_struct *)(e_acsl_37)); + __gmpz_sub((__mpz_struct *)(e_acsl_37), + (__mpz_struct const *)(e_acsl_35), + (__mpz_struct const *)(e_acsl_36)); + e_acsl_38 = __gmpz_cmp((__mpz_struct const *)(e_acsl_34), + (__mpz_struct const *)(e_acsl_37)); if (! (e_acsl_38 == 0)) { e_acsl_fail((char *)"(*(&t[2]-i) == 4-i)"); } - mpz_clear((__mpz_struct *)(e_acsl_34)); - mpz_clear((__mpz_struct *)(e_acsl_35)); - mpz_clear((__mpz_struct *)(e_acsl_36)); - mpz_clear((__mpz_struct *)(e_acsl_37)); + __gmpz_clear((__mpz_struct *)(e_acsl_34)); + __gmpz_clear((__mpz_struct *)(e_acsl_35)); + __gmpz_clear((__mpz_struct *)(e_acsl_36)); + __gmpz_clear((__mpz_struct *)(e_acsl_37)); } i ++; @@ -795,13 +796,13 @@ int main(void) mpz_t e_acsl_39; mpz_t e_acsl_40; int e_acsl_41; - mpz_init_set_si((__mpz_struct *)(e_acsl_39),(long)*p); - mpz_init_set_si((__mpz_struct *)(e_acsl_40),(long)5); - e_acsl_41 = mpz_cmp((__mpz_struct const *)(e_acsl_39), - (__mpz_struct const *)(e_acsl_40)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_39),(long)*p); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_40),(long)5); + e_acsl_41 = __gmpz_cmp((__mpz_struct const *)(e_acsl_39), + (__mpz_struct const *)(e_acsl_40)); if (! (e_acsl_41 == 0)) { e_acsl_fail((char *)"(*p == 5)"); } - mpz_clear((__mpz_struct *)(e_acsl_39)); - mpz_clear((__mpz_struct *)(e_acsl_40)); + __gmpz_clear((__mpz_struct *)(e_acsl_39)); + __gmpz_clear((__mpz_struct *)(e_acsl_40)); } __retres = 0; diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/result.res.oracle b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/result.res.oracle index e678905c8aa45ad17ed3d605850d79c92a7e0210..7e8190c259ba6dff237cd1c625824f2b179ffaaf 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/result.res.oracle +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/result.res.oracle @@ -6,24 +6,24 @@ tests/e-acsl-runtime/result.i:6:[e-acsl] warning: missing guard for ensuring tha Y ∈ {1} [value] computing for function f <- main. Called from PROJECT_FILE.i:188. -[value] computing for function mpz_init_set_si <- f <- main. +[value] computing for function __gmpz_init_set_si <- f <- main. Called from PROJECT_FILE.i:143. -PROJECT_FILE.i:33:[value] Function mpz_init_set_si: postcondition got status valid. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- f <- main. +PROJECT_FILE.i:33:[value] Function __gmpz_init_set_si: postcondition got status valid. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- f <- main. Called from PROJECT_FILE.i:144. -PROJECT_FILE.i:21:[value] Function mpz_init: postcondition got status valid. -[value] Done for function mpz_init -[value] computing for function mpz_sub <- f <- main. +PROJECT_FILE.i:21:[value] Function __gmpz_init: postcondition got status valid. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_sub <- f <- main. Called from PROJECT_FILE.i:145. -PROJECT_FILE.i:70:[value] Function mpz_sub: precondition got status valid. -PROJECT_FILE.i:71:[value] Function mpz_sub: precondition got status valid. -PROJECT_FILE.i:72:[value] Function mpz_sub: precondition got status valid. -[value] Done for function mpz_sub -[value] computing for function mpz_get_si <- f <- main. +PROJECT_FILE.i:70:[value] Function __gmpz_sub: precondition got status valid. +PROJECT_FILE.i:71:[value] Function __gmpz_sub: precondition got status valid. +PROJECT_FILE.i:72:[value] Function __gmpz_sub: precondition got status valid. +[value] Done for function __gmpz_sub +[value] computing for function __gmpz_get_si <- f <- main. Called from PROJECT_FILE.i:146. -PROJECT_FILE.i:96:[value] Function mpz_get_si: precondition got status valid. -[value] Done for function mpz_get_si +PROJECT_FILE.i:96:[value] Function __gmpz_get_si: precondition got status valid. +[value] Done for function __gmpz_get_si [value] computing for function e_acsl_fail <- f <- main. Called from PROJECT_FILE.i:148. [value] computing for function printf <- e_acsl_fail <- f <- main. @@ -35,13 +35,13 @@ PROJECT_FILE.i:119:[value] Function exit: postcondition got status invalid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- f <- main. +[value] computing for function __gmpz_clear <- f <- main. Called from PROJECT_FILE.i:150. -PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- f <- main. +PROJECT_FILE.i:43:[value] Function __gmpz_clear: precondition got status valid. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- f <- main. Called from PROJECT_FILE.i:151. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:131:[value] Function f: postcondition got status valid. [value] Recording results for f [value] Done for function f @@ -52,17 +52,17 @@ PROJECT_FILE.i:158:[value] Function g: postcondition got status valid. [value] Done for function g [value] computing for function h <- main. Called from PROJECT_FILE.i:190. -[value] computing for function mpz_init_set_si <- h <- main. +[value] computing for function __gmpz_init_set_si <- h <- main. Called from PROJECT_FILE.i:174. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- h <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- h <- main. Called from PROJECT_FILE.i:175. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- h <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- h <- main. Called from PROJECT_FILE.i:176. -PROJECT_FILE.i:49:[value] Function mpz_cmp: precondition got status valid. -PROJECT_FILE.i:50:[value] Function mpz_cmp: precondition got status valid. -[value] Done for function mpz_cmp +PROJECT_FILE.i:49:[value] Function __gmpz_cmp: precondition got status valid. +PROJECT_FILE.i:50:[value] Function __gmpz_cmp: precondition got status valid. +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- h <- main. Called from PROJECT_FILE.i:177. [value] computing for function printf <- e_acsl_fail <- h <- main. @@ -73,12 +73,12 @@ PROJECT_FILE.i:50:[value] Function mpz_cmp: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- h <- main. +[value] computing for function __gmpz_clear <- h <- main. Called from PROJECT_FILE.i:178. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- h <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- h <- main. Called from PROJECT_FILE.i:179. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:165:[value] Function h: postcondition got status valid. [value] Recording results for h [value] Done for function h @@ -106,30 +106,30 @@ typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; /*@ ensures \valid(\old(x)); assigns *x; */ -extern void mpz_init(__mpz_struct * /*[1]*/ x); +extern void __gmpz_init(__mpz_struct * /*[1]*/ x); /*@ ensures \valid(\old(z)); assigns *z; assigns *z \from n; */ -extern void mpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); +extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); /*@ requires \valid(x); assigns *x; */ -extern void mpz_clear(__mpz_struct * /*[1]*/ x); +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); assigns \nothing; */ -extern int mpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ requires \valid(z1); requires \valid(z2); requires \valid(z3); assigns *z1; */ -extern void mpz_sub(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); +extern void __gmpz_sub(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2, + __mpz_struct const * /*[1]*/ z3); /*@ requires \valid(z); assigns \nothing; */ -extern long mpz_get_si(__mpz_struct const * /*[1]*/ z); +extern long __gmpz_get_si(__mpz_struct const * /*[1]*/ z); /*@ terminates \false; ensures \false; assigns \nothing; */ @@ -155,16 +155,16 @@ int f(int x) mpz_t e_acsl_2; mpz_t e_acsl_4; int e_acsl_5; - mpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)e_acsl_1); - mpz_init((__mpz_struct *)(e_acsl_4)); - mpz_sub((__mpz_struct *)(e_acsl_4),(__mpz_struct const *)(e_acsl_2), - (__mpz_struct const *)(e_acsl_2)); - e_acsl_5 = (int)mpz_get_si((__mpz_struct const *)(e_acsl_4)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)e_acsl_1); + __gmpz_init((__mpz_struct *)(e_acsl_4)); + __gmpz_sub((__mpz_struct *)(e_acsl_4),(__mpz_struct const *)(e_acsl_2), + (__mpz_struct const *)(e_acsl_2)); + e_acsl_5 = (int)__gmpz_get_si((__mpz_struct const *)(e_acsl_4)); if (! (x == e_acsl_5)) { e_acsl_fail((char *)"(\\result == (int)(\\old(x)-\\old(x)))"); } - mpz_clear((__mpz_struct *)(e_acsl_2)); - mpz_clear((__mpz_struct *)(e_acsl_4)); + __gmpz_clear((__mpz_struct *)(e_acsl_2)); + __gmpz_clear((__mpz_struct *)(e_acsl_4)); return (x); } @@ -187,13 +187,13 @@ int h(void) mpz_t e_acsl_1; mpz_t e_acsl_2; int e_acsl_3; - mpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)__retres); - mpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)0); - e_acsl_3 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_2)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)__retres); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)0); + e_acsl_3 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_2)); if (! (e_acsl_3 == 0)) { e_acsl_fail((char *)"(\\result == 0)"); } - mpz_clear((__mpz_struct *)(e_acsl_1)); - mpz_clear((__mpz_struct *)(e_acsl_2)); + __gmpz_clear((__mpz_struct *)(e_acsl_1)); + __gmpz_clear((__mpz_struct *)(e_acsl_2)); return (__retres); } diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/sizeof.res.oracle b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/sizeof.res.oracle index d8a69d2f46d1209e2d0e0547382cfddebf84bd29..5bb1671625b0973cdade87c838a1b262e8e88fc1 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/sizeof.res.oracle +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/sizeof.res.oracle @@ -3,18 +3,18 @@ [value] Initial state computed [value] Values of globals at initialization PROJECT_FILE.i:136:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:141. -PROJECT_FILE.i:33:[value] Function mpz_init_set_si: postcondition got status valid. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +PROJECT_FILE.i:33:[value] Function __gmpz_init_set_si: postcondition got status valid. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:142. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:143. -PROJECT_FILE.i:49:[value] Function mpz_cmp: precondition got status valid. -PROJECT_FILE.i:50:[value] Function mpz_cmp: precondition got status valid. -[value] Done for function mpz_cmp +PROJECT_FILE.i:49:[value] Function __gmpz_cmp: precondition got status valid. +PROJECT_FILE.i:50:[value] Function __gmpz_cmp: precondition got status valid. +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:144. [value] computing for function printf <- e_acsl_fail <- main. @@ -26,23 +26,23 @@ PROJECT_FILE.i:119:[value] Function exit: postcondition got status invalid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:145. -PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +PROJECT_FILE.i:43:[value] Function __gmpz_clear: precondition got status valid. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:146. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear PROJECT_FILE.i:150:[value] Assertion got status valid. -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:155. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:156. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:157. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:159. [value] computing for function printf <- e_acsl_fail <- main. @@ -53,12 +53,12 @@ PROJECT_FILE.i:150:[value] Assertion got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:161. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:162. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] Recording results for main [value] done for function main [value] ====== VALUES COMPUTED ====== @@ -78,15 +78,15 @@ typedef __mpz_struct mpz_t[1]; /*@ ensures \valid(\old(z)); assigns *z; assigns *z \from n; */ -extern void mpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); +extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); /*@ requires \valid(x); assigns *x; */ -extern void mpz_clear(__mpz_struct * /*[1]*/ x); +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); assigns \nothing; */ -extern int mpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ terminates \false; ensures \false; assigns \nothing; */ @@ -110,15 +110,15 @@ int main(void) mpz_t e_acsl_1; mpz_t e_acsl_2; int e_acsl_3; - mpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)4); - mpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)4); - e_acsl_3 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_2)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)4); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)4); + e_acsl_3 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_2)); if (! (e_acsl_3 == 0)) { e_acsl_fail((char *)"(sizeof(int) == sizeof(x))"); } - mpz_clear((__mpz_struct *)(e_acsl_1)); - mpz_clear((__mpz_struct *)(e_acsl_2)); + __gmpz_clear((__mpz_struct *)(e_acsl_1)); + __gmpz_clear((__mpz_struct *)(e_acsl_2)); } /*@ assert sizeof("totototototo") ≡ sizeof(char *); */ ; @@ -126,15 +126,15 @@ int main(void) mpz_t e_acsl_4; mpz_t e_acsl_5; int e_acsl_6; - mpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)4); - mpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)4); - e_acsl_6 = mpz_cmp((__mpz_struct const *)(e_acsl_4), - (__mpz_struct const *)(e_acsl_5)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)4); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)4); + e_acsl_6 = __gmpz_cmp((__mpz_struct const *)(e_acsl_4), + (__mpz_struct const *)(e_acsl_5)); if (! (e_acsl_6 == 0)) { e_acsl_fail((char *)"(sizeof(\"totototototo\") == sizeof(char *))"); } - mpz_clear((__mpz_struct *)(e_acsl_4)); - mpz_clear((__mpz_struct *)(e_acsl_5)); + __gmpz_clear((__mpz_struct *)(e_acsl_4)); + __gmpz_clear((__mpz_struct *)(e_acsl_5)); } __retres = 0; diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/stmt_contract.res.oracle b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/stmt_contract.res.oracle index 54e4e1622418c88730470dfd9010074a542779c4..fdd4bffc1e3f7f22cba70cce273bee4d83e939f9 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/stmt_contract.res.oracle +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/oracle/stmt_contract.res.oracle @@ -2,18 +2,18 @@ [value] Computing initial state [value] Initial state computed [value] Values of globals at initialization -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:144. -PROJECT_FILE.i:33:[value] Function mpz_init_set_si: postcondition got status valid. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +PROJECT_FILE.i:33:[value] Function __gmpz_init_set_si: postcondition got status valid. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:145. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:146. -PROJECT_FILE.i:49:[value] Function mpz_cmp: precondition got status valid. -PROJECT_FILE.i:50:[value] Function mpz_cmp: precondition got status valid. -[value] Done for function mpz_cmp +PROJECT_FILE.i:49:[value] Function __gmpz_cmp: precondition got status valid. +PROJECT_FILE.i:50:[value] Function __gmpz_cmp: precondition got status valid. +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:147. [value] computing for function printf <- e_acsl_fail <- main. @@ -25,22 +25,22 @@ PROJECT_FILE.i:119:[value] Function exit: postcondition got status invalid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:148. -PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +PROJECT_FILE.i:43:[value] Function __gmpz_clear: precondition got status valid. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:149. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:161. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:162. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:163. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:164. [value] computing for function printf <- e_acsl_fail <- main. @@ -51,12 +51,12 @@ PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:165. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:166. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:167. [value] computing for function printf <- e_acsl_fail <- main. @@ -67,24 +67,24 @@ PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:168. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:169. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:170. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:178. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:179. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:180. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:181. [value] computing for function printf <- e_acsl_fail <- main. @@ -95,21 +95,21 @@ PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:182. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:183. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:196. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:197. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:198. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:199. [value] computing for function printf <- e_acsl_fail <- main. @@ -120,15 +120,15 @@ PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:200. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:201. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:202. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:203. [value] computing for function printf <- e_acsl_fail <- main. @@ -139,27 +139,27 @@ PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:204. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:205. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:206. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:207. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:239. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:240. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:241. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:242. [value] computing for function printf <- e_acsl_fail <- main. @@ -170,25 +170,25 @@ PROJECT_FILE.i:43:[value] Function mpz_clear: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:243. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:244. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:245. -PROJECT_FILE.i:21:[value] Function mpz_init: postcondition got status valid. -[value] Done for function mpz_init -[value] computing for function mpz_add <- main. +PROJECT_FILE.i:21:[value] Function __gmpz_init: postcondition got status valid. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_add <- main. Called from PROJECT_FILE.i:246. -PROJECT_FILE.i:64:[value] Function mpz_add: precondition got status valid. -PROJECT_FILE.i:65:[value] Function mpz_add: precondition got status valid. -PROJECT_FILE.i:66:[value] Function mpz_add: precondition got status valid. -[value] Done for function mpz_add -[value] computing for function mpz_cmp <- main. +PROJECT_FILE.i:64:[value] Function __gmpz_add: precondition got status valid. +PROJECT_FILE.i:65:[value] Function __gmpz_add: precondition got status valid. +PROJECT_FILE.i:66:[value] Function __gmpz_add: precondition got status valid. +[value] Done for function __gmpz_add +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:247. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:248. [value] computing for function printf <- e_acsl_fail <- main. @@ -199,12 +199,12 @@ PROJECT_FILE.i:66:[value] Function mpz_add: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:249. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:250. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:251. [value] computing for function printf <- e_acsl_fail <- main. @@ -215,33 +215,33 @@ PROJECT_FILE.i:66:[value] Function mpz_add: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:252. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:253. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:254. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:255. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:256. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:257. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:261. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:262. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:263. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:264. [value] computing for function printf <- e_acsl_fail <- main. @@ -252,21 +252,21 @@ PROJECT_FILE.i:66:[value] Function mpz_add: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:265. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:266. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:267. -[value] Done for function mpz_init -[value] computing for function mpz_add <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_add <- main. Called from PROJECT_FILE.i:268. -[value] Done for function mpz_add -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_add +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:269. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:270. [value] computing for function printf <- e_acsl_fail <- main. @@ -277,46 +277,46 @@ PROJECT_FILE.i:66:[value] Function mpz_add: precondition got status valid. [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:271. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:272. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:273. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:274. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:275. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:301. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:302. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:303. -[value] Done for function mpz_cmp -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:309. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:310. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:311. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp PROJECT_FILE.i:312:[value] assigning non deterministic value for the first time -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:313. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:314. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:316. [value] computing for function printf <- e_acsl_fail <- main. @@ -327,42 +327,42 @@ PROJECT_FILE.i:312:[value] assigning non deterministic value for the first time [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_init_set_si <- main. +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:317. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:318. -[value] Done for function mpz_cmp -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:323. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:324. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:325. -[value] Done for function mpz_cmp -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:327. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:328. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:336. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:337. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:338. -[value] Done for function mpz_cmp -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:340. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:341. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:343. [value] computing for function printf <- e_acsl_fail <- main. @@ -373,54 +373,54 @@ PROJECT_FILE.i:312:[value] assigning non deterministic value for the first time [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_cmp <- main. +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:344. -[value] Done for function mpz_cmp -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:349. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:350. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:351. -[value] Done for function mpz_cmp -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:353. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:354. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:364. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:365. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init <- main. Called from PROJECT_FILE.i:366. -[value] Done for function mpz_init -[value] computing for function mpz_add <- main. +[value] Done for function __gmpz_init +[value] computing for function __gmpz_add <- main. Called from PROJECT_FILE.i:367. -[value] Done for function mpz_add -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_add +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:368. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:369. -[value] Done for function mpz_cmp -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_cmp +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:371. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:372. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:373. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:374. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:376. [value] computing for function printf <- e_acsl_fail <- main. @@ -431,24 +431,24 @@ PROJECT_FILE.i:312:[value] assigning non deterministic value for the first time [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:377. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:378. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:379. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:388. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:389. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:390. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:391. [value] computing for function printf <- e_acsl_fail <- main. @@ -459,21 +459,21 @@ PROJECT_FILE.i:312:[value] assigning non deterministic value for the first time [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:392. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:393. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:399. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:400. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:401. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:402. [value] computing for function printf <- e_acsl_fail <- main. @@ -484,21 +484,21 @@ PROJECT_FILE.i:312:[value] assigning non deterministic value for the first time [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:403. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:404. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:419. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:420. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:421. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:422. [value] computing for function printf <- e_acsl_fail <- main. @@ -509,21 +509,21 @@ PROJECT_FILE.i:312:[value] assigning non deterministic value for the first time [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:423. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:424. -[value] Done for function mpz_clear -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:428. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_init_set_si <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_init_set_si <- main. Called from PROJECT_FILE.i:429. -[value] Done for function mpz_init_set_si -[value] computing for function mpz_cmp <- main. +[value] Done for function __gmpz_init_set_si +[value] computing for function __gmpz_cmp <- main. Called from PROJECT_FILE.i:430. -[value] Done for function mpz_cmp +[value] Done for function __gmpz_cmp [value] computing for function e_acsl_fail <- main. Called from PROJECT_FILE.i:431. [value] computing for function printf <- e_acsl_fail <- main. @@ -534,12 +534,12 @@ PROJECT_FILE.i:312:[value] assigning non deterministic value for the first time [value] Done for function exit [value] Recording results for e_acsl_fail [value] Done for function e_acsl_fail -[value] computing for function mpz_clear <- main. +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:432. -[value] Done for function mpz_clear -[value] computing for function mpz_clear <- main. +[value] Done for function __gmpz_clear +[value] computing for function __gmpz_clear <- main. Called from PROJECT_FILE.i:433. -[value] Done for function mpz_clear +[value] Done for function __gmpz_clear [value] Recording results for main [value] done for function main [value] ====== VALUES COMPUTED ====== @@ -559,27 +559,27 @@ typedef struct __anonstruct___mpz_struct_1 __mpz_struct; typedef __mpz_struct mpz_t[1]; /*@ ensures \valid(\old(x)); assigns *x; */ -extern void mpz_init(__mpz_struct * /*[1]*/ x); +extern void __gmpz_init(__mpz_struct * /*[1]*/ x); /*@ ensures \valid(\old(z)); assigns *z; assigns *z \from n; */ -extern void mpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); +extern void __gmpz_init_set_si(__mpz_struct * /*[1]*/ z, long n); /*@ requires \valid(x); assigns *x; */ -extern void mpz_clear(__mpz_struct * /*[1]*/ x); +extern void __gmpz_clear(__mpz_struct * /*[1]*/ x); /*@ requires \valid(z1); requires \valid(z2); assigns \nothing; */ -extern int mpz_cmp(__mpz_struct const * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2); +extern int __gmpz_cmp(__mpz_struct const * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2); /*@ requires \valid(z1); requires \valid(z2); requires \valid(z3); assigns *z1; */ -extern void mpz_add(__mpz_struct * /*[1]*/ z1, - __mpz_struct const * /*[1]*/ z2, - __mpz_struct const * /*[1]*/ z3); +extern void __gmpz_add(__mpz_struct * /*[1]*/ z1, + __mpz_struct const * /*[1]*/ z2, + __mpz_struct const * /*[1]*/ z3); /*@ terminates \false; ensures \false; assigns \nothing; */ @@ -606,13 +606,13 @@ int main(void) mpz_t e_acsl_2; int e_acsl_3; x = 1; - mpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)1); - e_acsl_3 = mpz_cmp((__mpz_struct const *)(e_acsl_1), - (__mpz_struct const *)(e_acsl_2)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_1),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_2),(long)1); + e_acsl_3 = __gmpz_cmp((__mpz_struct const *)(e_acsl_1), + (__mpz_struct const *)(e_acsl_2)); if (! (e_acsl_3 == 0)) { e_acsl_fail((char *)"(x == 1)"); } - mpz_clear((__mpz_struct *)(e_acsl_1)); - mpz_clear((__mpz_struct *)(e_acsl_2)); + __gmpz_clear((__mpz_struct *)(e_acsl_1)); + __gmpz_clear((__mpz_struct *)(e_acsl_2)); } /*@ ensures x ≡ 2; @@ -624,18 +624,18 @@ int main(void) mpz_t e_acsl_7; int e_acsl_8; x = 2; - mpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)2); - e_acsl_6 = mpz_cmp((__mpz_struct const *)(e_acsl_4), - (__mpz_struct const *)(e_acsl_5)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_4),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_5),(long)2); + e_acsl_6 = __gmpz_cmp((__mpz_struct const *)(e_acsl_4), + (__mpz_struct const *)(e_acsl_5)); if (! (e_acsl_6 == 0)) { e_acsl_fail((char *)"(x == 2)"); } - mpz_init_set_si((__mpz_struct *)(e_acsl_7),(long)y); - e_acsl_8 = mpz_cmp((__mpz_struct const *)(e_acsl_7), - (__mpz_struct const *)(e_acsl_5)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_7),(long)y); + e_acsl_8 = __gmpz_cmp((__mpz_struct const *)(e_acsl_7), + (__mpz_struct const *)(e_acsl_5)); if (! (e_acsl_8 == 0)) { e_acsl_fail((char *)"(y == 2)"); } - mpz_clear((__mpz_struct *)(e_acsl_4)); - mpz_clear((__mpz_struct *)(e_acsl_5)); - mpz_clear((__mpz_struct *)(e_acsl_7)); + __gmpz_clear((__mpz_struct *)(e_acsl_4)); + __gmpz_clear((__mpz_struct *)(e_acsl_5)); + __gmpz_clear((__mpz_struct *)(e_acsl_7)); } /*@ requires x ≡ 2; */ @@ -643,13 +643,13 @@ int main(void) mpz_t e_acsl_9; mpz_t e_acsl_10; int e_acsl_11; - mpz_init_set_si((__mpz_struct *)(e_acsl_9),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_10),(long)2); - e_acsl_11 = mpz_cmp((__mpz_struct const *)(e_acsl_9), - (__mpz_struct const *)(e_acsl_10)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_9),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_10),(long)2); + e_acsl_11 = __gmpz_cmp((__mpz_struct const *)(e_acsl_9), + (__mpz_struct const *)(e_acsl_10)); if (! (e_acsl_11 == 0)) { e_acsl_fail((char *)"(x == 2)"); } - mpz_clear((__mpz_struct *)(e_acsl_9)); - mpz_clear((__mpz_struct *)(e_acsl_10)); + __gmpz_clear((__mpz_struct *)(e_acsl_9)); + __gmpz_clear((__mpz_struct *)(e_acsl_10)); x ++; } @@ -662,20 +662,20 @@ int main(void) mpz_t e_acsl_15; mpz_t e_acsl_16; int e_acsl_17; - mpz_init_set_si((__mpz_struct *)(e_acsl_12),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_13),(long)3); - e_acsl_14 = mpz_cmp((__mpz_struct const *)(e_acsl_12), - (__mpz_struct const *)(e_acsl_13)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_12),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_13),(long)3); + e_acsl_14 = __gmpz_cmp((__mpz_struct const *)(e_acsl_12), + (__mpz_struct const *)(e_acsl_13)); if (! (e_acsl_14 == 0)) { e_acsl_fail((char *)"(x == 3)"); } - mpz_init_set_si((__mpz_struct *)(e_acsl_15),(long)y); - mpz_init_set_si((__mpz_struct *)(e_acsl_16),(long)2); - e_acsl_17 = mpz_cmp((__mpz_struct const *)(e_acsl_15), - (__mpz_struct const *)(e_acsl_16)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_15),(long)y); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_16),(long)2); + e_acsl_17 = __gmpz_cmp((__mpz_struct const *)(e_acsl_15), + (__mpz_struct const *)(e_acsl_16)); if (! (e_acsl_17 == 0)) { e_acsl_fail((char *)"(y == 2)"); } - mpz_clear((__mpz_struct *)(e_acsl_12)); - mpz_clear((__mpz_struct *)(e_acsl_13)); - mpz_clear((__mpz_struct *)(e_acsl_15)); - mpz_clear((__mpz_struct *)(e_acsl_16)); + __gmpz_clear((__mpz_struct *)(e_acsl_12)); + __gmpz_clear((__mpz_struct *)(e_acsl_13)); + __gmpz_clear((__mpz_struct *)(e_acsl_15)); + __gmpz_clear((__mpz_struct *)(e_acsl_16)); x += y; } @@ -707,50 +707,51 @@ int main(void) int e_acsl_24; mpz_t e_acsl_25; int e_acsl_26; - mpz_init_set_si((__mpz_struct *)(e_acsl_18),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_19),(long)5); - e_acsl_20 = mpz_cmp((__mpz_struct const *)(e_acsl_18), - (__mpz_struct const *)(e_acsl_19)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_18),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_19),(long)5); + e_acsl_20 = __gmpz_cmp((__mpz_struct const *)(e_acsl_18), + (__mpz_struct const *)(e_acsl_19)); if (! (e_acsl_20 == 0)) { e_acsl_fail((char *)"(x == 5)"); } - mpz_init_set_si((__mpz_struct *)(e_acsl_21),(long)3); - mpz_init_set_si((__mpz_struct *)(e_acsl_22),(long)y); - mpz_init((__mpz_struct *)(e_acsl_23)); - mpz_add((__mpz_struct *)(e_acsl_23),(__mpz_struct const *)(e_acsl_21), - (__mpz_struct const *)(e_acsl_22)); - e_acsl_24 = mpz_cmp((__mpz_struct const *)(e_acsl_18), - (__mpz_struct const *)(e_acsl_23)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_21),(long)3); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_22),(long)y); + __gmpz_init((__mpz_struct *)(e_acsl_23)); + __gmpz_add((__mpz_struct *)(e_acsl_23), + (__mpz_struct const *)(e_acsl_21), + (__mpz_struct const *)(e_acsl_22)); + e_acsl_24 = __gmpz_cmp((__mpz_struct const *)(e_acsl_18), + (__mpz_struct const *)(e_acsl_23)); if (! (e_acsl_24 == 0)) { e_acsl_fail((char *)"(x == 3+y)"); } - mpz_init_set_si((__mpz_struct *)(e_acsl_25),(long)2); - e_acsl_26 = mpz_cmp((__mpz_struct const *)(e_acsl_22), - (__mpz_struct const *)(e_acsl_25)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_25),(long)2); + e_acsl_26 = __gmpz_cmp((__mpz_struct const *)(e_acsl_22), + (__mpz_struct const *)(e_acsl_25)); if (! (e_acsl_26 == 0)) { e_acsl_fail((char *)"(y == 2)"); } - mpz_clear((__mpz_struct *)(e_acsl_18)); - mpz_clear((__mpz_struct *)(e_acsl_19)); - mpz_clear((__mpz_struct *)(e_acsl_21)); - mpz_clear((__mpz_struct *)(e_acsl_22)); - mpz_clear((__mpz_struct *)(e_acsl_23)); - mpz_clear((__mpz_struct *)(e_acsl_25)); + __gmpz_clear((__mpz_struct *)(e_acsl_18)); + __gmpz_clear((__mpz_struct *)(e_acsl_19)); + __gmpz_clear((__mpz_struct *)(e_acsl_21)); + __gmpz_clear((__mpz_struct *)(e_acsl_22)); + __gmpz_clear((__mpz_struct *)(e_acsl_23)); + __gmpz_clear((__mpz_struct *)(e_acsl_25)); x = 3; } - mpz_init_set_si((__mpz_struct *)(e_acsl_27),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_28),(long)3); - e_acsl_29 = mpz_cmp((__mpz_struct const *)(e_acsl_27), - (__mpz_struct const *)(e_acsl_28)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_27),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_28),(long)3); + e_acsl_29 = __gmpz_cmp((__mpz_struct const *)(e_acsl_27), + (__mpz_struct const *)(e_acsl_28)); if (! (e_acsl_29 == 0)) { e_acsl_fail((char *)"(x == 3)"); } - mpz_init_set_si((__mpz_struct *)(e_acsl_30),(long)y); - mpz_init_set_si((__mpz_struct *)(e_acsl_31),(long)1); - mpz_init((__mpz_struct *)(e_acsl_32)); - mpz_add((__mpz_struct *)(e_acsl_32),(__mpz_struct const *)(e_acsl_30), - (__mpz_struct const *)(e_acsl_31)); - e_acsl_33 = mpz_cmp((__mpz_struct const *)(e_acsl_27), - (__mpz_struct const *)(e_acsl_32)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_30),(long)y); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_31),(long)1); + __gmpz_init((__mpz_struct *)(e_acsl_32)); + __gmpz_add((__mpz_struct *)(e_acsl_32),(__mpz_struct const *)(e_acsl_30), + (__mpz_struct const *)(e_acsl_31)); + e_acsl_33 = __gmpz_cmp((__mpz_struct const *)(e_acsl_27), + (__mpz_struct const *)(e_acsl_32)); if (! (e_acsl_33 == 0)) { e_acsl_fail((char *)"(x == y+1)"); } - mpz_clear((__mpz_struct *)(e_acsl_27)); - mpz_clear((__mpz_struct *)(e_acsl_28)); - mpz_clear((__mpz_struct *)(e_acsl_30)); - mpz_clear((__mpz_struct *)(e_acsl_31)); - mpz_clear((__mpz_struct *)(e_acsl_32)); + __gmpz_clear((__mpz_struct *)(e_acsl_27)); + __gmpz_clear((__mpz_struct *)(e_acsl_28)); + __gmpz_clear((__mpz_struct *)(e_acsl_30)); + __gmpz_clear((__mpz_struct *)(e_acsl_31)); + __gmpz_clear((__mpz_struct *)(e_acsl_32)); } /*@ behavior b1: @@ -776,38 +777,38 @@ int main(void) int e_acsl_51; int e_acsl_55; int e_acsl_61; - mpz_init_set_si((__mpz_struct *)(e_acsl_34),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_35),(long)1); - e_acsl_36 = mpz_cmp((__mpz_struct const *)(e_acsl_34), - (__mpz_struct const *)(e_acsl_35)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_34),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_35),(long)1); + e_acsl_36 = __gmpz_cmp((__mpz_struct const *)(e_acsl_34), + (__mpz_struct const *)(e_acsl_35)); if (! (e_acsl_36 == 0)) { e_acsl_40 = 1; } else { mpz_t e_acsl_37; mpz_t e_acsl_38; int e_acsl_39; - mpz_init_set_si((__mpz_struct *)(e_acsl_37),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_38),(long)0); - e_acsl_39 = mpz_cmp((__mpz_struct const *)(e_acsl_37), - (__mpz_struct const *)(e_acsl_38)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_37),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_38),(long)0); + e_acsl_39 = __gmpz_cmp((__mpz_struct const *)(e_acsl_37), + (__mpz_struct const *)(e_acsl_38)); e_acsl_40 = e_acsl_39 == 0; - mpz_clear((__mpz_struct *)(e_acsl_37)); - mpz_clear((__mpz_struct *)(e_acsl_38)); + __gmpz_clear((__mpz_struct *)(e_acsl_37)); + __gmpz_clear((__mpz_struct *)(e_acsl_38)); } if (! e_acsl_40) { e_acsl_fail((char *)"(x == 1 ==> x == 0)"); } - mpz_init_set_si((__mpz_struct *)(e_acsl_41),(long)3); - e_acsl_42 = mpz_cmp((__mpz_struct const *)(e_acsl_34), - (__mpz_struct const *)(e_acsl_41)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_41),(long)3); + e_acsl_42 = __gmpz_cmp((__mpz_struct const *)(e_acsl_34), + (__mpz_struct const *)(e_acsl_41)); if (e_acsl_42 == 0) { mpz_t e_acsl_43; mpz_t e_acsl_44; int e_acsl_45; - mpz_init_set_si((__mpz_struct *)(e_acsl_43),(long)y); - mpz_init_set_si((__mpz_struct *)(e_acsl_44),(long)2); - e_acsl_45 = mpz_cmp((__mpz_struct const *)(e_acsl_43), - (__mpz_struct const *)(e_acsl_44)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_43),(long)y); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_44),(long)2); + e_acsl_45 = __gmpz_cmp((__mpz_struct const *)(e_acsl_43), + (__mpz_struct const *)(e_acsl_44)); e_acsl_46 = e_acsl_45 == 0; - mpz_clear((__mpz_struct *)(e_acsl_43)); - mpz_clear((__mpz_struct *)(e_acsl_44)); + __gmpz_clear((__mpz_struct *)(e_acsl_43)); + __gmpz_clear((__mpz_struct *)(e_acsl_44)); } else { e_acsl_46 = 0; } if (! e_acsl_46) { e_acsl_50 = 1; } @@ -815,29 +816,29 @@ int main(void) mpz_t e_acsl_47; mpz_t e_acsl_48; int e_acsl_49; - mpz_init_set_si((__mpz_struct *)(e_acsl_47),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_48),(long)3); - e_acsl_49 = mpz_cmp((__mpz_struct const *)(e_acsl_47), - (__mpz_struct const *)(e_acsl_48)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_47),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_48),(long)3); + e_acsl_49 = __gmpz_cmp((__mpz_struct const *)(e_acsl_47), + (__mpz_struct const *)(e_acsl_48)); e_acsl_50 = e_acsl_49 == 0; - mpz_clear((__mpz_struct *)(e_acsl_47)); - mpz_clear((__mpz_struct *)(e_acsl_48)); + __gmpz_clear((__mpz_struct *)(e_acsl_47)); + __gmpz_clear((__mpz_struct *)(e_acsl_48)); } if (! e_acsl_50) { e_acsl_fail((char *)"(x == 3 && y == 2 ==> x == 3)"); } - e_acsl_51 = mpz_cmp((__mpz_struct const *)(e_acsl_34), - (__mpz_struct const *)(e_acsl_41)); + e_acsl_51 = __gmpz_cmp((__mpz_struct const *)(e_acsl_34), + (__mpz_struct const *)(e_acsl_41)); if (e_acsl_51 == 0) { mpz_t e_acsl_52; mpz_t e_acsl_53; int e_acsl_54; - mpz_init_set_si((__mpz_struct *)(e_acsl_52),(long)y); - mpz_init_set_si((__mpz_struct *)(e_acsl_53),(long)2); - e_acsl_54 = mpz_cmp((__mpz_struct const *)(e_acsl_52), - (__mpz_struct const *)(e_acsl_53)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_52),(long)y); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_53),(long)2); + e_acsl_54 = __gmpz_cmp((__mpz_struct const *)(e_acsl_52), + (__mpz_struct const *)(e_acsl_53)); e_acsl_55 = e_acsl_54 == 0; - mpz_clear((__mpz_struct *)(e_acsl_52)); - mpz_clear((__mpz_struct *)(e_acsl_53)); + __gmpz_clear((__mpz_struct *)(e_acsl_52)); + __gmpz_clear((__mpz_struct *)(e_acsl_53)); } else { e_acsl_55 = 0; } if (! e_acsl_55) { e_acsl_61 = 1; } @@ -847,26 +848,27 @@ int main(void) mpz_t e_acsl_58; mpz_t e_acsl_59; int e_acsl_60; - mpz_init_set_si((__mpz_struct *)(e_acsl_56),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_57),(long)y); - mpz_init((__mpz_struct *)(e_acsl_58)); - mpz_add((__mpz_struct *)(e_acsl_58),(__mpz_struct const *)(e_acsl_56), - (__mpz_struct const *)(e_acsl_57)); - mpz_init_set_si((__mpz_struct *)(e_acsl_59),(long)5); - e_acsl_60 = mpz_cmp((__mpz_struct const *)(e_acsl_58), - (__mpz_struct const *)(e_acsl_59)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_56),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_57),(long)y); + __gmpz_init((__mpz_struct *)(e_acsl_58)); + __gmpz_add((__mpz_struct *)(e_acsl_58), + (__mpz_struct const *)(e_acsl_56), + (__mpz_struct const *)(e_acsl_57)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_59),(long)5); + e_acsl_60 = __gmpz_cmp((__mpz_struct const *)(e_acsl_58), + (__mpz_struct const *)(e_acsl_59)); e_acsl_61 = e_acsl_60 == 0; - mpz_clear((__mpz_struct *)(e_acsl_56)); - mpz_clear((__mpz_struct *)(e_acsl_57)); - mpz_clear((__mpz_struct *)(e_acsl_58)); - mpz_clear((__mpz_struct *)(e_acsl_59)); + __gmpz_clear((__mpz_struct *)(e_acsl_56)); + __gmpz_clear((__mpz_struct *)(e_acsl_57)); + __gmpz_clear((__mpz_struct *)(e_acsl_58)); + __gmpz_clear((__mpz_struct *)(e_acsl_59)); } if (! e_acsl_61) { e_acsl_fail((char *)"(x == 3 && y == 2 ==> x+y == 5)"); } - mpz_clear((__mpz_struct *)(e_acsl_34)); - mpz_clear((__mpz_struct *)(e_acsl_35)); - mpz_clear((__mpz_struct *)(e_acsl_41)); + __gmpz_clear((__mpz_struct *)(e_acsl_34)); + __gmpz_clear((__mpz_struct *)(e_acsl_35)); + __gmpz_clear((__mpz_struct *)(e_acsl_41)); x += y; } @@ -875,25 +877,25 @@ int main(void) mpz_t e_acsl_62; mpz_t e_acsl_63; int e_acsl_64; - mpz_init_set_si((__mpz_struct *)(e_acsl_62),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_63),(long)5); - e_acsl_64 = mpz_cmp((__mpz_struct const *)(e_acsl_62), - (__mpz_struct const *)(e_acsl_63)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_62),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_63),(long)5); + e_acsl_64 = __gmpz_cmp((__mpz_struct const *)(e_acsl_62), + (__mpz_struct const *)(e_acsl_63)); if (! (e_acsl_64 == 0)) { e_acsl_fail((char *)"(x == 5)"); } - mpz_clear((__mpz_struct *)(e_acsl_62)); - mpz_clear((__mpz_struct *)(e_acsl_63)); + __gmpz_clear((__mpz_struct *)(e_acsl_62)); + __gmpz_clear((__mpz_struct *)(e_acsl_63)); /*@ requires y ≡ 2; */ { mpz_t e_acsl_65; mpz_t e_acsl_66; int e_acsl_67; - mpz_init_set_si((__mpz_struct *)(e_acsl_65),(long)y); - mpz_init_set_si((__mpz_struct *)(e_acsl_66),(long)2); - e_acsl_67 = mpz_cmp((__mpz_struct const *)(e_acsl_65), - (__mpz_struct const *)(e_acsl_66)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_65),(long)y); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_66),(long)2); + e_acsl_67 = __gmpz_cmp((__mpz_struct const *)(e_acsl_65), + (__mpz_struct const *)(e_acsl_66)); if (! (e_acsl_67 == 0)) { e_acsl_fail((char *)"(y == 2)"); } - mpz_clear((__mpz_struct *)(e_acsl_65)); - mpz_clear((__mpz_struct *)(e_acsl_66)); + __gmpz_clear((__mpz_struct *)(e_acsl_65)); + __gmpz_clear((__mpz_struct *)(e_acsl_66)); x += y; } } @@ -908,23 +910,23 @@ int main(void) mpz_t e_acsl_68; mpz_t e_acsl_69; int e_acsl_70; - mpz_init_set_si((__mpz_struct *)(e_acsl_68),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_69),(long)7); - e_acsl_70 = mpz_cmp((__mpz_struct const *)(e_acsl_68), - (__mpz_struct const *)(e_acsl_69)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_68),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_69),(long)7); + e_acsl_70 = __gmpz_cmp((__mpz_struct const *)(e_acsl_68), + (__mpz_struct const *)(e_acsl_69)); if (! (e_acsl_70 == 0)) { e_acsl_fail((char *)"(x == 7)"); } - mpz_clear((__mpz_struct *)(e_acsl_68)); - mpz_clear((__mpz_struct *)(e_acsl_69)); + __gmpz_clear((__mpz_struct *)(e_acsl_68)); + __gmpz_clear((__mpz_struct *)(e_acsl_69)); __retres = 0; } - mpz_init_set_si((__mpz_struct *)(e_acsl_71),(long)x); - mpz_init_set_si((__mpz_struct *)(e_acsl_72),(long)7); - e_acsl_73 = mpz_cmp((__mpz_struct const *)(e_acsl_71), - (__mpz_struct const *)(e_acsl_72)); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_71),(long)x); + __gmpz_init_set_si((__mpz_struct *)(e_acsl_72),(long)7); + e_acsl_73 = __gmpz_cmp((__mpz_struct const *)(e_acsl_71), + (__mpz_struct const *)(e_acsl_72)); if (! (e_acsl_73 == 0)) { e_acsl_fail((char *)"(x == 7)"); } - mpz_clear((__mpz_struct *)(e_acsl_71)); - mpz_clear((__mpz_struct *)(e_acsl_72)); + __gmpz_clear((__mpz_struct *)(e_acsl_71)); + __gmpz_clear((__mpz_struct *)(e_acsl_72)); } return (__retres); diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/other_constants.i b/src/plugins/e-acsl/tests/e-acsl-runtime/other_constants.i index 39d8a7c4685434ac17605b9846f67e08a2556802..dd42af3185310dcc9a7e7072dbad2aa8150efcbc 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/other_constants.i +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/other_constants.i @@ -1,6 +1,6 @@ /* run.config COMMENT: non integer constants - EXECNOW: LOG gen_other_constants.c BIN gen_other_constants.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/other_constants.i -e-acsl-project p -e-acsl-include-headers -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_other_constants.c > /dev/null && gcc -o ./tests/e-acsl-runtime/result/gen_other_constants.out ./tests/e-acsl-runtime/result/gen_other_constants.c -lgmp && ./tests/e-acsl-runtime/result/gen_other_constants.out + EXECNOW: LOG gen_other_constants.c BIN gen_other_constants.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/other_constants.i -e-acsl-project p -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_other_constants.c > /dev/null && gcc -pedantic -o ./tests/e-acsl-runtime/result/gen_other_constants.out ./tests/e-acsl-runtime/result/gen_other_constants.c -lgmp && ./tests/e-acsl-runtime/result/gen_other_constants.out */ enum bool { false, true }; diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/ptr.i b/src/plugins/e-acsl/tests/e-acsl-runtime/ptr.i index 3905d46925f81dcd04f0e3d7c094f5ab57c22265..a0ce8cfb9e343f1cf289c76a16d137594a95c797 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/ptr.i +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/ptr.i @@ -1,6 +1,6 @@ /* run.config COMMENT: pointers and pointer arithmetic - EXECNOW: LOG gen_ptr.c BIN gen_ptr.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/ptr.i -e-acsl-project p -e-acsl-include-headers -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_ptr.c > /dev/null && gcc -o ./tests/e-acsl-runtime/result/gen_ptr.out ./tests/e-acsl-runtime/result/gen_ptr.c -lgmp && ./tests/e-acsl-runtime/result/gen_ptr.out + EXECNOW: LOG gen_ptr.c BIN gen_ptr.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/ptr.i -e-acsl-project p -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_ptr.c > /dev/null && gcc -pedantic -o ./tests/e-acsl-runtime/result/gen_ptr.out ./tests/e-acsl-runtime/result/gen_ptr.c -lgmp && ./tests/e-acsl-runtime/result/gen_ptr.out */ int main(void) { diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/result.i b/src/plugins/e-acsl/tests/e-acsl-runtime/result.i index 2e7e3c1602314fe178a7c925084d375eafa8f87b..ade096644dddfe9619f7ada85820cb70b7f955c0 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/result.i +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/result.i @@ -1,6 +1,6 @@ /* run.config COMMENT: \result - EXECNOW: LOG gen_result.c BIN gen_result.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/result.i -e-acsl-project p -e-acsl-include-headers -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_result.c > /dev/null && gcc -o ./tests/e-acsl-runtime/result/gen_result.out ./tests/e-acsl-runtime/result/gen_result.c -lgmp && ./tests/e-acsl-runtime/result/gen_result.out + EXECNOW: LOG gen_result.c BIN gen_result.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/result.i -e-acsl-project p -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_result.c > /dev/null && gcc -pedantic -o ./tests/e-acsl-runtime/result/gen_result.out ./tests/e-acsl-runtime/result/gen_result.c -lgmp && ./tests/e-acsl-runtime/result/gen_result.out */ /*@ ensures \result == (int)(x - x); */ diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/sizeof.i b/src/plugins/e-acsl/tests/e-acsl-runtime/sizeof.i index 7c701fe1de38428c40b3235c36073b4cdf73df8a..8c63c59874db757a2789ecd5aa39c39823ca7c93 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/sizeof.i +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/sizeof.i @@ -1,6 +1,6 @@ /* run.config COMMENT: sizeof - EXECNOW: LOG gen_sizeof.c BIN gen_sizeof.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/sizeof.i -e-acsl-project p -e-acsl-include-headers -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_sizeof.c > /dev/null && gcc -o ./tests/e-acsl-runtime/result/gen_sizeof.out ./tests/e-acsl-runtime/result/gen_sizeof.c -lgmp && ./tests/e-acsl-runtime/result/gen_sizeof.out + EXECNOW: LOG gen_sizeof.c BIN gen_sizeof.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/sizeof.i -e-acsl-project p -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_sizeof.c > /dev/null && gcc -pedantic -o ./tests/e-acsl-runtime/result/gen_sizeof.out ./tests/e-acsl-runtime/result/gen_sizeof.c -lgmp && ./tests/e-acsl-runtime/result/gen_sizeof.out */ int main(void) { diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/stmt_contract.i b/src/plugins/e-acsl/tests/e-acsl-runtime/stmt_contract.i index 60111c14b3f11f36fd221f441d6a87a2758390e5..7cce1e5ca103318d5641fe197d56f19b2c43de5e 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/stmt_contract.i +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/stmt_contract.i @@ -1,6 +1,6 @@ /* run.config COMMENT: stmt contract - EXECNOW: LOG gen_stmt_contract.c BIN gen_stmt_contract.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/stmt_contract.i -e-acsl-project p -e-acsl-include-headers -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_stmt_contract.c > /dev/null && gcc -o ./tests/e-acsl-runtime/result/gen_stmt_contract.out ./tests/e-acsl-runtime/result/gen_stmt_contract.c -lgmp && ./tests/e-acsl-runtime/result/gen_stmt_contract.out + EXECNOW: LOG gen_stmt_contract.c BIN gen_stmt_contract.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/stmt_contract.i -e-acsl-project p -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_stmt_contract.c > /dev/null && gcc -pedantic -o ./tests/e-acsl-runtime/result/gen_stmt_contract.out ./tests/e-acsl-runtime/result/gen_stmt_contract.c -lgmp && ./tests/e-acsl-runtime/result/gen_stmt_contract.out */ int main(void) { int x = 0, y = 2; diff --git a/src/plugins/e-acsl/tests/e-acsl-runtime/true.i b/src/plugins/e-acsl/tests/e-acsl-runtime/true.i index de30c16fa19864578f164842f1ccf8444c28714d..f7ce1b578c2c317fb249a89fdb0261b45a312288 100644 --- a/src/plugins/e-acsl/tests/e-acsl-runtime/true.i +++ b/src/plugins/e-acsl/tests/e-acsl-runtime/true.i @@ -1,9 +1,10 @@ /* run.config COMMENT: assert \true - EXECNOW: LOG gen_true.c BIN gen_true.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/true.i -e-acsl-project p -e-acsl-include-headers -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_true.c > /dev/null && gcc -o ./tests/e-acsl-runtime/result/gen_true.out ./tests/e-acsl-runtime/result/gen_true.c && ./tests/e-acsl-runtime/result/gen_true.out + EXECNOW: LOG gen_true.c BIN gen_true.out FRAMAC_SHARE=./share @frama-c@ ./tests/e-acsl-runtime/true.i -e-acsl-project p -then-on p -print -ocode ./tests/e-acsl-runtime/result/gen_true.c > /dev/null && gcc -pedantic -o ./tests/e-acsl-runtime/result/gen_true.out ./tests/e-acsl-runtime/result/gen_true.c && ./tests/e-acsl-runtime/result/gen_true.out */ int main(void) { int x = 0; + // /*@ assert \true == 0; */ // not yet implemented /*@ assert \true; */ return 0; } diff --git a/src/plugins/e-acsl/visit.ml b/src/plugins/e-acsl/visit.ml index 9fabddae6f66471fb1fa7be3fc0934008ef88c26..a02d675b0943aa3cb01c5a9dd86ca00b6f43e151 100644 --- a/src/plugins/e-acsl/visit.ml +++ b/src/plugins/e-acsl/visit.ml @@ -42,7 +42,9 @@ let context_sensitive ?loc env ctx is_mpz_string t_opt e = let e, env = if is_mpz_string then mk_mpz env e else e, env in if Mpz.is_t ty || is_mpz_string then (* cast the mpz into a C integer *) - let name = if isSignedInteger ty' then "mpz_get_si" else "mpz_get_ui" in + let name = + if isSignedInteger ty' then "__gmpz_get_si" else "__gmpz_get_ui" + in Options.warning ?source:(Extlib.opt_map fst loc) ~once:true @@ -120,11 +122,11 @@ let relation_to_binop = function | Rneq -> Ne let name_of_mpz_arith_bop = function - | PlusA -> "mpz_add" - | MinusA -> "mpz_sub" - | Mult -> "mpz_mul" - | Div -> "mpz_tdiv_q" - | Mod -> "mpz_tdiv_r" + | PlusA -> "__gmpz_add" + | MinusA -> "__gmpz_sub" + | Mult -> "__gmpz_mul" + | Div -> "__gmpz_tdiv_q" + | Mod -> "__gmpz_tdiv_r" | Lt | Gt | Le | Ge | Eq | Ne | BAnd | BXor | BOr | LAnd | LOr | Shiftlt | Shiftrt | PlusPI | IndexPI | MinusPI | MinusPP -> assert false @@ -207,8 +209,8 @@ and context_insensitive_term_to_exp env t = | TUnOp(Neg | BNot as op, t') -> let e, env = term_to_exp env Linteger t' in let name = match op with - | Neg -> "mpz_neg" - | BNot -> "mpz_com" + | Neg -> "__gmpz_neg" + | BNot -> "__gmpz_com" | LNot -> assert false in let e, env = @@ -405,7 +407,7 @@ and comparison_to_exp ?(loc=Location.unknown) ?e1 env bop t1 t2 t_opt = env t_opt intType - (fun v _ -> [ Misc.mk_call ~result:(var v) "mpz_cmp" [ e1; e2 ] ]) + (fun v _ -> [ Misc.mk_call ~result:(var v) "__gmpz_cmp" [ e1; e2 ] ]) in new_exp ?loc (BinOp(bop, e, zero ?loc, intType)), env | _ ->