NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: lib/59652: DNS utilities core dump in -current
The following reply was made to PR toolchain/59652; it has been noted by GNATS.
From: Nick Hudson <nick.hudson%gmx.co.uk@localhost>
To: gnats-bugs%netbsd.org@localhost, lib-bug-people%netbsd.org@localhost, gnats-admin%netbsd.org@localhost,
netbsd-bugs%netbsd.org@localhost, brandon%burn.net@localhost
Cc:
Subject: Re: lib/59652: DNS utilities core dump in -current
Date: Mon, 29 Sep 2025 18:27:01 +0100
More analysis shows me it's a ld.elf_so bug that means the data isn't=20
aligned correctly relative to the struct tcb_tls for__HAVE_TLS_VARIANT_I
I didn't check __HAVE_TLS_VARIANT_II yet.
Here's a little test program that fails.
#include <inttypes.h>
#include <assert.h>
#define ALIGNMENT 64
#define MAGIC1 0xaa55aa55aa55aa55
#define MAGIC2 0xc0ffeeeeeeeeeeee
#define MAGIC3 0xff00ff00ff00ff00
__thread
struct {
uint64_t magic1;
uint64_t magic2 __attribute__((aligned(ALIGNMENT)));
uint64_t magic3;
} tls_data =3D {
.magic1 =3D MAGIC1,
.magic2 =3D MAGIC2,
.magic3 =3D MAGIC3,
};
int
main()
{
assert(tls_data.magic1 =3D=3D MAGIC1);
assert(tls_data.magic2 =3D=3D MAGIC2);
assert(tls_data.magic3 =3D=3D MAGIC3);
}
Home |
Main Index |
Thread Index |
Old Index