On Tue, Oct 22, 2024 at 08:48:10PM GMT, Alejandro Colomar wrote: > Hi Joseph, > > I found some tests that could be improved, so I've worked on that in the > last few days. I'll post as a reply to this email the bootstrap and > regression testing results.
alx@debian:~/src/gnu/gcc/len$ git tag len17 alx@debian:~/src/gnu/gcc/len$ git log --oneline gnu/master^..len17 936f7945fae (HEAD -> len, tag: len17) c: Add __countof__ operator d847dc4a795 contrib/: Add support for Cc: and Link: tags 01f50ebfd97 (gnu/trunk, gnu/master) Revert "[PATCH 7/7] RISC-V: Disable by pieces for ve> alx@debian:~/src/gnu/gcc/len$ git reset gnu/master --h HEAD is now at 01f50ebfd97 Revert "[PATCH 7/7] RISC-V: Disable by pieces for vector setmem length > UNITS_PER_WORD" alx@debian:~/src/gnu/gcc/len$ mkdir ../len17 alx@debian:~/src/gnu/gcc/len$ cd ../len17 alx@debian:~/src/gnu/gcc/len17$ /bin/time ../len/configure --disable-multilib --prefix=/opt/local/gnu/gcc/countof |& ts -s | ovr -n 3; echo $? 00:00:04 config.status: creating Makefile 00:00:04 2.86user 1.75system 0:04.17elapsed 110%CPU (0avgtext+0avgdata 26344maxresident)k 00:00:04 97984inputs+8000outputs (305major+280624minor)pagefaults 0swaps 0 alx@debian:~/src/gnu/gcc/len17$ /bin/time make -j24 bootstrap |& ts -s | ovr -n 3; echo $? 00:21:23 make[1]: Leaving directory '/home/alx/src/gnu/gcc/len17' 00:21:23 15132.07user 432.94system 21:23.16elapsed 1213%CPU (0avgtext+0avgdata 1571468maxresident)k 00:21:23 1548192inputs+30472720outputs (19209major+118824055minor)pagefaults 0swaps 0 alx@debian:~/src/gnu/gcc/len17$ /bin/time make check |& ts -s | ovr -n 3; echo $? 06:52:09 make[1]: Leaving directory '/home/alx/src/gnu/gcc/len17' 06:52:09 21407.35user 3424.85system 6:52:09elapsed 100%CPU (0avgtext+0avgdata 2326956maxresident)k 06:52:09 731976inputs+21637088outputs (2855major+994117616minor)pagefaults 0swaps 0 alx@debian:~/src/gnu/gcc/len17$ cd ../len alx@debian:~/src/gnu/gcc/len$ git merge --ff-only len17 Updating 01f50ebfd97..936f7945fae Fast-forward contrib/gcc-changelog/git_commit.py | 5 +- gcc/c-family/c-common.cc | 26 ++++++++ gcc/c-family/c-common.def | 3 + gcc/c-family/c-common.h | 2 + gcc/c/c-decl.cc | 22 +++++-- gcc/c/c-parser.cc | 62 +++++++++++++---- gcc/c/c-tree.h | 4 ++ gcc/c/c-typeck.cc | 118 +++++++++++++++++++++++++++++++-- gcc/doc/extend.texi | 30 +++++++++ gcc/testsuite/gcc.dg/countof-compile.c | 127 +++++++++++++++++++++++++++++++++++ gcc/testsuite/gcc.dg/countof-vla.c | 46 +++++++++++++ gcc/testsuite/gcc.dg/countof.c | 150 ++++++++++++++++++++++++++++++++++++++++++ 12 files changed, 570 insertions(+), 25 deletions(-) create mode 100644 gcc/testsuite/gcc.dg/countof-compile.c create mode 100644 gcc/testsuite/gcc.dg/countof-vla.c create mode 100644 gcc/testsuite/gcc.dg/countof.c alx@debian:~/src/gnu/gcc/len17$ cd .. alx@debian:~/src/gnu/gcc$ mv len17/ len17_b4 alx@debian:~/src/gnu/gcc/len$ mkdir len17 alx@debian:~/src/gnu/gcc/len$ cd len17 alx@debian:~/src/gnu/gcc/len17$ /bin/time ../len/configure --disable-multilib --prefix=/opt/local/gnu/gcc/countof |& ts -s | ovr; echo $? 00:00:03 232inputs+8000outputs (1major+278059minor)pagefaults 0swaps 0 alx@debian:~/src/gnu/gcc/len17$ /bin/time make -j24 bootstrap |& ts -s | ovr; echo $? 00:20:39 40992inputs+30487656outputs (561major+125063297minor)pagefaults 0swaps 0 alx@debian:~/src/gnu/gcc/len17$ /bin/time make check |& ts -s | ovr; echo $? 06:56:00 74496inputs+21640408outputs (2723major+991618593minor)pagefaults 0swaps 0 alx@debian:~/src/gnu/gcc/len17$ find -type f | grep '\.sum$' | while read f; do diff -u ../len17_b4/$f $f; done --- ../len17_b4/./gcc/testsuite/gcc/gcc.sum 2024-10-20 21:28:04.131516030 +0200 +++ ./gcc/testsuite/gcc/gcc.sum 2024-10-22 13:06:18.877529401 +0200 @@ -1,4 +1,4 @@ -Test run by alx on Sun Oct 20 19:42:24 2024 +Test run by alx on Tue Oct 22 11:17:17 2024 Native configuration is x86_64-pc-linux-gnu === gcc tests === @@ -78022,6 +78022,30 @@ PASS: gcc.dg/conv-2.c (test for excess errors) PASS: gcc.dg/conv-3.c (test for excess errors) PASS: gcc.dg/conv-3.c execution test +PASS: gcc.dg/countof-compile.c (test for errors, line 24) +PASS: gcc.dg/countof-compile.c (test for errors, line 28) +PASS: gcc.dg/countof-compile.c (test for errors, line 39) +PASS: gcc.dg/countof-compile.c (test for errors, line 47) +PASS: gcc.dg/countof-compile.c (test for errors, line 62) +PASS: gcc.dg/countof-compile.c (test for errors, line 65) +PASS: gcc.dg/countof-compile.c (test for errors, line 68) +PASS: gcc.dg/countof-compile.c (test for errors, line 80) +PASS: gcc.dg/countof-compile.c (test for errors, line 81) +PASS: gcc.dg/countof-compile.c (test for errors, line 82) +PASS: gcc.dg/countof-compile.c (test for errors, line 83) +PASS: gcc.dg/countof-compile.c (test for errors, line 84) +PASS: gcc.dg/countof-compile.c (test for errors, line 85) +PASS: gcc.dg/countof-compile.c (test for errors, line 86) +PASS: gcc.dg/countof-compile.c (test for errors, line 87) +PASS: gcc.dg/countof-compile.c (test for errors, line 88) +PASS: gcc.dg/countof-compile.c (test for warnings, line 92) +PASS: gcc.dg/countof-compile.c (test for errors, line 112) +PASS: gcc.dg/countof-compile.c (test for errors, line 121) +PASS: gcc.dg/countof-compile.c (test for errors, line 126) +PASS: gcc.dg/countof-compile.c (test for excess errors) +PASS: gcc.dg/countof-vla.c (test for excess errors) +PASS: gcc.dg/countof.c (test for excess errors) +PASS: gcc.dg/countof.c execution test PASS: gcc.dg/cr-decimal-dig-1.c (test for excess errors) PASS: gcc.dg/cr-decimal-dig-2.c (test for excess errors) PASS: gcc.dg/cr-decimal-dig-3.c (test for excess errors) @@ -208690,7 +208714,7 @@ === gcc Summary === -# of expected passes 203598 +# of expected passes 203622 # of unexpected failures 37 # of unexpected successes 2 # of expected failures 1471 --- ../len17_b4/./gcc/testsuite/gfortran/gfortran.sum 2024-10-20 23:07:39.361276662 +0200 +++ ./gcc/testsuite/gfortran/gfortran.sum 2024-10-22 14:45:01.978602257 +0200 @@ -1,4 +1,4 @@ -Test run by alx on Sun Oct 20 22:32:36 2024 +Test run by alx on Tue Oct 22 14:10:06 2024 Native configuration is x86_64-pc-linux-gnu === gfortran tests === --- ../len17_b4/./gcc/testsuite/objc/objc.sum 2024-10-20 23:08:46.517872353 +0200 +++ ./gcc/testsuite/objc/objc.sum 2024-10-22 14:46:08.167200761 +0200 @@ -1,4 +1,4 @@ -Test run by alx on Sun Oct 20 23:07:39 2024 +Test run by alx on Tue Oct 22 14:45:02 2024 Native configuration is x86_64-pc-linux-gnu === objc tests === --- ../len17_b4/./gcc/testsuite/g++/g++.sum 2024-10-20 22:32:35.602258071 +0200 +++ ./gcc/testsuite/g++/g++.sum 2024-10-22 14:10:05.487527382 +0200 @@ -1,4 +1,4 @@ -Test run by alx on Sun Oct 20 21:28:04 2024 +Test run by alx on Tue Oct 22 13:06:19 2024 Native configuration is x86_64-pc-linux-gnu === g++ tests === --- ../len17_b4/./x86_64-pc-linux-gnu/libitm/testsuite/libitm.sum 2024-10-21 02:34:25.906785565 +0200 +++ ./x86_64-pc-linux-gnu/libitm/testsuite/libitm.sum 2024-10-22 18:13:10.216200995 +0200 @@ -1,4 +1,4 @@ -Test run by alx on Mon Oct 21 02:34:23 2024 +Test run by alx on Tue Oct 22 18:13:08 2024 Native configuration is x86_64-pc-linux-gnu === libitm tests === --- ../len17_b4/./x86_64-pc-linux-gnu/libgomp/testsuite/libgomp.sum 2024-10-21 02:34:23.258761608 +0200 +++ ./x86_64-pc-linux-gnu/libgomp/testsuite/libgomp.sum 2024-10-22 18:13:07.608178686 +0200 @@ -1,4 +1,4 @@ -Test run by alx on Mon Oct 21 02:20:07 2024 +Test run by alx on Tue Oct 22 17:58:52 2024 Native configuration is x86_64-pc-linux-gnu === libgomp tests === --- ../len17_b4/./x86_64-pc-linux-gnu/libatomic/testsuite/libatomic.sum2024-10-21 02:34:28.354807711 +0200 +++ ./x86_64-pc-linux-gnu/libatomic/testsuite/libatomic.sum 2024-10-22 18:13:12.560221047 +0200 @@ -1,4 +1,4 @@ -Test run by alx on Mon Oct 21 02:34:26 2024 +Test run by alx on Tue Oct 22 18:13:10 2024 Native configuration is x86_64-pc-linux-gnu === libatomic tests === --- ../len17_b4/./x86_64-pc-linux-gnu/libstdc++-v3/testsuite/libstdc++.sum 2024-10-21 02:19:44.922761161 +0200 +++ ./x86_64-pc-linux-gnu/libstdc++-v3/testsuite/libstdc++.sum 2024-10-22 17:58:29.992819146 +0200 @@ -1,4 +1,4 @@ -Test run by alx on Sun Oct 20 23:09:16 2024 +Test run by alx on Tue Oct 22 14:46:37 2024 Native configuration is x86_64-pc-linux-gnu === libstdc++ tests === > > > v17 changes: > > - Rebase (patches 2/4 and 3/4 from v16b have been merged already). > - Improve and add tests. > > Below is the range diff against v16b. > > > Have a lovely night! > Alex > > Alejandro Colomar (2): > contrib/: Add support for Cc: and Link: tags > c: Add __countof__ operator > > contrib/gcc-changelog/git_commit.py | 5 +- > gcc/c-family/c-common.cc | 26 +++++ > gcc/c-family/c-common.def | 3 + > gcc/c-family/c-common.h | 2 + > gcc/c/c-decl.cc | 22 +++- > gcc/c/c-parser.cc | 62 +++++++--- > gcc/c/c-tree.h | 4 + > gcc/c/c-typeck.cc | 118 ++++++++++++++++++- > gcc/doc/extend.texi | 30 +++++ > gcc/testsuite/gcc.dg/countof-compile.c | 127 +++++++++++++++++++++ > gcc/testsuite/gcc.dg/countof-vla.c | 46 ++++++++ > gcc/testsuite/gcc.dg/countof.c | 150 +++++++++++++++++++++++++ > 12 files changed, 570 insertions(+), 25 deletions(-) > create mode 100644 gcc/testsuite/gcc.dg/countof-compile.c > create mode 100644 gcc/testsuite/gcc.dg/countof-vla.c > create mode 100644 gcc/testsuite/gcc.dg/countof.c > > Range-diff against v16b: > 1: eac2d18d8a0 = 1: d847dc4a795 contrib/: Add support for Cc: and Link: tags > 2: 7418a11fcd6 < -: ----------- gcc/: Rename array_type_nelts => > array_type_nelts_minus_one > 3: 0cfae0598b3 < -: ----------- gcc/: Merge definitions of > array_type_nelts_top > 4: 12a30a2a6fd ! 2: 936f7945fae c: Add __countof__ operator > @@ gcc/testsuite/gcc.dg/countof-compile.c (new) > +static int y[__countof__(z)]; > + > +void > -+automatic(void) > ++completed (void) > +{ > -+ __countof__ (w); > ++ int i = 42; > ++ int a[] = {1, 2, i}; > ++ > ++ _Static_assert(__countof__ (w) == 3); > ++ __countof__ (a); > +} > + > +void > @@ gcc/testsuite/gcc.dg/countof-compile.c (new) > +{ > + __countof__ (x); /* { dg-error "incomplete" } */ > + > -+ /* We want to support the following one in the future, > -+ but for now it should fail. */ > ++ /* We want to support array parameters in the future, > ++ which should change this from "invalid" to "incomplete". */ > + __countof__ (p); /* { dg-error "invalid" } */ > +} > + > @@ gcc/testsuite/gcc.dg/countof-compile.c (new) > + __countof__ (s.fam); /* { dg-error "incomplete" } */ > +} > + > ++void > ++param (int n, int p[n]) > ++{ > ++ /* We want to support array parameters in the future, > ++ which would make this work. */ > ++ __countof__ (p); /* { dg-error "invalid" } */ > ++} > ++ > +void fix_fix (int i, char (*a)[3][5], int (*x)[__countof__ (*a)]); > +void fix_var (int i, char (*a)[3][i], int (*x)[__countof__ (*a)]); > +void fix_uns (int i, char (*a)[3][*], int (*x)[__countof__ (*a)]); > > -- > 2.45.2 > -- <https://www.alejandro-colomar.es/>
signature.asc
Description: PGP signature