https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115901
--- Comment #2 from Sam James <sjames at gcc dot gnu.org> --- expr.i: ``` void mpz_tdiv_r(); void mpz_get_str(); void main() { mpz_tdiv_r(mpz_get_str); } ``` libcoreutils_a-mini-gmp-gnulib.i: ``` typedef long mp_limb_t; int mpn_div_qr_invert___clz_c; mp_limb_t mpn_div_qr_invert_d0, mpn_div_qr_invert___clz_x, mpn_div_qr_1_preinv_qp_0, mpn_div_qr_1_preinv_nn, mpn_div_qr_1_preinv_q; struct gmp_div_inverse mpz_tdiv_r_bi; void __assert_fail(); typedef struct { int _mp_size } __mpz_struct; struct gmp_div_inverse { unsigned shift; mp_limb_t d1, d0 } mpn_div_qr_invert(struct gmp_div_inverse *inv, long dn) { if (dn) { for (; mpn_div_qr_invert___clz_x; mpn_div_qr_invert___clz_c++) ; inv->d1 = mpn_div_qr_invert___clz_c; __assert_fail(inv->d1); } else inv->d0 = mpn_div_qr_invert_d0; } void mpn_div_qr_1_preinv(struct gmp_div_inverse *inv) { __assert_fail(); __assert_fail(inv->shift); while (mpn_div_qr_1_preinv_nn) mpn_div_qr_1_preinv_qp_0 = mpn_div_qr_1_preinv_q; } void mpn_div_qr_preinv(struct gmp_div_inverse *inv) { mpn_div_qr_1_preinv(inv); if (inv->d0) if (inv->d1) __assert_fail(); } void mpz_tdiv_r() { __mpz_struct *d; struct gmp_div_inverse inv; mpn_div_qr_invert(&inv, d->_mp_size); mpn_div_qr_preinv(&inv); mpn_div_qr_1_preinv(&mpz_tdiv_r_bi); } ``` That's straight from cvise so not tidied at all. I need to do some other bits now. It should be doable to kill LTO dependence next