GCC modified for the FreeChainXenon project
Find a file
Gaius Mulley 1bafa6a3fd PR modula2/114565 progress trace would be useful to isolate ICE for users
This patch introduces the internal option -fm2-debug-trace= which can
be given a comma separated list of filter terms.  Currently it allows:
all,line,token,quad.  The patch allows users to trace the progress of
cc1gm2 so that source which causes an ICE can be reduced.  Once
PR113836 is complete it is expected that the trace information will be
written to file.

gcc/m2/ChangeLog:

	PR modula2/114565
	* gm2-compiler/M2GenGCC.mod (CodeStatement): Test
	GetDebugTraceQuad before calling DisplayQuad.
	* gm2-compiler/M2LexBuf.mod (NumberIO): Import CardToStr.
	(GetToken): Test GetDebugTraceToken before writing the
	token number or token line.
	* gm2-compiler/M2Options.def (SetDebugTraceQuad): Rename to
	(SetM2DebugTraceFilter): ...this.
	(SetDebugTraceAPI): Remove.
	(GetDebugTraceQuad): New procedure function.
	(GetDebugTraceTree): Ditto.
	(GetDebugTraceToken): Ditto.
	(GetDebugTraceLine): Ditto.
	(GetDebugFunctionLineNumbers): Ditto.
	* gm2-compiler/M2Options.mod (DebugFunctionLineNumbers): New
	boolean variable.
	(DebugTraceQuad): Ditto.
	(DebugTraceTree): Ditto.
	(DebugTraceLine): Ditto.
	(DebugTraceToken): Ditto.
	(errors1): New procedure.
	(SetDebugTraceQuad): Remove.
	(SetM2DebugTraceFilter): New procedure implemented.
	(SetM2DebugTrace): Ditto.
	(GetDebugTraceQuad): Ditto.
	(GetDebugTraceToken ): Ditto.
	(GetDebugTraceLine): Ditto.
	(SetDebugTraceLine): Remove.
	* gm2-compiler/M2Quads.mod (GenQuadOTrash): Test
	GetDebugTraceQuad and call DisplayQuad.
	(GenQuadOTypetok): Ditto.
	* gm2-compiler/SymbolTable.mod: Replace
	DebugFunctionLineNumbers with GetDebugFunctionLineNumbers.
	* gm2-gcc/init.cc (_M2_M2LangDump_init): Add prototype.
	(init_PerCompilationInit): Add call.
	* gm2-gcc/m2misc.cc (m2misc_cerror): New function.
	(m2misc_error): Ditto.
	* gm2-gcc/m2misc.def (error): New procedure.
	(cerror): Ditto.
	* gm2-gcc/m2misc.h (m2misc_cerror): New prototype.
	(m2misc_error): Ditto.
	* gm2-gcc/m2options.h (M2Options_SetDebugTraceQuad): New
	prototype.
	(M2Options_SetDebugTraceAPI): Remove.
	(M2Options_GetDebugTraceToken): New prototype.
	(M2Options_GetDebugTraceLine): Ditto.
	(M2Options_SetDebugFunctionLineNumbers): Ditto.
	(M2Options_GetDebugFunctionLineNumbers): Ditto.
	(M2Options_SetM2DebugTraceFilter): Ditto.
	* gm2-lang.cc (gm2_langhook_init_options): Remove
	OPT_fdebug_trace_quad case.
	Remove OPT_fdebug_trace_api case.
	Add OPT_fm2_debug_trace_ case.
	* lang.opt (fm2-debug-trace): New option.
	(fdebug-trace-api): Remove.
	(fdebug-trace-quad): Remove.
	* m2.flex (m2flex_M2Error): Check s for NULL.
	(skipnewline): New function.
	(consumeLine): Call traceline.

