Re: possible snprintf() regression in 3.3.2

2021-11-25 Thread Corinna Vinschen via Cygwin
On Nov 25 21:02, Takashi Yano via Cygwin wrote: > On Wed, 24 Nov 2021 10:28:13 +0100 > Corinna Vinschen wrote: > > On Nov 24 18:14, Takashi Yano via Cygwin wrote: > > > On Wed, 24 Nov 2021 17:52:04 +0900 > > > Takashi Yano wrote: > > > > The printed value is still something wrong... > > > > sqrt(2)

Re: possible snprintf() regression in 3.3.2

2021-11-25 Thread Takashi Yano via Cygwin
On Wed, 24 Nov 2021 10:28:13 +0100 Corinna Vinschen wrote: > On Nov 24 18:14, Takashi Yano via Cygwin wrote: > > On Wed, 24 Nov 2021 17:52:04 +0900 > > Takashi Yano wrote: > > > The printed value is still something wrong... > > > sqrt(2)*1e70 should be an integer value. > > > > I mean... > > > >

RE: possible snprintf() regression in 3.3.2

2021-11-24 Thread Lemke, Michael SF/HZA-ZI2E
On Wednesday, November 24, 2021 10:28 AM Corinna Vinschen wrote: > On Nov 24 18:14, Takashi Yano via Cygwin wrote: > > On Wed, 24 Nov 2021 17:52:04 +0900 > > Takashi Yano wrote: > > > The printed value is still something wrong... > > > sqrt(2)*1e70 should be an integer value. > > > > I mean... > >

Re: possible snprintf() regression in 3.3.2

2021-11-24 Thread Corinna Vinschen via Cygwin
On Nov 24 18:14, Takashi Yano via Cygwin wrote: > On Wed, 24 Nov 2021 17:52:04 +0900 > Takashi Yano wrote: > > The printed value is still something wrong... > > sqrt(2)*1e70 should be an integer value. > > I mean... > > sqrt(2)*1e70 is actually not an integer, however, double has mantissa > of on

Re: possible snprintf() regression in 3.3.2

2021-11-24 Thread Takashi Yano via Cygwin
On Wed, 24 Nov 2021 17:52:04 +0900 Takashi Yano wrote: > On Wed, 24 Nov 2021 12:40:55 +0900 > Takashi Yano wrote: > > On Tue, 23 Nov 2021 10:48:21 +0100 > > Corinna Vinschen wrote: > > > On Nov 23 17:34, Takashi Yano via Cygwin wrote: > > > > However, in reality, for example in the case: > > > > sn

Re: possible snprintf() regression in 3.3.2

2021-11-24 Thread Takashi Yano via Cygwin
On Wed, 24 Nov 2021 12:40:55 +0900 Takashi Yano wrote: > On Tue, 23 Nov 2021 10:48:21 +0100 > Corinna Vinschen wrote: > > On Nov 23 17:34, Takashi Yano via Cygwin wrote: > > > However, in reality, for example in the case: > > > snprintf(buf, sizeof(buf), "%.3f", 1234567890123456.789); > > > 'ndigit

Re: possible snprintf() regression in 3.3.2

2021-11-24 Thread Corinna Vinschen via Cygwin
On Nov 24 12:40, Takashi Yano via Cygwin wrote: > On Tue, 23 Nov 2021 10:48:21 +0100 > Corinna Vinschen wrote: > > On Nov 23 17:34, Takashi Yano via Cygwin wrote: > > > However, in reality, for example in the case: > > > snprintf(buf, sizeof(buf), "%.3f", 1234567890123456.789); > > > 'ndigits' is o

Re: possible snprintf() regression in 3.3.2

2021-11-23 Thread Takashi Yano via Cygwin
On Tue, 23 Nov 2021 10:48:21 +0100 Corinna Vinschen wrote: > On Nov 23 17:34, Takashi Yano via Cygwin wrote: > > However, in reality, for example in the case: > > snprintf(buf, sizeof(buf), "%.3f", 1234567890123456.789); > > 'ndigits' is only 3 even though total digits will be 20. > > > > So, Tony

Re: possible snprintf() regression in 3.3.2

2021-11-23 Thread Corinna Vinschen via Cygwin
On Nov 23 17:34, Takashi Yano via Cygwin wrote: > On Tue, 23 Nov 2021 10:23:02 +1100 > Tony Cook wrote: > > On Mon, Nov 22, 2021 at 02:04:06PM +0100, Corinna Vinschen via Cygwin wrote: > > > On Nov 22 11:34, Corinna Vinschen via Cygwin wrote: > > > > On Nov 21 11:16, Tony Cook wrote: > > > > > A si

Re: possible snprintf() regression in 3.3.2

2021-11-23 Thread Takashi Yano via Cygwin
On Tue, 23 Nov 2021 10:23:02 +1100 Tony Cook wrote: > On Mon, Nov 22, 2021 at 02:04:06PM +0100, Corinna Vinschen via Cygwin wrote: > > On Nov 22 11:34, Corinna Vinschen via Cygwin wrote: > > > On Nov 21 11:16, Tony Cook wrote: > > > > On Thu, Nov 18, 2021 at 09:08:40PM +, Sam Edge via Cygwin wr

Re: possible snprintf() regression in 3.3.2

2021-11-22 Thread Tony Cook
On Mon, Nov 22, 2021 at 02:04:06PM +0100, Corinna Vinschen via Cygwin wrote: > On Nov 22 11:34, Corinna Vinschen via Cygwin wrote: > > On Nov 21 11:16, Tony Cook wrote: > > > On Thu, Nov 18, 2021 at 09:08:40PM +, Sam Edge via Cygwin wrote: > > > > I use newlib on embedded with threading libs th

