public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
@ 2021-12-07 13:23 doko at debian dot org
2021-12-07 13:31 ` [Bug d/103604] " rguenth at gcc dot gnu.org
` (26 more replies)
0 siblings, 27 replies; 28+ messages in thread
From: doko at debian dot org @ 2021-12-07 13:23 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
Bug ID: 103604
Summary: [12 Regression] trunk 20210506 fails to build in
libphobos on mips64el-linux-gnu
Product: gcc
Version: 12.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: d
Assignee: ibuclaw at gdcproject dot org
Reporter: doko at debian dot org
Target Milestone: ---
trunk 20211206 fails to build on mips64el-linux-gnu:
configure: error: can't compile D sources!
make[4]: *** [Makefile:23569: configure-stage1-target-libphobos] Error 1
using GCC 10.3 as the bootstrap compiler
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
@ 2021-12-07 13:31 ` rguenth at gcc dot gnu.org
2021-12-07 13:41 ` marxin at gcc dot gnu.org
` (25 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: rguenth at gcc dot gnu.org @ 2021-12-07 13:31 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|--- |12.0
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
2021-12-07 13:31 ` [Bug d/103604] " rguenth at gcc dot gnu.org
@ 2021-12-07 13:41 ` marxin at gcc dot gnu.org
2021-12-13 1:56 ` syq at debian dot org
` (24 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: marxin at gcc dot gnu.org @ 2021-12-07 13:41 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
Martin Liška <marxin at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Ever confirmed|0 |1
Last reconfirmed| |2021-12-07
CC| |marxin at gcc dot gnu.org
Status|UNCONFIRMED |WAITING
--- Comment #1 from Martin Liška <marxin at gcc dot gnu.org> ---
Can you please paste output of config.log file?
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
2021-12-07 13:31 ` [Bug d/103604] " rguenth at gcc dot gnu.org
2021-12-07 13:41 ` marxin at gcc dot gnu.org
@ 2021-12-13 1:56 ` syq at debian dot org
2021-12-13 7:56 ` syq at debian dot org
` (23 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: syq at debian dot org @ 2021-12-13 1:56 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
YunQiang Su <syq at debian dot org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |syq at debian dot org
--- Comment #2 from YunQiang Su <syq at debian dot org> ---
root@sid-mips64el:/build/gcc-12/gcc-12-12-20211211#
/build/gcc-12/gcc-12-12-20211211/build/./gcc/gdc
-B/build/gcc-12/gcc-12-12-20211211/build/./gcc/
-B/usr/mips64el-linux-gnuabi64/bin/ -B/usr/mips64el-linux-gnuabi64/lib/
-isystem /usr/mips64el-linux-gnuabi64/include -isystem
/usr/mips64el-linux-gnuabi64/sys-include -isystem
/build/gcc-12/gcc-12-12-20211211/build/sys-include -fno-checking -c
-fno-druntime -nostdinc -I
/build/gcc-12/gcc-12-12-20211211/src/libphobos/libdruntime -g -O2 xx.d
read error: Success
read error: Success
d21: error: unable to read module 'xx'
d21: note: Expected 'xx.d' or 'xx/package.d' in one of the following import
paths:
import path[0] = /build/gcc-12/gcc-12-12-20211211/src/libphobos/libdruntime
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (2 preceding siblings ...)
2021-12-13 1:56 ` syq at debian dot org
@ 2021-12-13 7:56 ` syq at debian dot org
2021-12-13 8:02 ` syq at debian dot org
` (22 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: syq at debian dot org @ 2021-12-13 7:56 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #3 from YunQiang Su <syq at debian dot org> ---
I got it.
it is not due to gcc itself, while due to *stat problem in glibc 2.33 for
MIPS64.
It seems we introduce a bug when try to fix y2106 problem for mips64.
I am try to dig it.
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (3 preceding siblings ...)
2021-12-13 7:56 ` syq at debian dot org
@ 2021-12-13 8:02 ` syq at debian dot org
2021-12-13 8:16 ` ibuclaw at gcc dot gnu.org
` (21 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: syq at debian dot org @ 2021-12-13 8:02 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #4 from YunQiang Su <syq at debian dot org> ---
but where is the stat_t of D is defined?
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (4 preceding siblings ...)
2021-12-13 8:02 ` syq at debian dot org
@ 2021-12-13 8:16 ` ibuclaw at gcc dot gnu.org
2021-12-13 10:40 ` syq at debian dot org
` (20 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: ibuclaw at gcc dot gnu.org @ 2021-12-13 8:16 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
ibuclaw at gcc dot gnu.org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |ibuclaw at gcc dot gnu.org
--- Comment #5 from ibuclaw at gcc dot gnu.org ---
(In reply to YunQiang Su from comment #4)
> but where is the stat_t of D is defined?
In libphobos/libdruntime/core/sys/posix/sys/stat.d
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (5 preceding siblings ...)
2021-12-13 8:16 ` ibuclaw at gcc dot gnu.org
@ 2021-12-13 10:40 ` syq at debian dot org
2021-12-13 10:42 ` syq at debian dot org
` (19 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: syq at debian dot org @ 2021-12-13 10:40 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #6 from YunQiang Su <syq at debian dot org> ---
Index: gcc-12-12-20211211/src/libphobos/libdruntime/core/sys/posix/sys/stat.d
===================================================================
--- gcc-12-12-20211211.orig/src/libphobos/libdruntime/core/sys/posix/sys/stat.d
+++ gcc-12-12-20211211/src/libphobos/libdruntime/core/sys/posix/sys/stat.d
@@ -347,7 +347,7 @@ version (CRuntime_Glibc)
{
c_ulong st_dev;
int[3] st_pad1;
- static if (!__USE_FILE_OFFSET64)
+ static if (__WORDSIZE == 64 || !__USE_FILE_OFFSET64)
{
ino_t st_ino;
}
@@ -360,7 +360,7 @@ version (CRuntime_Glibc)
uid_t st_uid;
gid_t st_gid;
c_ulong st_rdev;
- static if (!__USE_FILE_OFFSET64)
+ static if (__WORDSIZE == 64 || !__USE_FILE_OFFSET64)
{
uint[2] st_pad2;
off_t st_size;
@@ -394,7 +394,7 @@ version (CRuntime_Glibc)
}
blksize_t st_blksize;
uint st_pad4;
- static if (!__USE_FILE_OFFSET64)
+ static if (__WORDSIZE == 64 || !__USE_FILE_OFFSET64)
{
blkcnt_t st_blocks;
}
This patch can solve this problem: of course, we need to back port it to
gcc-10/gcc-11 also.
The problem is due to that:
N32 and N64 uses different "struct stat"
In the older version, __USE_FILE_OFFSET64 may be not defined for N64
while now, it is defined.
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (6 preceding siblings ...)
2021-12-13 10:40 ` syq at debian dot org
@ 2021-12-13 10:42 ` syq at debian dot org
2021-12-13 10:44 ` ibuclaw at gcc dot gnu.org
` (18 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: syq at debian dot org @ 2021-12-13 10:42 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #7 from YunQiang Su <syq at debian dot org> ---
Where should we fallback this patch to?
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (7 preceding siblings ...)
2021-12-13 10:42 ` syq at debian dot org
@ 2021-12-13 10:44 ` ibuclaw at gcc dot gnu.org
2021-12-13 11:01 ` syq at debian dot org
` (17 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: ibuclaw at gcc dot gnu.org @ 2021-12-13 10:44 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
ibuclaw at gcc dot gnu.org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|WAITING |ASSIGNED
--- Comment #8 from ibuclaw at gcc dot gnu.org ---
(In reply to YunQiang Su from comment #7)
> Where should we fallback this patch to?
I can submit it to upstream dlang/druntime (on github) and merged it in when I
next do the sync later this week.
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (8 preceding siblings ...)
2021-12-13 10:44 ` ibuclaw at gcc dot gnu.org
@ 2021-12-13 11:01 ` syq at debian dot org
2021-12-13 16:25 ` ibuclaw at gdcproject dot org
` (16 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: syq at debian dot org @ 2021-12-13 11:01 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #9 from YunQiang Su <syq at debian dot org> ---
(In reply to ibuclaw from comment #8)
> (In reply to YunQiang Su from comment #7)
> > Where should we fallback this patch to?
> I can submit it to upstream dlang/druntime (on github) and merged it in when
> I next do the sync later this week.
Thank you so much.
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (9 preceding siblings ...)
2021-12-13 11:01 ` syq at debian dot org
@ 2021-12-13 16:25 ` ibuclaw at gdcproject dot org
2021-12-14 1:44 ` syq at debian dot org
` (15 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: ibuclaw at gdcproject dot org @ 2021-12-13 16:25 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #10 from Iain Buclaw <ibuclaw at gdcproject dot org> ---
(In reply to YunQiang Su from comment #6)
>
> This patch can solve this problem: of course, we need to back port it to
> gcc-10/gcc-11 also.
>
> The problem is due to that:
> N32 and N64 uses different "struct stat"
> In the older version, __USE_FILE_OFFSET64 may be not defined for N64
> while now, it is defined.
Is this patch backwards compatible though? Perhaps the value of
`__USE_FILE_OFFSET64` should instead be fixed to match that of the target.
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (10 preceding siblings ...)
2021-12-13 16:25 ` ibuclaw at gdcproject dot org
@ 2021-12-14 1:44 ` syq at debian dot org
2021-12-14 4:44 ` syq at debian dot org
` (14 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: syq at debian dot org @ 2021-12-14 1:44 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #11 from YunQiang Su <syq at debian dot org> ---
(In reply to Iain Buclaw from comment #10)
> (In reply to YunQiang Su from comment #6)
> >
> > This patch can solve this problem: of course, we need to back port it to
> > gcc-10/gcc-11 also.
> >
> > The problem is due to that:
> > N32 and N64 uses different "struct stat"
> > In the older version, __USE_FILE_OFFSET64 may be not defined for N64
> > while now, it is defined.
> Is this patch backwards compatible though? Perhaps the value of
> `__USE_FILE_OFFSET64` should instead be fixed to match that of the target.
ohhh. you are right. I misunderstand this problem.
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (11 preceding siblings ...)
2021-12-14 1:44 ` syq at debian dot org
@ 2021-12-14 4:44 ` syq at debian dot org
2021-12-14 4:50 ` syq at debian dot org
` (13 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: syq at debian dot org @ 2021-12-14 4:44 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #12 from YunQiang Su <syq at debian dot org> ---
(In reply to YunQiang Su from comment #11)
> (In reply to Iain Buclaw from comment #10)
> > (In reply to YunQiang Su from comment #6)
> > >
> > > This patch can solve this problem: of course, we need to back port it to
> > > gcc-10/gcc-11 also.
> > >
> > > The problem is due to that:
> > > N32 and N64 uses different "struct stat"
> > > In the older version, __USE_FILE_OFFSET64 may be not defined for N64
> > > while now, it is defined.
> > Is this patch backwards compatible though? Perhaps the value of
> > `__USE_FILE_OFFSET64` should instead be fixed to match that of the target.
>
> ohhh. you are right. I misunderstand this problem.
There are no previous version at all..., since all of them are broken.
And __USE_FILE_OFFSET64 for D is always defined (at least since it is introduce
into gcc).
So *stat64* function call should always be used, and stat.d has a wrong
version.
So the patch should be:
Index: gcc-12-12-20211211/src/libphobos/libdruntime/core/sys/posix/sys/stat.d
===================================================================
--- gcc-12-12-20211211.orig/src/libphobos/libdruntime/core/sys/posix/sys/stat.d
+++ gcc-12-12-20211211/src/libphobos/libdruntime/core/sys/posix/sys/stat.d
@@ -368,7 +368,7 @@ version (CRuntime_Glibc)
}
else
{
- c_long[3] st_pad2;
+ uint[3] st_pad2;
c_long st_size;
}
static if (__USE_MISC || __USE_XOPEN2K8)
@@ -402,7 +402,7 @@ version (CRuntime_Glibc)
{
c_long st_blocks;
}
- c_long[14] st_pad5;
+ uint[14] st_pad5;
}
}
else version (PPC)
This is the gdb ptype /o outputs:
type = struct core.sys.posix.sys.stat.stat_t {
ulong st_dev;
int st_pad1[3];
ulong st_ino;
uint st_mode;
ulong st_nlink;
uint st_uid;
uint st_gid;
ulong st_rdev;
long st_pad2[3];
long st_size;
long st_atime;
ulong st_atimensec;
long st_mtime;
ulong st_mtimensec;
long st_ctime;
ulong st_ctimensec;
long st_blksize;
uint st_pad4;
long st_blocks;
long st_pad5[14];
}
/* offset | size */ type = struct stat {
/* 0 | 8 */ __dev_t st_dev;
/* 8 | 12 */ int st_pad1[3];
/* XXX 4-byte hole */
/* 24 | 8 */ __ino64_t st_ino;
/* 32 | 4 */ __mode_t st_mode;
/* XXX 4-byte hole */
/* 40 | 8 */ __nlink_t st_nlink;
/* 48 | 4 */ __uid_t st_uid;
/* 52 | 4 */ __gid_t st_gid;
/* 56 | 8 */ __dev_t st_rdev;
/* 64 | 12 */ unsigned int st_pad2[3];
/* XXX 4-byte hole */
/* 80 | 8 */ __off64_t st_size;
/* 88 | 16 */ struct timespec {
/* 88 | 8 */ __time_t tv_sec;
/* 96 | 8 */ __syscall_slong_t tv_nsec;
/* total size (bytes): 16 */
} st_atim;
/* 104 | 16 */ struct timespec {
/* 104 | 8 */ __time_t tv_sec;
/* 112 | 8 */ __syscall_slong_t tv_nsec;
/* total size (bytes): 16 */
} st_mtim;
/* 120 | 16 */ struct timespec {
/* 120 | 8 */ __time_t tv_sec;
/* 128 | 8 */ __syscall_slong_t tv_nsec;
/* total size (bytes): 16 */
} st_ctim;
/* 136 | 8 */ __blksize_t st_blksize;
/* 144 | 4 */ unsigned int st_pad4;
/* XXX 4-byte hole */
/* 152 | 8 */ __blkcnt64_t st_blocks;
/* 160 | 56 */ int st_pad5[14];
/* total size (bytes): 216 */
}
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (12 preceding siblings ...)
2021-12-14 4:44 ` syq at debian dot org
@ 2021-12-14 4:50 ` syq at debian dot org
2021-12-14 15:02 ` ibuclaw at gdcproject dot org
` (12 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: syq at debian dot org @ 2021-12-14 4:50 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #13 from YunQiang Su <syq at debian dot org> ---
And please have a wait, I need to make sure that this patch can work with N32.
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (13 preceding siblings ...)
2021-12-14 4:50 ` syq at debian dot org
@ 2021-12-14 15:02 ` ibuclaw at gdcproject dot org
2021-12-14 15:06 ` ibuclaw at gdcproject dot org
` (11 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: ibuclaw at gdcproject dot org @ 2021-12-14 15:02 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #14 from Iain Buclaw <ibuclaw at gdcproject dot org> ---
(In reply to YunQiang Su from comment #13)
> And please have a wait, I need to make sure that this patch can work with
> N32.
So on gcc230, what I see is:
| C | D |
32 | 144 | 160 |
o64 | 160 | 148 |
n32 | 160 | 148 |
64 | 216 | 280 |
Totally wrong across the board.
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (14 preceding siblings ...)
2021-12-14 15:02 ` ibuclaw at gdcproject dot org
@ 2021-12-14 15:06 ` ibuclaw at gdcproject dot org
2021-12-14 15:10 ` ibuclaw at gdcproject dot org
` (10 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: ibuclaw at gdcproject dot org @ 2021-12-14 15:06 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #15 from Iain Buclaw <ibuclaw at gdcproject dot org> ---
Created attachment 51999
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=51999&action=edit
mips stat_t patch
Patch matches field declarations I can see in the headers, and it for sure
reigns it in.
| C | D |
32 | 144 | 160 |
o64 | 160 | 176 |
n32 | 160 | 176 |
64 | 216 | 216 |
Don't think it would fail now the statically allocated size is *at least* same
as C. But some alias is still not matching up.
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (15 preceding siblings ...)
2021-12-14 15:06 ` ibuclaw at gdcproject dot org
@ 2021-12-14 15:10 ` ibuclaw at gdcproject dot org
2021-12-14 15:28 ` syq at debian dot org
` (9 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: ibuclaw at gdcproject dot org @ 2021-12-14 15:10 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #16 from Iain Buclaw <ibuclaw at gdcproject dot org> ---
(In reply to Iain Buclaw from comment #15)
> Don't think it would fail now the statically allocated size is *at least*
> same as C. But some alias is still not matching up.
core.sys.posix.sys.types is implicitly assuming X86 sizes.
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (16 preceding siblings ...)
2021-12-14 15:10 ` ibuclaw at gdcproject dot org
@ 2021-12-14 15:28 ` syq at debian dot org
2021-12-14 15:58 ` ibuclaw at gdcproject dot org
` (8 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: syq at debian dot org @ 2021-12-14 15:28 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #17 from YunQiang Su <syq at debian dot org> ---
(In reply to Iain Buclaw from comment #16)
> (In reply to Iain Buclaw from comment #15)
> > Don't think it would fail now the statically allocated size is *at least*
> > same as C. But some alias is still not matching up.
> core.sys.posix.sys.types is implicitly assuming X86 sizes.
(In reply to YunQiang Su from comment #13)
> And please have a wait, I need to make sure that this patch can work with
> N32.
Finally, with help of gdb, This patch can work with both N64 and N32.
--- /usr/lib/gcc/mips64el-linux-gnuabi64/11/include/d/core/sys/posix/sys/stat.d
2021-11-18 20:24:46.000000000 +0000
+++ stat.d 2021-12-14 15:22:21.929556158 +0000
@@ -345,7 +345,7 @@
{
struct stat_t
{
- c_ulong st_dev;
+ ulong st_dev;
int[3] st_pad1;
static if (!__USE_FILE_OFFSET64)
{
@@ -353,13 +353,13 @@
}
else
{
- c_ulong st_ino;
+ ulong st_ino;
}
mode_t st_mode;
nlink_t st_nlink;
uid_t st_uid;
gid_t st_gid;
- c_ulong st_rdev;
+ ulong st_rdev;
static if (!__USE_FILE_OFFSET64)
{
uint[2] st_pad2;
@@ -368,8 +368,8 @@
}
else
{
- c_long[3] st_pad2;
- c_long st_size;
+ uint[3] st_pad2;
+ long st_size;
}
static if (__USE_MISC || __USE_XOPEN2K8)
{
@@ -400,9 +400,9 @@
}
else
{
- c_long st_blocks;
+ long st_blocks;
}
- c_long[14] st_pad5;
+ uint[14] st_pad5;
}
}
else version (PPC)
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (17 preceding siblings ...)
2021-12-14 15:28 ` syq at debian dot org
@ 2021-12-14 15:58 ` ibuclaw at gdcproject dot org
2021-12-14 16:01 ` syq at debian dot org
` (7 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: ibuclaw at gdcproject dot org @ 2021-12-14 15:58 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #18 from Iain Buclaw <ibuclaw at gdcproject dot org> ---
(In reply to Iain Buclaw from comment #16)
> (In reply to Iain Buclaw from comment #15)
> > Don't think it would fail now the statically allocated size is *at least*
> > same as C. But some alias is still not matching up.
> core.sys.posix.sys.types is implicitly assuming X86 sizes.
(In reply to Iain Buclaw from comment #15)
> Created attachment 51999 [details]
> mips stat_t patch
>
> Patch matches field declarations I can see in the headers, and it for sure
> reigns it in.
>
> | C | D |
> 32 | 144 | 160 |
> o64 | 160 | 176 |
> n32 | 160 | 176 |
> 64 | 216 | 216 |
>
> Don't think it would fail now the statically allocated size is *at least*
> same as C. But some alias is still not matching up.
Ah, no, this is right, I just didn't build the C source with
-D_FILE_OFFSET_BITS=64
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (18 preceding siblings ...)
2021-12-14 15:58 ` ibuclaw at gdcproject dot org
@ 2021-12-14 16:01 ` syq at debian dot org
2021-12-14 16:18 ` ibuclaw at gdcproject dot org
` (6 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: syq at debian dot org @ 2021-12-14 16:01 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #19 from YunQiang Su <syq at debian dot org> ---
(In reply to Iain Buclaw from comment #18)
> (In reply to Iain Buclaw from comment #16)
> > (In reply to Iain Buclaw from comment #15)
> > > Don't think it would fail now the statically allocated size is *at least*
> > > same as C. But some alias is still not matching up.
> > core.sys.posix.sys.types is implicitly assuming X86 sizes.
>
> (In reply to Iain Buclaw from comment #15)
> > Created attachment 51999 [details]
> > mips stat_t patch
> >
> > Patch matches field declarations I can see in the headers, and it for sure
> > reigns it in.
> >
> > | C | D |
> > 32 | 144 | 160 |
> > o64 | 160 | 176 |
> > n32 | 160 | 176 |
> > 64 | 216 | 216 |
> >
> > Don't think it would fail now the statically allocated size is *at least*
> > same as C. But some alias is still not matching up.
> Ah, no, this is right, I just didn't build the C source with
> -D_FILE_OFFSET_BITS=64
FYI: I find that gcc/glibc (for C) generates wrong code for O32 with
-D_FILE_OFFSET_BITS=64.
I am digging it.
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (19 preceding siblings ...)
2021-12-14 16:01 ` syq at debian dot org
@ 2021-12-14 16:18 ` ibuclaw at gdcproject dot org
2021-12-15 19:01 ` cvs-commit at gcc dot gnu.org
` (5 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: ibuclaw at gdcproject dot org @ 2021-12-14 16:18 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #20 from Iain Buclaw <ibuclaw at gdcproject dot org> ---
(In reply to YunQiang Su from comment #17)
> (In reply to Iain Buclaw from comment #16)
> > (In reply to Iain Buclaw from comment #15)
> > > Don't think it would fail now the statically allocated size is *at least*
> > > same as C. But some alias is still not matching up.
> > core.sys.posix.sys.types is implicitly assuming X86 sizes.
>
> (In reply to YunQiang Su from comment #13)
> > And please have a wait, I need to make sure that this patch can work with
> > N32.
>
> Finally, with help of gdb, This patch can work with both N64 and N32.
Thanks, I've gone with a variant of what I submitted here. Added a few static
asserts to ensure that the size matches what I've observed.
https://github.com/dlang/druntime/pull/3649
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (20 preceding siblings ...)
2021-12-14 16:18 ` ibuclaw at gdcproject dot org
@ 2021-12-15 19:01 ` cvs-commit at gcc dot gnu.org
2021-12-21 13:16 ` cvs-commit at gcc dot gnu.org
` (4 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2021-12-15 19:01 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #21 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Iain Buclaw <ibuclaw@gcc.gnu.org>:
https://gcc.gnu.org/g:fd43568cc54e17c8b4a845677872c6282bc6dbb7
commit r12-6003-gfd43568cc54e17c8b4a845677872c6282bc6dbb7
Author: Iain Buclaw <ibuclaw@gdcproject.org>
Date: Wed Dec 15 19:47:02 2021 +0100
d: Merge upstream dmd 93108bb9e, druntime 6364e010, phobos 575b67a9b.
D front-end changes:
- Import dmd v2.098.1-beta.1.
- Default extern(C++) compatibility to C++17.
Druntime changes:
- Import druntime v2.098.1-beta.1.
- Fix definition of stat_t on MIPS64 (PR103604)
Phobos changes:
- Import phobos v2.098.1-beta.1.
gcc/d/ChangeLog:
* d-lang.cc (d_init_options): Set default -fextern-std= to C++17.
* dmd/MERGE: Merge upstream dmd 93108bb9e.
* gdc.texi (Runtime Options): Document the default for
-fextern-std=.
libphobos/ChangeLog:
PR d/103604
* configure: Regenerate.
* configure.ac (libtool_VERSION): Update to 3:0:0.
* libdruntime/MERGE: Merge upstream druntime 6364e010.
* src/MERGE: Merge upstream phobos 575b67a9b.
* testsuite/libphobos.traits/all_satisfy.d: New test.
* testsuite/libphobos.traits/traits.exp: New test.
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (21 preceding siblings ...)
2021-12-15 19:01 ` cvs-commit at gcc dot gnu.org
@ 2021-12-21 13:16 ` cvs-commit at gcc dot gnu.org
2021-12-21 13:17 ` cvs-commit at gcc dot gnu.org
` (3 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2021-12-21 13:16 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #22 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-11 branch has been updated by Iain Buclaw
<ibuclaw@gcc.gnu.org>:
https://gcc.gnu.org/g:96a09dec2421af3e201f5a54dadb35f00917ea5b
commit r11-9408-g96a09dec2421af3e201f5a54dadb35f00917ea5b
Author: Iain Buclaw <ibuclaw@gdcproject.org>
Date: Tue Dec 21 14:07:37 2021 +0100
libphobos: Fix definition of stat_t for MIPS64 (PR103604)
Backported specific change from commit r12-6003.
libphobos/ChangeLog:
PR d/103604
* libdruntime/core/sys/posix/sys/stat.d (struct stat_t): Fix
definition for MIPS64.
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (22 preceding siblings ...)
2021-12-21 13:16 ` cvs-commit at gcc dot gnu.org
@ 2021-12-21 13:17 ` cvs-commit at gcc dot gnu.org
2021-12-21 13:17 ` cvs-commit at gcc dot gnu.org
` (2 subsequent siblings)
26 siblings, 0 replies; 28+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2021-12-21 13:17 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #23 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-10 branch has been updated by Iain Buclaw
<ibuclaw@gcc.gnu.org>:
https://gcc.gnu.org/g:ecd9684ec16ec0de2e4c0bb3f2097f98e6686cbe
commit r10-10354-gecd9684ec16ec0de2e4c0bb3f2097f98e6686cbe
Author: Iain Buclaw <ibuclaw@gdcproject.org>
Date: Tue Dec 21 14:07:37 2021 +0100
libphobos: Fix definition of stat_t for MIPS64 (PR103604)
Backported specific change from commit r12-6003.
libphobos/ChangeLog:
PR d/103604
* libdruntime/core/sys/posix/sys/stat.d (struct stat_t): Fix
definition for MIPS64.
(cherry picked from commit 96a09dec2421af3e201f5a54dadb35f00917ea5b)
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (23 preceding siblings ...)
2021-12-21 13:17 ` cvs-commit at gcc dot gnu.org
@ 2021-12-21 13:17 ` cvs-commit at gcc dot gnu.org
2021-12-21 13:19 ` ibuclaw at gdcproject dot org
2021-12-22 3:03 ` syq at debian dot org
26 siblings, 0 replies; 28+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2021-12-21 13:17 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #24 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-9 branch has been updated by Iain Buclaw
<ibuclaw@gcc.gnu.org>:
https://gcc.gnu.org/g:38d8dec9c9d6a735759ddebe6d90a50719a7f94c
commit r9-9881-g38d8dec9c9d6a735759ddebe6d90a50719a7f94c
Author: Iain Buclaw <ibuclaw@gdcproject.org>
Date: Tue Dec 21 14:07:37 2021 +0100
libphobos: Fix definition of stat_t for MIPS64 (PR103604)
Backported specific change from commit r12-6003.
libphobos/ChangeLog:
PR d/103604
* libdruntime/core/sys/posix/sys/stat.d (struct stat_t): Fix
definition for MIPS64.
(cherry picked from commit 96a09dec2421af3e201f5a54dadb35f00917ea5b)
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (24 preceding siblings ...)
2021-12-21 13:17 ` cvs-commit at gcc dot gnu.org
@ 2021-12-21 13:19 ` ibuclaw at gdcproject dot org
2021-12-22 3:03 ` syq at debian dot org
26 siblings, 0 replies; 28+ messages in thread
From: ibuclaw at gdcproject dot org @ 2021-12-21 13:19 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
Iain Buclaw <ibuclaw at gdcproject dot org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|--- |FIXED
Status|ASSIGNED |RESOLVED
--- Comment #25 from Iain Buclaw <ibuclaw at gdcproject dot org> ---
Fixed layout has been pushed out, should be all good now.
^ permalink raw reply [flat|nested] 28+ messages in thread
* [Bug d/103604] [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
` (25 preceding siblings ...)
2021-12-21 13:19 ` ibuclaw at gdcproject dot org
@ 2021-12-22 3:03 ` syq at debian dot org
26 siblings, 0 replies; 28+ messages in thread
From: syq at debian dot org @ 2021-12-22 3:03 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103604
--- Comment #26 from YunQiang Su <syq at debian dot org> ---
(In reply to Iain Buclaw from comment #25)
> Fixed layout has been pushed out, should be all good now.
(In reply to YunQiang Su from comment #19)
> (In reply to Iain Buclaw from comment #18)
> > (In reply to Iain Buclaw from comment #16)
> > > (In reply to Iain Buclaw from comment #15)
> > > > Don't think it would fail now the statically allocated size is *at least*
> > > > same as C. But some alias is still not matching up.
> > > core.sys.posix.sys.types is implicitly assuming X86 sizes.
> >
> > (In reply to Iain Buclaw from comment #15)
> > > Created attachment 51999 [details]
> > > mips stat_t patch
> > >
> > > Patch matches field declarations I can see in the headers, and it for sure
> > > reigns it in.
> > >
> > > | C | D |
> > > 32 | 144 | 160 |
> > > o64 | 160 | 176 |
> > > n32 | 160 | 176 |
> > > 64 | 216 | 216 |
> > >
> > > Don't think it would fail now the statically allocated size is *at least*
> > > same as C. But some alias is still not matching up.
> > Ah, no, this is right, I just didn't build the C source with
> > -D_FILE_OFFSET_BITS=64
>
> FYI: I find that gcc/glibc (for C) generates wrong code for O32 with
> -D_FILE_OFFSET_BITS=64.
>
> I am digging it.
mipsel has no problem: I should use %lld to print the st_size.
^ permalink raw reply [flat|nested] 28+ messages in thread
end of thread, other threads:[~2021-12-22 3:03 UTC | newest]
Thread overview: 28+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-07 13:23 [Bug d/103604] New: [12 Regression] trunk 20210506 fails to build in libphobos on mips64el-linux-gnu doko at debian dot org
2021-12-07 13:31 ` [Bug d/103604] " rguenth at gcc dot gnu.org
2021-12-07 13:41 ` marxin at gcc dot gnu.org
2021-12-13 1:56 ` syq at debian dot org
2021-12-13 7:56 ` syq at debian dot org
2021-12-13 8:02 ` syq at debian dot org
2021-12-13 8:16 ` ibuclaw at gcc dot gnu.org
2021-12-13 10:40 ` syq at debian dot org
2021-12-13 10:42 ` syq at debian dot org
2021-12-13 10:44 ` ibuclaw at gcc dot gnu.org
2021-12-13 11:01 ` syq at debian dot org
2021-12-13 16:25 ` ibuclaw at gdcproject dot org
2021-12-14 1:44 ` syq at debian dot org
2021-12-14 4:44 ` syq at debian dot org
2021-12-14 4:50 ` syq at debian dot org
2021-12-14 15:02 ` ibuclaw at gdcproject dot org
2021-12-14 15:06 ` ibuclaw at gdcproject dot org
2021-12-14 15:10 ` ibuclaw at gdcproject dot org
2021-12-14 15:28 ` syq at debian dot org
2021-12-14 15:58 ` ibuclaw at gdcproject dot org
2021-12-14 16:01 ` syq at debian dot org
2021-12-14 16:18 ` ibuclaw at gdcproject dot org
2021-12-15 19:01 ` cvs-commit at gcc dot gnu.org
2021-12-21 13:16 ` cvs-commit at gcc dot gnu.org
2021-12-21 13:17 ` cvs-commit at gcc dot gnu.org
2021-12-21 13:17 ` cvs-commit at gcc dot gnu.org
2021-12-21 13:19 ` ibuclaw at gdcproject dot org
2021-12-22 3:03 ` syq at debian dot org
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).