|
LMMP 4.3.0
Lamina High-Precision Arithmetic Library
|
#include "impl/inlines.h"#include "mparam.h"#include "impl/mul_cache.h"#include "impl/tmp_alloc.h"#include "lmmp/lmmpn.h"函数 | |
| mp_limb_t | lmmp_div_mulinv_ (mp_ptr restrict dstq, mp_ptr restrict numa, mp_size_t na, mp_srcptr restrict numb, mp_size_t nb, mp_srcptr restrict invappr, mp_size_t ni) |
| void | lmmp_inv_prediv_ (mp_ptr dst, mp_srcptr numa, mp_size_t na, mp_size_t ni) |
| Copyright (C) 2026 HJimmyK (Jericho Knox) | |
| mp_limb_t lmmp_div_mulinv_ | ( | mp_ptr restrict | dstq, |
| mp_ptr restrict | numa, | ||
| mp_size_t | na, | ||
| mp_srcptr restrict | numb, | ||
| mp_size_t | nb, | ||
| mp_srcptr restrict | invappr, | ||
| mp_size_t | ni ) |
在文件 div_mulinv.c 第 56 行定义.
引用了 DIV_MULINV_MODM_CACHE_THRESHOLD, LIMB_B_2, lmmp_add_n_(), lmmp_assert, lmmp_cmp_(), lmmp_div_mulinv_(), lmmp_fft_cache_free_(), lmmp_fft_gr_cache_free_(), lmmp_fft_next_size_(), lmmp_inc, lmmp_mersenne_next_size_(), LMMP_MIN, lmmp_mul_(), lmmp_mul_fft_cache_(), lmmp_mul_fft_cache_init_(), lmmp_mul_mersenne_(), lmmp_mul_mersenne_cache_(), lmmp_mul_mersenne_cache_init_(), lmmp_mul_n_, lmmp_param_assert, lmmp_sub_1_(), lmmp_sub_n_(), lmmp_sub_nc_(), MUL_FFT_THRESHOLD, numb, restrict, TALLOC_TYPE, TEMP_DECL, TEMP_FREE , 以及 tp.
Copyright (C) 2026 HJimmyK (Jericho Knox)
除法前的逆元预计算,[dst,ni] = invappr( (ni+1 MSLs of numa) + 1 ) / B
This file is part of LMMP.
LMMP is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public License along with this library. If not, see https://www.gnu.org/licenses/.
SPDX-License-Identifier: LGPL-3.0-or-later
Copyright (C) 2026 HJimmyK (Jericho Knox)
| dst | 输出预计算逆元的缓冲区,长度为ni |
| numa | 输入操作数,长度为na |
| na | 输入操作数的 limb 长度 |
| ni | 预计算逆元的目标尺寸 |
在文件 div_mulinv.c 第 30 行定义.
引用了 LIMB_B_2, lmmp_add_1_(), lmmp_copy, lmmp_inv_prediv_(), lmmp_invappr_(), lmmp_param_assert, lmmp_zero, restrict, TALLOC_TYPE, TEMP_DECL, TEMP_FREE , 以及 tp.
被这些函数引用 dec_pow_extend_(), lmmp_div_(), lmmp_div_s_(), lmmp_inv_prediv_() , 以及 lmmp_to_str_().