multi_add_0, multi_add_1, multi_add_2, multi_add_3, multi_add_4, multi_add_5, multi_add_6, multi_add_7, multi_add_8
#include <flint/crt_helpers.h>Set z \gets z + a modulo B^n for the n-limb arrays z and a, where n is the suffix (0 \le n \le 8) and B = 2^{\mathtt{FLINT\_BITS}}; the carry out is discarded. multi_add_0 does nothing.
On x86-64 with AVX2 and on ARM64 these expand to the multi-limb macros of longlong.h (add_ssaaaa and its longer relatives), which compile to a single chain of add-with-carry instructions; elsewhere, including 32-bit platforms, the macros are used up to three limbs and mpn_add_n beyond (the macro CRT_HELPERS_UNROLLED_ADD tells which). The arrays must be identical or not overlap.
The FLINT team, “multi_add_0, multi_add_1, multi_add_2, multi_add_3, multi_add_4, multi_add_5, multi_add_6, multi_add_7, multi_add_8 (crt_helpers.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/crt_helpers/multi_add_0.html (generated 2026-10-20).
@misc{flint-doc-crt-helpers-multi-add-0,
author = {{The FLINT team}},
title = {{multi\_add\_0, multi\_add\_1, multi\_add\_2, multi\_add\_3, multi\_add\_4, multi\_add\_5, multi\_add\_6, multi\_add\_7, multi\_add\_8 (crt\_helpers.h)}},
howpublished = {FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev},
year = {2026},
url = {https://flintlib.org/doc/crt_helpers/multi_add_0.html},
note = {Generated 2026-10-20}
}