Signed-off-by: Gaius Mulley <gaiusmod2@gmail.com>
2024-04-02 23:47:42 +01:00
.github Minor formatting fix for newly-added file from previous commit 2023-11-01 19:28:56 -04:00
c++tools Update copyright years. 2024-01-03 12:19:35 +01:00
config Fix up duplicated words mostly in comments, part 1 2024-04-02 13:39:11 +02:00
contrib Daily bump. 2024-03-20 00:18:09 +00:00
fixincludes Daily bump. 2023-11-23 00:18:14 +00:00
gcc PR modula2/114565 progress trace would be useful to isolate ICE for users 2024-04-02 23:47:42 +01:00
gnattools Update Copyright year in ChangeLog files 2024-01-03 11:35:18 +01:00
gotools Daily bump. 2023-11-04 00:16:45 +00:00
include Daily bump. 2024-03-01 00:16:41 +00:00
INSTALL
libada Update copyright years. 2024-01-03 12:19:35 +01:00
libatomic Daily bump. 2024-02-15 00:17:50 +00:00
libbacktrace Daily bump. 2024-03-09 00:17:14 +00:00
libcc1 Daily bump. 2024-03-17 00:17:21 +00:00
libcody Update Copyright year in ChangeLog files 2024-01-03 11:35:18 +01:00
libcpp Daily bump. 2024-03-15 00:17:52 +00:00
libdecnumber Fix up duplicated words mostly in comments, part 1 2024-04-02 13:39:11 +02:00
libffi Daily bump. 2023-10-27 00:17:12 +00:00
libgcc Fix up duplicated words mostly in comments, part 1 2024-04-02 13:39:11 +02:00
libgfortran Fix up duplicated words mostly in comments, part 1 2024-04-02 13:39:11 +02:00
libgm2 Fix up duplicated words mostly in comments, part 1 2024-04-02 13:39:11 +02:00
libgo libgo: bump libgo version for GCC 14 release 2024-02-05 11:28:30 -08:00
libgomp Fix up duplicated words mostly in comments, part 1 2024-04-02 13:39:11 +02:00
libgrust Update copyright years. 2024-02-21 13:51:26 +01:00
libiberty libiberty: Invoke D demangler when --format=auto 2024-04-02 13:30:19 -06:00
libitm Fix up duplicated words mostly in comments, part 1 2024-04-02 13:39:11 +02:00
libobjc Fix up duplicated words mostly in comments, part 1 2024-04-02 13:39:11 +02:00
libphobos Daily bump. 2024-03-18 00:16:48 +00:00
libquadmath Daily bump. 2024-01-04 00:18:45 +00:00
libsanitizer Daily bump. 2024-02-17 00:17:08 +00:00
libssp Daily bump. 2024-02-07 00:18:31 +00:00
libstdc++-v3 libstdc++: Guard uses of char8_t with __cpp_char8_t [PR114519] 2024-04-02 20:55:32 +01:00
libvtv Fix up duplicated words mostly in comments, part 1 2024-04-02 13:39:11 +02:00
lto-plugin Update copyright years. 2024-01-03 12:19:35 +01:00
maintainer-scripts Daily bump. 2023-11-14 12:23:39 +00:00
zlib Daily bump. 2023-10-23 00:16:43 +00:00
.dir-locals.el
.gitattributes
.gitignore *: add modern gettext 2023-11-14 00:47:11 +01:00
ABOUT-NLS
ar-lib
ChangeLog Daily bump. 2024-03-09 00:17:14 +00:00
ChangeLog.jit
ChangeLog.tree-ssa
compile
config-ml.in LoongArch: Reimplement multilib build option handling. 2023-09-15 10:42:12 +08:00
config.guess
config.rpath
config.sub
configure LoongArch: Don't falsely claim gold supported in toplevel configure 2024-02-23 18:13:25 +08:00
configure.ac LoongArch: Don't falsely claim gold supported in toplevel configure 2024-02-23 18:13:25 +08:00
COPYING
COPYING.LIB
COPYING.RUNTIME
COPYING3
COPYING3.LIB
depcomp
install-sh
libtool-ldflags
libtool.m4 Build: fix error in fixinclude configure 2023-11-22 11:54:33 +01:00
ltgcc.m4
ltmain.sh
ltoptions.m4
ltsugar.m4
ltversion.m4
lt~obsolete.m4
MAINTAINERS MAINTAINERS: Fix order in Write After Aproval 2024-03-08 09:14:44 +01:00
Makefile.def gccrs: Fix missing build dependency 2024-01-16 16:23:02 +01:00
Makefile.in Fix up postboot dependencies [PR106472] 2024-04-02 13:40:27 +02:00
Makefile.tpl Fix up postboot dependencies [PR106472] 2024-04-02 13:40:27 +02:00
missing
mkdep
mkinstalldirs
move-if-change
multilib.am
README
SECURITY.txt SECURITY.txt: Drop "exploitable" in reference to hardening issues 2024-01-09 10:49:01 -05:00
symlink-tree
test-driver
ylwrap

This directory contains the GNU Compiler Collection (GCC).

The GNU Compiler Collection is free software.  See the files whose
names start with COPYING for copying permission.  The manuals, and
some of the runtime libraries, are under different terms; see the
individual source files for details.

The directory INSTALL contains copies of the installation information
as HTML and plain text.  The source of this information is
gcc/doc/install.texi.  The installation information includes details
of what is included in the GCC sources and what files GCC installs.

See the file gcc/doc/gcc.texi (together with other files that it
includes) for usage and porting information.  An online readable
version of the manual is in the files gcc/doc/gcc.info*.

See http://gcc.gnu.org/bugs/ for how to report bugs usefully.

Copyright years on GCC source files may be listed using range
notation, e.g., 1987-2012, indicating that every year in the range,
inclusive, is a copyrightable year that could otherwise be listed
individually.