mpn_mul_2 doesn't do size=1
This commit is contained in:
parent
a2baca61f0
commit
b52aa5a59e
@ -57,7 +57,7 @@ mult (mpz_srcptr u, mpz_srcptr v, mpz_ptr w)
|
||||
}
|
||||
|
||||
#if HAVE_NATIVE_mpn_mul_2
|
||||
if (vsize <= 2)
|
||||
if (vsize <= 2 && usize >= vsize)
|
||||
{
|
||||
MPZ_REALLOC (w, usize+vsize);
|
||||
wp = PTR(w);
|
||||
|
@ -833,7 +833,7 @@ refmpn_mul_2 (mp_ptr dst, mp_srcptr src, mp_size_t size, mp_srcptr mult)
|
||||
|
||||
ASSERT (refmpn_overlap_fullonly_p (dst, src, size));
|
||||
ASSERT (! refmpn_overlap_p (dst, size+1, mult, (mp_size_t) 2));
|
||||
ASSERT (size >= 1);
|
||||
ASSERT (size >= 2);
|
||||
ASSERT_MPN (mult, 2);
|
||||
|
||||
/* in case dst==src */
|
||||
|
Loading…
Reference in New Issue
Block a user