bug-gnulib@gnu.org mirror (unofficial)
 help / color / mirror / Atom feed
* FAIL in diffutils/gnulib-tests
@ 2023-02-06  1:17 Bjarni Ingi Gislason
  2023-02-06  1:28 ` Bruno Haible
  2023-02-07 23:08 ` Bjarni Ingi Gislason
  0 siblings, 2 replies; 6+ messages in thread
From: Bjarni Ingi Gislason @ 2023-02-06  1:17 UTC (permalink / raw)
  To: bug-gnulib

Latest master

locale is in /usr/share/i18n/locales/is_IS

% *_frac_* must be checked
int_frac_digits         0
frac_digits             0

============================================================
   GNU diffutils 3.9.12-c05c: gnulib-tests/test-suite.log
============================================================

# TOTAL: 204
# PASS:  169
# SKIP:  32
# XFAIL: 0
# FAIL:  3
# XPASS: 0
# ERROR: 0

.. contents:: :depth: 2

[...]

FAIL: test-c-stack2.sh
======================

FAIL test-c-stack2.sh (exit status: 1)

FAIL: test-localeconv
=====================

../../gnulib-tests/test-localeconv.c:53: assertion 'l->frac_digits == CHAR_MAX' failed
FAIL test-localeconv (exit status: 134)

[...]

FAIL: test-sigsegv-catch-stackoverflow2
=======================================

FAIL test-sigsegv-catch-stackoverflow2 (exit status: 132)

####

From the make run

File make_variables:

WERROR_CFLAGS= 

/usr/local/bin/make
GNU Make 4.4.0.90
Built for x86_64-pc-linux-gnu

[...]

## ---------------------------------------------------------------------- ##
## ---------------------------- Gnulib tests ---------------------------- ##
## Please report test failures in this directory to <bug-gnulib@gnu.org>. ##
## ---------------------------------------------------------------------- ##

[...]

FAIL: test-c-stack2.sh
[...]
PASS: test-locale
../../build-aux/test-driver: line 112: 272289 Aborted                 (core dumped) "$@" >> "$log_file" 2>&1
FAIL: test-localeconv
[...]
PASS: test-sigsegv-catch-stackoverflow1
../../build-aux/test-driver: line 112: 272705 Illegal instruction     (core dumped) "$@" >> "$log_file" 2>&1
FAIL: test-sigsegv-catch-stackoverflow2
[...]

####


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: FAIL in diffutils/gnulib-tests
  2023-02-06  1:17 FAIL in diffutils/gnulib-tests Bjarni Ingi Gislason
@ 2023-02-06  1:28 ` Bruno Haible
  2023-02-06  3:19   ` Bjarni Ingi Gislason
  2023-02-07 23:08 ` Bjarni Ingi Gislason
  1 sibling, 1 reply; 6+ messages in thread
From: Bruno Haible @ 2023-02-06  1:28 UTC (permalink / raw)
  To: bug-gnulib; +Cc: Bjarni Ingi Gislason

Bjarni Ingi Gislason wrote:
>    GNU diffutils 3.9.12-c05c: gnulib-tests/test-suite.log

Please try again with the tarball that you can download from
https://gitlab.com/gnu-diffutils/ci-distcheck
(full URL: https://gitlab.com/gnu-diffutils/ci-distcheck/-/jobs/artifacts/main/raw/diffutils-snapshot.tar?job=check-optimized ).

If you cannot reproduce with that snapshot tarball, the cause
must be in the operations you did in that git repository after
'git clone'.

If you *can* reproduce with that snapshot tarball, then please
also state the distro that you are using. Because:

> Built for x86_64-pc-linux-gnu

This can be very recent. This can also be 15 years old.

Recall that one of the purposes of a bug report is to allow us
to reproduce it. If all you say is "Built for x86_64-pc-linux-gnu",
there are hundreds of possible distros.

Bruno





^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: FAIL in diffutils/gnulib-tests
  2023-02-06  1:28 ` Bruno Haible
@ 2023-02-06  3:19   ` Bjarni Ingi Gislason
  2023-02-06 18:28     ` Bruno Haible
  0 siblings, 1 reply; 6+ messages in thread
From: Bjarni Ingi Gislason @ 2023-02-06  3:19 UTC (permalink / raw)
  To: Bruno Haible; +Cc: bug-gnulib

