const-time: Add ct_memmov_cond, fix _gcry_mpih_set_cond.
* src/const-time.c (ct_memmov_cond): New. * src/const-time.h (ct_memmov_cond): New. * mpi/mpih-const-time.c (_gcry_mpih_set_cond): Use XOR and a MASK.
Cherry-pick master commit of:
bd08357436a9559766cd458d25781ee4f94012a2
ct_memmov_cond is like memcpy, but it allows use with overlapping
memory area when DST <= SRC. It's not like memmove because it doesn't
allow overlapping memory area when DST > SRC.
- Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>