Re: possible snprintf() regression in 3.3.2

2021-11-22 Thread Corinna Vinschen via Cygwin
On Nov 22 11:34, Corinna Vinschen via Cygwin wrote: > On Nov 21 11:16, Tony Cook wrote: > > On Thu, Nov 18, 2021 at 09:08:40PM +, Sam Edge via Cygwin wrote: > > > I use newlib on embedded with threading libs that have predetermined > > > fixed thread stack sizes. While we tend to have more RAM

Re: possible snprintf() regression in 3.3.2

2021-11-22 Thread Corinna Vinschen via Cygwin
On Nov 21 11:16, Tony Cook wrote: > On Thu, Nov 18, 2021 at 09:08:40PM +, Sam Edge via Cygwin wrote: > > I use newlib on embedded with threading libs that have predetermined > > fixed thread stack sizes. While we tend to have more RAM than in former > > times we also have multiple thread stacks

Re: possible snprintf() regression in 3.3.2

2021-11-20 Thread Tony Cook
On Thu, Nov 18, 2021 at 09:08:40PM +, Sam Edge via Cygwin wrote: > I use newlib on embedded with threading libs that have predetermined > fixed thread stack sizes. While we tend to have more RAM than in former > times we also have multiple thread stacks. Use of alloca() or variable > length aut

Re: possible snprintf() regression in 3.3.2

2021-11-18 Thread Sam Edge via Cygwin
On 18/11/2021 14:27, Corinna Vinschen via Cygwin wrote: On Nov 18 16:11, Noel Grandin via Cygwin wrote: On 2021/11/18 3:19 pm, Corinna Vinschen via Cygwin wrote: My patch raised NDEC from 43 to 1023 to allow aproximately the same number of digits as glibc. Newlib strives to support embedded

Re: possible snprintf() regression in 3.3.2

2021-11-18 Thread Corinna Vinschen via Cygwin
On Nov 18 16:11, Noel Grandin via Cygwin wrote: > > > On 2021/11/18 3:19 pm, Corinna Vinschen via Cygwin wrote: > > My patch raised NDEC from 43 to 1023 to allow aproximately the same > > number of digits as glibc. Newlib strives to support embedded targets > > and bare metal. Some of them are

Re: possible snprintf() regression in 3.3.2

2021-11-18 Thread Noel Grandin via Cygwin
On 2021/11/18 3:19 pm, Corinna Vinschen via Cygwin wrote: My patch raised NDEC from 43 to 1023 to allow aproximately the same number of digits as glibc. Newlib strives to support embedded targets and bare metal. Some of them are lucky if they have a stack size of 1K. The outbuf buffer is cre

Re: possible snprintf() regression in 3.3.2

2021-11-18 Thread Corinna Vinschen via Cygwin
On Nov 18 20:35, Takashi Yano via Cygwin wrote: > On Thu, 18 Nov 2021 11:06:49 +1100 > Tony Cook wrote: > > On Wed, Nov 17, 2021 at 01:27:55PM +0100, Corinna Vinschen via Cygwin wrote: > > > I don't have a good solution. The old ldtoa code is lacking, for > > > switching newlib to gdtoa I simply d

Re: possible snprintf() regression in 3.3.2

2021-11-18 Thread Takashi Yano via Cygwin
On Thu, 18 Nov 2021 11:06:49 +1100 Tony Cook wrote: > On Wed, Nov 17, 2021 at 01:27:55PM +0100, Corinna Vinschen via Cygwin wrote: > > I don't have a good solution. The old ldtoa code is lacking, for > > switching newlib to gdtoa I simply don't have the time. On the newlib > > list was a short di

Re: possible snprintf() regression in 3.3.2

2021-11-17 Thread Tony Cook
On Wed, Nov 17, 2021 at 01:27:55PM +0100, Corinna Vinschen via Cygwin wrote: > On Nov 17 18:21, Takashi Yano via Cygwin wrote: > > On Wed, 17 Nov 2021 11:37:18 +1100 > > Tony Cook wrote: > > > This came up from regression testing perl. > > > > > > Regression testing of perl @4a1b9dd524007193213d39

Re: possible snprintf() regression in 3.3.2

2021-11-17 Thread Corinna Vinschen via Cygwin
On Nov 17 18:21, Takashi Yano via Cygwin wrote: > On Wed, 17 Nov 2021 11:37:18 +1100 > Tony Cook wrote: > > This came up from regression testing perl. > > > > Regression testing of perl @4a1b9dd524007193213d3919d6a331109608b90c > > used (from uname): > > [...] > I found the caused by the commit: >

Re: possible snprintf() regression in 3.3.2

2021-11-17 Thread Takashi Yano via Cygwin
On Wed, 17 Nov 2021 11:37:18 +1100 Tony Cook wrote: > This came up from regression testing perl. > > Regression testing of perl @4a1b9dd524007193213d3919d6a331109608b90c > used (from uname): > > cygwin_nt-10.0 fv-az177-186 3.3.1(0.34153) 2021-10-28 20:52 x86_64 cygwin > > this did not exhibit t

possible snprintf() regression in 3.3.2

2021-11-16 Thread Tony Cook
This came up from regression testing perl. Regression testing of perl @4a1b9dd524007193213d3919d6a331109608b90c used (from uname): cygwin_nt-10.0 fv-az177-186 3.3.1(0.34153) 2021-10-28 20:52 x86_64 cygwin this did not exhibit the problem. See https://github.com/Perl/perl5/runs/4084168038?chec