xref: /netbsd-src/external/gpl3/gcc/README.gcc12 (revision 3f351f34c6d827cf017cdcff3543f6ec0c88b420)
1$NetBSD: README.gcc12,v 1.20 2023/10/22 00:09:20 mrg Exp $
2
3
4new stuff:
5	libmpx
6	liboffloadmic
7	libvtv
8	libcet
9	libphobos
10	d
11	gfortran
12	libbacktrace: +dwarf5_CFLAGS = $(libbacktrace_TEST_CFLAGS) -gdwarf-5
13	c++tools
14
15todo:
16	- audit all uses of new warning-disable variables and
17	  convert some from -Wno- to -Wno-error=
18
19arch/feature list.
20
21tools:		does build.sh tools work?
22kernels:	does a kernel run?  y (yes), b (builds/ready), p (partially), ? (not ready)
23libgcc:		does libgcc build?
24native-gcc:	does a full mknative-gcc complete?
25sani:		has sanitizer been ported to this CPU again for GCC 12?  b (build) y (works)
26make release:	does build.sh release complete?  (before sanitizer - bs)
27runs:		does the system boot with a full world?
28atf:		does atf run / compare well
29switched:	has port switched?  y (yes), n (no/ready), ? (not ready)
30
31
32architecture	tools	kernels	libgcc	native-gcc/sani	make release	runs	atf	switched
33------------	-----	-------	------	---------------	------------	----	---	--------
34aarch64		y	y	y	y	y[17]	y		y	y	?
35aarch64eb	y	y	y	y	y[17]	y		y	y	?
36alpha		y	y	y	y	b	y		y	y	?
37earmv4		y	b	?	y	?	?		?	?	?
38earmv4eb	y	b	?	y	?	?		?	?	?
39earmv5		y	y	y	y	b	y		y	y	?
40earmv5eb	y	y	y	y	b	y		y	y	?
41earmv5hf	y	b	?	y	?	?		?	?	?
42earmv5hfeb	y	b	?	y	?	?		?	?	?
43earmv6		y	b	?	y	?	?		?	?	?
44earmv6eb	y	b	?	y	?	?		?	?	?
45earmv6hf	y	y	y	y	b	y		y	y	?
46earmv6hfeb	y	y	y	y	b	y		y	y	?
47earmv7		y	b	y	y	?	?		?	?	?
48earmv7eb	y	b	?	y	?	?		?	?	?
49earmv7hf	y	y	y	y	b	y		y	y	?
50earmv7hfeb	y	y	y	y	b	y		y	y	?
51hppa		y	y	y	y	?	y		?	?	?
52i386		y	y	y	y	n[18]	y		y	n[19]	?
53ia64		y	b	y	y	y	y		y[3]	n	?
54m68000		y	y	y	y	n[11]	n		y[14]	?	?
55m68k		y	y	y	y	b	y		y[14]	y[14]	?
56mipseb		y	b	y	y	b	y		?	?	?
57mipsel		y	b	y	y	b	y		?	?	?
58mips64eb	y	b	y	y	b	y		?	?	?
59mips64el	y	b	y	y	b	y		?	?	?
60powerpc		y	y	y	y	?	n[4]		?	?	?
61powerpc64	y	?	?	y	?	?		?	?	?
62sh3eb		y	?	y	y	b	y		?	?	?
63sh3el		y	n[20]	y	y	b	y		n[22]	?	?
64sparc		y	y	y	y	n[21]	y		y	y	?
65sparc64		y	b	y	y	n[16]	y		y	?	?
66vax		y	y	y	y	n[23]	n		n[24,25] ?	?
67x86_64		y	y	y	y	y[13]	y		y	y	?
68riscv32		y	y	y	y	b	y		n[2]	?	?
69riscv64		y	y	y	y	b	y		y	y	?
70------------	-----	-------	------	---------------	------------	----	---
71architecture	tools	kernels	libgcc	native-gcc/sani	make release	runs	atf
72
73[2]: riscv32 kernels are not really implemented yet, not GCC 12 issue.
74[3]: GENERIC.SKI boots just as well as GCC 10.
75[4]: rs6000 has a new generator for rs6000-builtins.cc and rs6000-builtins.h rs6000-vecdefines.h
76[7]: fails to build kernels:
77     In file included from sys/arch/powerpc/oea/pmap64.c:4:
78     sys/arch/powerpc/oea/pmap.c:2186:2: error: #error PPC_OEA64 not supported
79[11]: sanitizers don't build yet.
80[13]: on amd64, with very basic test, lsan, ubsan, and asan work, but tsan crashes at start up:
81      ThreadSanitizer: CHECK failed: tsan_rtl.cpp:149 "((reinterpret_cast<uptr>(this) % 64)) == ((0))" (0x10, 0x0) (tid=21499)
82      ThreadSanitizer:DEADLYSIGNAL
83      ==21499==ERROR: ThreadSanitizer: SEGV on unknown address 0x000000000017 (pc 0x7f7ff4e5e14e bp 0x7f7fffffdbd0 sp 0x7f7fffffdb40 T21499)
84      ==21499==The signal is caused by a READ memory access.
85      ==21499==Hint: address points to the zero page.
86      ThreadSanitizer:DEADLYSIGNAL
87      ThreadSanitizer: nested bug in the same thread, aborting.
88[14]: "dd count=1", "env LC_CTYPE=en_US.UTF-8 locale", and "tests/crypto/libcrypto/h_evp_test evpmd_blake.txt" abort.
89      adding -fno-stack-protector to strsuftoll.c, citrus_module.c, and blake2_prov.c, respectively, works around the problem.
90[16]: sanitizers crash early:
91      Program received signal SIGSEGV, Segmentation fault.
92      (gdb) bt
93      #0  0x000000004064265c in __sanitizer::CheckASLR () at /usr/src/external/gpl3/gcc/dist/libsanitizer/sanitizer_common/sanitizer_linux.cpp:2181
94      #1  0xffffffffffffc704 in ?? ()
95      Backtrace stopped: previous frame identical to this frame (corrupt stack?)
96[17]: (NOT A REGRESSION) libtsan is newly introduced, which fails with:
97      FATAL: ThreadSanitizer: unexpected memory mapping 0x200100000-0x200101000
98[18]: *san requires 64-bit atomic ops:
99      ld: /usr/lib/libasan.so: undefined reference to `__sync_val_compare_and_swap_8'
100      If lib*san is compiled with -march=i586, all tests in usr.bin/{cc,c++} successfully pass.
101[19]: kernel freezes with garbage parmanently output to console, after lib/libc/sys/t_ptrace_wait:syscall_signal_on_sce fails:
102          syscall_signal_on_sce: [[ 3013.0266693] sorry pid 1847 was killed: orphanes
103          ss
104          ss
105          ss
106          ...
107[20]: kernel needs -O1 for ffs32() and ffs_nodealloccg() for multi-user boot. Even if the whole kernel is built with -O1, it panics during ATF:
108      kernel/t_sysv (92/935): 3 test cases
109          msg: [ 3981.4751382] panic: kernel diagnostic assertion "msghdr->msg_spot >= 0" failed: file "../../../../kern/sysv_msg.c", line 426
110[21]: asan has v7/v8/atomic issues:
111      ld: /usr/lib/libasan.so: undefined reference to `__sync_val_compare_and_swap_8'
112      nm shows some more:
113	U __sync_add_and_fetch_4
114	U __sync_fetch_and_add_4
115	U __sync_lock_test_and_set_4
116	U __sync_val_compare_and_swap_1
117	U __sync_val_compare_and_swap_4
118      liblsan and libubsan are mssing the _4 and _8 versions, too.
119[22]: single-user shell crashes. if userland is built with DBG=-O1, it boots into multi-user mode.
120      however, at least db(3) is broken, by which files are corrupted when edited by vi(1).
121[23]: sanitizers fail to build:
122      sanitizer_flag_parser.h:141:72: error: format '%zx' expects argument of type 'size_t', but argument 4 has type 'unsigned int' [-Werror=format=]
123[24]: (NOT A REGRESSION) c++ exception handling is broken. mechanically applying
124      http://www.execsw.org/netbsd/changeset.cgi?id=20140318T234341Z.c59ac4642e7d4b345f6dc5aa9887e9e1f9aa459a#src/gnu/dist/gcc4/gcc/config/vax/vax.c
125      does not help (with adjustments for gcc 10.5.0, which is broken, too):
126      (gdb) invalid-command
127      [1]   Illegal instruction (core dumped) gdb
128[25]: (maybe not related to [24]) native gcc is broken:
129      simh# cc hello.c
130      during RTL pass: final
131      hello.c: In function 'main':
132      hello.c:9:1: internal compiler error: Segmentation fault
133
134
135CPU vs platform test table (for CPUs with multiple ports).  this is "make release" or just kernels.
136values:		y (yes), k (kernels only), n (failed), r (running), ? (not attempted), nx (yes, no x11)
137
138CPU		platform list
139---		-------- ----
140		acorn32		cats	epoc32	evbarm-eb	evbarm-el	hpcarm		iyonix		netwinder	shark 		zaurus
141earmv4:		k		k	k	k		k		k		 		k		y
142earm:		 		 	 	nx		nx		 		k		 		 		k
143earmhf:		 		 	 	k		k
144earmv6:		 		 	 	k		k
145earmv6hf:	 		 	 	nx		nx
146earmv7:		 		 	 	k		k
147earmv7hf:	 		 	 	nx		nx
148
149		amiga		atari	cesfic	hp300		luna68k		mac68k		mvme68k		news68k		next68k		sun3	x68k
150m68k:		nx		k	k	k		k		nx		k		k		k		nx 	k
151
152		evbmips		emips		ews4800mips	mipsco		newsmips	sgimips
153mipseb:		k		k		k		k		k		y
154
155		evbmips		algor		arc		cobalt		hpcmips		pmax
156mipsel:		k		k		k		k		k		y
157
158		algor		evbmips		pmax
159mips64eb:	 		y
160mips64el:	k		y		y
161
162		amigappc	bebox	evbppc	ibmnws		macppc		mvmeppc		ofppc		prep		rs6000		sandpoint
163powerpc:	k		k	k	k		kn[4]		k		k		k		k		k
164
165		evbppc		macppc		ofppc
166powerpc64:	k		k		n[7]
167
168		dreamcast	evbsh3		hpcsh		landisk		mmeye
169sh3eb:		 		y		 		 		k
170sh3el:		k		y		k		k
171