Re: Bug#626129: perl: sh4: FTBFS: Failed at op/ver.t line 241
tags 626129 patch
thanks
Hi,
I made the patch which changed the optimization level of utf8.c from O2 to O1.
I understand that it is not right solutuon, I need to revise gcc.
Would you apply this patch until gcc is revised?
Best regards,
Nobuhiro
2011/5/9 Nobuhiro Iwamatsu <iwamatsu@nigauri.org>:
> Hi,
>
> 2011/5/9 Niko Tyni <ntyni@debian.org>:
>> On Mon, May 09, 2011 at 01:43:40PM +0900, Nobuhiro Iwamatsu wrote:
>>> Source: perl
>>> Version: 5.12.3-6
>>> Severity: wishlist
>>> User: debian-sh4@superh.org
>>> Usertags: sh4
>>> X-Debbugs-CC: debian-superh@lists.debian.org
>>
>>> Malformed UTF-8 character (13 bytes, need 13, after start byte 0xff)
>>> in sprintf at op/ver.t line 241.
>>> # Failed at op/ver.t line 241
>>> # got "9223372036854775807.0"
>>> # expected "9223372036854775807.9223372036854775808"
>>> t/op/ver.......................................................FAILED at test 45
>>
>>> double value cannot display. But float is OK.
>>
>>> ./perl -e 'printf ("%vd\n", eval "v9223372036854775807.9223372036854775808")'
>>> Malformed UTF-8 character (13 bytes, need 13, after start byte 0xff)
>>> in printf at -e line 1.
>>> 9223372036854775807.0
>>> ./perl -e 'printf ("%vd\n", eval "v2147483647.214748364")'
>>> 2147483647.214748364
>>
>> I must say I don't understand this at all. Is there something exotic
>> about doubles on sh4?
>
> I debuged this and I understood that this was a bug of GCC.
> This problem is revised when I changed optimization from O2 to O1.
>
> Best regards,
> Nobuhiro
>
> --
> Nobuhiro Iwamatsu
> iwamatsu at {nigauri.org / debian.org}
> GPG ID: 40AD1FA6
>
--
Nobuhiro Iwamatsu
iwamatsu at {nigauri.org / debian.org}
GPG ID: 40AD1FA6
diff --git a/cflags.SH b/cflags.SH
index 6914ba6..e6785dc 100755
--- a/cflags.SH
+++ b/cflags.SH
@@ -321,7 +321,11 @@ for file do
toke) ;;
universal) ;;
usersub) ;;
- utf8) ;;
+ utf8)
+ case $archname in
+ sh4*-*)
+ optimize=-O1;;
+ esac;;
util) ;;
*) ;;
esac
Reply to: