GNU bug report logs -
#13030
factor: infinite loop on Linux/powerpc
Previous Next
Reported by: Colin Watson <cjwatson <at> ubuntu.com>
Date: Thu, 29 Nov 2012 17:51:01 UTC
Severity: normal
Done: Pádraig Brady <P <at> draigBrady.com>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
[Message part 1 (text/plain, inline)]
On 01/04/2013 02:47 PM, Pádraig Brady wrote:
> So what I'm going to do is pull all the _LP64 amendments to longlong.h
> and instead avoid it completely with this in factor.c:
>
> diff --git a/src/factor.c b/src/factor.c
> index 473eee7..95451a5 100644
> --- a/src/factor.c
> +++ b/src/factor.c
> @@ -118,7 +118,14 @@
> #endif
>
> #ifndef USE_LONGLONG_H
> -# define USE_LONGLONG_H 1
> +/* With the way we use longlong.h, it's only safe to use
> + when UWtype = UHWtype, as there were various cases
> + (as can be seen in the history for longlong.h) where
> + for example, _LP64 was required to enable W_TYPE_SIZE==64 code,
> + to avoid compile time or run time issues. */
> +# if LONG_MAX == INTMAX_MAX
> +# define USE_LONGLONG_H 1
> +# endif
> #endif
>
> #if USE_LONGLONG_H
>
> That works for i686 x86_64 and sparcv7 and sparcv9 at least.
No comments, so I'm pushing the attached.
thanks,
Pádraig.
[factor-asm-general.diff (text/x-patch, attachment)]
This bug report was last modified 12 years and 132 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.