Test multiplying two long long ints.

When using clang with -ftrapv or -sanitize=integer the tests would pass
but linking would fail with "undefined reference to __mulodi4".
Explicitly test for this before enabling -trapv.
This commit is contained in:
Darren Tucker 2016-08-17 13:35:43 +10:00
parent a1cc637e7e
commit a8fc0f42e1
1 changed files with 4 additions and 4 deletions

8
aclocal.m4 vendored
View File

@ -1,5 +1,3 @@
dnl $Id: aclocal.m4,v 1.13 2014/01/22 10:30:12 djm Exp $
dnl
dnl OpenSSH-specific autoconf macros
dnl
@ -59,7 +57,8 @@ int main(int argc, char **argv) {
float l = i * 2.1;
double m = l / 0.5;
long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
long long int p = n * o;
printf("%d %d %d %f %f %lld %lld %lld\n", i, j, k, l, m, n, o, p);
exit(0);
}
]])],
@ -96,7 +95,8 @@ int main(int argc, char **argv) {
float l = i * 2.1;
double m = l / 0.5;
long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
long long p = n * o;
printf("%d %d %d %f %f %lld %lld %lld\n", i, j, k, l, m, n, o, p);
exit(0);
}
]])],