On Mon, Feb 06, 2023 at 02:28:03AM +0100, Bruno Haible wrote:
> Bjarni Ingi Gislason wrote:
> >    GNU diffutils 3.9.12-c05c: gnulib-tests/test-suite.log
> 
> Please try again with the tarball that you can download from
> https://gitlab.com/gnu-diffutils/ci-distcheck
> (full URL: https://gitlab.com/gnu-diffutils/ci-distcheck/-/jobs/artifacts/main/raw/diffutils-snapshot.tar?job=check-optimized ).
> 
[...]

Debian testing (bookworm/sid)

gcc (Debian 12.2.0-14) 12.2.0

GNU Make 4.4.0.90


  Differences between latest git repository and the tar file
"diffutils-2023-01-31".

  Similar text is shown on the terminal in both cases:

traps: test-c-stack[287115] trap invalid opcode ip:56214e4522af
sp:7ffde48af170 error:0 in test-c-stack[56214e452000+2000]

traps: test-sigsegv-ca[288174] trap invalid opcode ip:55f3cc5d047a
sp:7ffe4f87a9c0 error:0 in
test-sigsegv-catch-stackoverflow2[55f3cc5d0000+2000]

  The only difference concerning FAIL that I see is '>>' versus '>'.

-: from the git repository

+: the snapshot (tar file)


 PASS: test-locale
-../../build-aux/test-driver: line 112: 268125 Aborted                
(core dumped) "$@" >> "$log_file" 2>&1
+../../build-aux/test-driver: line 107: 287758 Aborted                
(core dumped) "$@" > $log_file 2>&1
 FAIL: test-localeconv
 PASS: test-lstat
 PASS: test-malloc-gnu
@@ -1734,7 +1734,7 @@ PASS: test-sigprocmask
 PASS: test-sigsegv-catch-segv1
 PASS: test-sigsegv-catch-segv2
 PASS: test-sigsegv-catch-stackoverflow1
-../../build-aux/test-driver: line 112: 268554 Illegal instruction    
(core dumped) "$@" >> "$log_file" 2>&1
+../../build-aux/test-driver: line 107: 288174 Illegal instruction    
(core dumped) "$@" > $log_file 2>&1
 FAIL: test-sigsegv-catch-stackoverflow2
 PASS: test-sleep

####

  There is a difference in code between the used test-drivers,
but they have the same scriptversion.

--- test-driver 2023-02-05 23:26:11.000000000 +0000
+++ /home/bg/Sottar.skrar/diffutils-2023-01-31/build-aux/test-driver   
2023-01-31 16:06:10.000000000 +0000
@@ -3,7 +3,7 @@

 scriptversion=2018-03-07.03; # UTC

-# Copyright (C) 2011-2021 Free Software Foundation, Inc.
+# Copyright (C) 2011-2018 Free Software Foundation, Inc.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: FAIL in diffutils/gnulib-tests
  2023-02-06  3:19   ` Bjarni Ingi Gislason
@ 2023-02-06 18:28     ` Bruno Haible
  0 siblings, 0 replies; 6+ messages in thread
From: Bruno Haible @ 2023-02-06 18:28 UTC (permalink / raw)
  To: Bjarni Ingi Gislason; +Cc: bug-gnulib

Bjarni Ingi Gislason wrote:
> On Mon, Feb 06, 2023 at 02:28:03AM +0100, Bruno Haible wrote:
> > Bjarni Ingi Gislason wrote:
> > >    GNU diffutils 3.9.12-c05c: gnulib-tests/test-suite.log
> > 
> > Please try again with the tarball that you can download from
> > https://gitlab.com/gnu-diffutils/ci-distcheck
> > (full URL: https://gitlab.com/gnu-diffutils/ci-distcheck/-/jobs/artifacts/main/raw/diffutils-snapshot.tar?job=check-optimized ).
> > 
> [...]
> 
> Debian testing (bookworm/sid)
> 
> gcc (Debian 12.2.0-14) 12.2.0
> 
> GNU Make 4.4.0.90
> 
> 
>   Differences between latest git repository and the tar file
> "diffutils-2023-01-31".
> 
>   Similar text is shown on the terminal in both cases:
> 
> traps: test-c-stack[287115] trap invalid opcode ip:56214e4522af
> sp:7ffde48af170 error:0 in test-c-stack[56214e452000+2000]
> 
> traps: test-sigsegv-ca[288174] trap invalid opcode ip:55f3cc5d047a
> sp:7ffe4f87a9c0 error:0 in
> test-sigsegv-catch-stackoverflow2[55f3cc5d0000+2000]
> 
>   The only difference concerning FAIL that I see is '>>' versus '>'.
> 
> -: from the git repository
> 
> +: the snapshot (tar file)
> 
> 
>  PASS: test-locale
> -../../build-aux/test-driver: line 112: 268125 Aborted                
> (core dumped) "$@" >> "$log_file" 2>&1
> +../../build-aux/test-driver: line 107: 287758 Aborted                
> (core dumped) "$@" > $log_file 2>&1
>  FAIL: test-localeconv
>  PASS: test-lstat
>  PASS: test-malloc-gnu
> @@ -1734,7 +1734,7 @@ PASS: test-sigprocmask
>  PASS: test-sigsegv-catch-segv1
>  PASS: test-sigsegv-catch-segv2
>  PASS: test-sigsegv-catch-stackoverflow1
> -../../build-aux/test-driver: line 112: 268554 Illegal instruction    
> (core dumped) "$@" >> "$log_file" 2>&1
> +../../build-aux/test-driver: line 107: 288174 Illegal instruction    
> (core dumped) "$@" > $log_file 2>&1
>  FAIL: test-sigsegv-catch-stackoverflow2
>  PASS: test-sleep

So, for you, this diffutils-2023-01-31 tarball fails
  - the stack overflow tests,
  - the localeconv test.

Where for me, on Debian testing (bookworm), downloaded from
https://cdimage.debian.org/cdimage/weekly-builds/amd64/iso-dvd/
with timestamp 2023-01-23, all tests pass.

This indicates that you are hitting bugs in this Debian "testing"
distro, that are already fixed.

Nothing to do in Gnulib, since it's normal for bugs to appear and
disappear in a "testing" (= alpha quality) distro.

Bruno





^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: FAIL in diffutils/gnulib-tests
  2023-02-06  1:17 FAIL in diffutils/gnulib-tests Bjarni Ingi Gislason
  2023-02-06  1:28 ` Bruno Haible
@ 2023-02-07 23:08 ` Bjarni Ingi Gislason
  2023-02-08  0:21   ` -funsigned-char Bruno Haible
  1 sibling, 1 reply; 6+ messages in thread
From: Bjarni Ingi Gislason @ 2023-02-07 23:08 UTC (permalink / raw)
  To: bug-gnulib

On Mon, Feb 06, 2023 at 01:17:29AM +0000, Bjarni Ingi Gislason wrote:
[...]
> 
> FAIL: test-c-stack2.sh
> ======================
> 
> FAIL test-c-stack2.sh (exit status: 1)
> 
> FAIL: test-localeconv
> =====================
> 
> ../../gnulib-tests/test-localeconv.c:53: assertion 'l->frac_digits == CHAR_MAX' failed
> FAIL test-localeconv (exit status: 134)
> 

l->frac_digits is 127 and  CHAR_MAX is 255.

  This is due to the CFLAG "-funsigned-char", which I always use having
compiled "less", which produced a lot of warnings without this flag.

  The other two "FAIL" and opcode issues are still there.

[...]


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: -funsigned-char
  2023-02-07 23:08 ` Bjarni Ingi Gislason
@ 2023-02-08  0:21   ` Bruno Haible
  0 siblings, 0 replies; 6+ messages in thread
From: Bruno Haible @ 2023-02-08  0:21 UTC (permalink / raw)
  To: bug-gnulib; +Cc: Bjarni Ingi Gislason

Bjarni Ingi Gislason wrote:
> > ../../gnulib-tests/test-localeconv.c:53: assertion 'l->frac_digits == CHAR_MAX' failed
> > FAIL test-localeconv (exit status: 134)
> > 
> 
> l->frac_digits is 127 and  CHAR_MAX is 255.
> 
>   This is due to the CFLAG "-funsigned-char"

When you connect a libc compiled for one ABI and a program compiled for a
different ABI (that's what -funsigned-char produces), you evidently get
breakage.

>   which I always use having
> compiled "less", which produced a lot of warnings without this flag.

The way to fix the problems occurring because a program wants to view
their strings as 'unsigned char *' is
  - NOT to use -funsigned-char, as you just have seen,
  - NOT to cast pointers from 'char *' to 'unsigned char *' and vice
    versa, because ultimately this leads to strict aliasing violations
    in some places,
  - BUT to cast individual 'char *' elements to 'unsigned char' right
    after fetching them from the string. E.g.
       if (isalnum ((unsigned char) *p))

Bruno





^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2023-02-08  0:22 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-02-06  1:17 FAIL in diffutils/gnulib-tests Bjarni Ingi Gislason
2023-02-06  1:28 ` Bruno Haible
2023-02-06  3:19   ` Bjarni Ingi Gislason
2023-02-06 18:28     ` Bruno Haible
2023-02-07 23:08 ` Bjarni Ingi Gislason
2023-02-08  0:21   ` -funsigned-char Bruno Haible

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).