Re: [PATCH 5/4] libbacktrace: improve getting debug information for loaded dlls

2024-05-03 Thread Ian Lance Taylor
On Thu, May 2, 2024 at 12:23 PM Björn Schäpers wrote: > > Am 28.04.2024 um 20:16 schrieb Ian Lance Taylor: > > > > Which of your other patches are still relevant? Thanks. > > > only this one. Thanks. Committed. Ian

Re: [COMMITTED] Remove obsolete Solaris 11.3 support

2024-05-02 Thread Ian Lance Taylor
On Thu, May 2, 2024 at 7:06 AM Rainer Orth wrote: > > * libgo configure.ac and Makefile.am can now expect HAVE_STAT_TIMESPEC > to be true and libgo_cv_lib_setcontext_clobbers_tls doesn't apply any > longer. Any change would have to go upstream first and I don't know > about Ian's policy

Re: [COMMITTED] Reduce startup costs for Value_Range.

2024-05-02 Thread Ian Lance Taylor
On Wed, May 1, 2024 at 7:50 PM Andrew Pinski wrote: > > On Wed, May 1, 2024 at 7:40 PM Ian Lance Taylor wrote: > > > > On Wed, May 1, 2024 at 12:43 AM Aldy Hernandez wrote: > > > > > > gcc/ChangeLog: > > > > > > * ipa-f

Re: [COMMITTED] Reduce startup costs for Value_Range.

2024-05-01 Thread Ian Lance Taylor
On Wed, May 1, 2024 at 12:43 AM Aldy Hernandez wrote: > > gcc/ChangeLog: > > * ipa-fnsummary.cc (evaluate_properties_for_edge): Initialize > Value_Range's. > * value-range.h (class Value_Range): Add a buffer and remove > m_irange and m_frange. >

libgo patch commited: Dump register on Solaris

2024-04-29 Thread Ian Lance Taylor
This libgo patch, by Rainer Orth, dumps register values on Solaris on a crash. This fixes GC PR 106813. Bootstrapped and ran Go testsuite on x86_64-pc-linux-gnu. Committed to mainline. Ian a05efc8bf5ed329ea7d9b1740c326bdc6b04e37a diff --git a/gcc/go/gofrontend/MERGE b/gcc/go/gofrontend/MERGE

libgo patch committed: Use in runtime/runtime.h

2024-04-29 Thread Ian Lance Taylor
This libgo patch changes runtime/runtime.h to use the C99 header file rather than defining a bool type and true/false constants itself. C99 was a long time ago and in case this file is always compiled by the newly built GCC. This should fix GCC PR 114875. Bootstrapped on x86_64-pc-linux-gnu.

Re: [PATCH 5/4] libbacktrace: improve getting debug information for loaded dlls

2024-04-28 Thread Ian Lance Taylor
On Thu, Apr 25, 2024 at 1:15 PM Björn Schäpers wrote: > > > Attached is the combined version of the two patches, only implementing the > > variant with the tlhelp32 API. > > > > Tested on x86 and x86_64 windows. > > > > Kind regards, > > Björn. > > A friendly ping. Thanks. Committed as follows.

Re: [PATCH] libbacktrace: Avoid GNU ld --compress-debug-sections=zlib-gabi

2024-04-23 Thread Ian Lance Taylor
On Tue, Apr 23, 2024 at 7:24 AM Jakub Jelinek wrote: > > What we could do is drop the HAVE_COMPRESSED_DEBUG stuff altogether, and > instead similarly how we have HAVE_COMPRESSED_DEBUG_ZSTD have > HAVE_COMPRESSED_DEBUG_{ZLIB,ZLIB_GABI,ZLIB_GNU} and for each of those > if linker supports them test

Re: [PATCH] gotools: Workaround non-reproduceability of automake

2024-04-15 Thread Ian Lance Taylor
On Mon, Apr 15, 2024 at 5:42 AM Jakub Jelinek wrote: > > 2024-04-15 Jakub Jelinek > > * Makefile.am (install-exec-local, uninstall-local): Add goals > on the else branch of if NATIVE to ensure reproducibility. > * Makefile.in: Regenerate. This is OK. Go ahead and

Re: [PATCH] go: Add go.install-dvi rule in go/Make-lang.in

2024-04-04 Thread Ian Lance Taylor
On Thu, Apr 4, 2024 at 9:27 AM Christophe Lyon wrote: > > go has a go.dvi build rule, but lacks the go.install-dvi one. > > 2024-04-04 Christophe Lyon > > gcc/go/ > * Make-lang.in (go.install-dvi): New rule. This is OK. Thanks. Ian

Go patch committed: Use correct check for index value overflow

2024-03-27 Thread Ian Lance Taylor
This patch to the Go frontend uses the correct size and comparison when doing an index value overflow check. This has apparently been wrong since I introduced the code ten years ago. This fixes GCC PR 114500. Bootstrapped and ran Go testsuite on x86_64-pc-linux-gnu. Committed to mainline. Ian

Go patch committed: Update issue16016 test

2024-03-27 Thread Ian Lance Taylor
This patch to the Go testsuite updates issue16016.go. This backports https://go.dev/cl/574536 into the GCC testsuite. This fixes PR go/114453. Bootstrapped and ran test. Committed to mainline. Ian 5b6f599670994bef957bd15c683102468a7104f1 diff --git

Go patch committed: initialize local variable in lower_method_expression

2024-03-27 Thread Ian Lance Taylor
This patch to the Go frontend fixes an uninitialized variables in lower_method_expression. This fixes GCC PR 114463. Bootstrapped and ran Go testsuite on x86_64-pc-linux-gnu. Committed to mainline. Ian 7b2a24f3964509bd5b74c4579c7ea5684e82aee1 diff --git a/gcc/go/gofrontend/MERGE

Re: No rule to make target '../libbacktrace/libbacktrace.la', needed by 'libgo.la'. [PR106472]

2024-03-26 Thread Ian Lance Taylor
pp; bootstrap=true; }; // since 4f4e53dd8517c0b2 > - year 2004 Yes. I was just trying to answer your question. Ian > Am 25. März 2024 23:59:52 UTC schrieb Ian Lance Taylor : >> >> On Sat, Mar 23, 2024 at 4:32 AM Дилян Палаузов >> wrote: >>> >>> >>>

Re: No rule to make target '../libbacktrace/libbacktrace.la', needed by 'libgo.la'. [PR106472]

2024-03-25 Thread Ian Lance Taylor
On Sat, Mar 23, 2024 at 4:32 AM Дилян Палаузов wrote: > > Can the build experts say what needs to be changed? The dependencies I added > are missing in the build configuration (@if gcc-bootstrap). > > I cannot say if libbacktrace should or should not be a bootstrap=true module. I don't count

libbacktrace patch committed: Don't assume compressed section aligned

2024-03-08 Thread Ian Lance Taylor
Reportedly when lld compresses debug sections, it fails to set the alignment of the compressed section such that the compressed header can be read directly. To me this seems like a bug in lld. However, libbacktrace needs to work around it. This patch, originally by the GitHub user ubyte, does

libbacktrace patch committed: Link test programs with -no-install

2024-03-02 Thread Ian Lance Taylor
Some of the libbacktrace tests link a program and then modify the debug info in some way. When configured with --enable-shared the linking, using libtool, generates a shell script. That causes the tests to fail because they can't modify the debug info of a shell script. This patch, originally

libbacktrace patch committed: Skip all LZMA block header padding bytes

2024-03-02 Thread Ian Lance Taylor
This patch to libbacktrace corrects the LZMA block header parsing to skip all the padding bytes, verifying that they are zero. This fixes https://github.com/ianlancetaylor/libbacktrace/issues/118. Bootstrapped and ran libbacktrace tests on x86_64-pc-linux-gnu. I was able to verify that the

Re: libbacktrace patch committed: Read symbol table of debuginfo file

2024-03-01 Thread Ian Lance Taylor
On Thu, Feb 29, 2024 at 7:47 PM Ian Lance Taylor wrote: > > This patch to libbacktrace reads symbol tables from debuginfo files. > These become another symbol table to search. This is needed if people > use --strip-all rather than --strip-debug when adding a debuglink > secti

libbacktrace patch committed: Read symbol table of debuginfo file

2024-02-29 Thread Ian Lance Taylor
This patch to libbacktrace reads symbol tables from debuginfo files. These become another symbol table to search. This is needed if people use --strip-all rather than --strip-debug when adding a debuglink section. This fixes https://github.com/ianlancetaylor/libbacktrace/issues/113. Bootstrapped

Re: [PATCH RFA] build: drop target libs from LD_LIBRARY_PATH [PR105688]

2024-02-07 Thread Ian Lance Taylor
On Tue, Feb 6, 2024 at 6:08 PM Jason Merrill wrote: > > Tested x86_64-pc-linux-gnu. Any thoughts? It still makes sense to me, for what that's worth. Ian > -- 8< -- > > The patch for PR22340 (r104978) moved the adding of TARGET_LIB_PATH to > RPATH_ENVVAR from POSTSTAGE1_HOST_EXPORTS to

libgo patch committed: Bump version number

2024-02-05 Thread Ian Lance Taylor
This libgo patch bumps the version number for the GCC 14 release. This is for GCC PR 113668. Bootstrapped and ran Go testsuite on x86_64-pc-linux-gnu. Committed to mainline. Ian 7b0597eba6b29387b56b8d6a4b38f3586e6b49a5 diff --git a/gcc/go/gofrontend/MERGE b/gcc/go/gofrontend/MERGE index

Go frontend patch committed: print types in a more readable way

2024-02-05 Thread Ian Lance Taylor
This patch to the Go frontend adds Type::message_name to print types in ways that makes sense to users. As we move toward generics, the error messages need to be able to refer to types in a readable manner. Today we use this new feature in AST dumps. Bootstrapped and ran Go testsuite on

libgo patch committed: Better error messages for unsupported target

2024-02-02 Thread Ian Lance Taylor
This libgo patch generates better error messages then the Go GOARCH and GOOS values can't be determined from the target. This indicates that the target is not supported. This is for GCC PR 113530. Bootstrapped and ran Go testsuite on x86_64-pc-linux-gnu. Committed to mainline. Ian

Go patch committed: Export the type "any" as a builtin

2024-02-02 Thread Ian Lance Taylor
This patch to the Go frontend exports the type "any" as a builtin. Otherwise we can't tell the difference between builtin type "any" and a locally defined type "any". This will require updates to the gccgo export data parsers in the main Go repo and the x/tools repo. These updates are

Re: [PATCH 5/4] libbacktrace: improve getting debug information for loaded dlls

2024-01-25 Thread Ian Lance Taylor
On Thu, Jan 25, 2024 at 11:53 AM Björn Schäpers wrote: > > Am 23.01.2024 um 23:37 schrieb Ian Lance Taylor: > > On Thu, Jan 4, 2024 at 2:33 PM Björn Schäpers wrote: > >> > >> Am 03.01.2024 um 00:12 schrieb Björn Schäpers: > >>> Am 30.11.2023 um 20:53 sc

Re: [PATCH 5/4] libbacktrace: improve getting debug information for loaded dlls

2024-01-23 Thread Ian Lance Taylor
On Thu, Jan 4, 2024 at 2:33 PM Björn Schäpers wrote: > > Am 03.01.2024 um 00:12 schrieb Björn Schäpers: > > Am 30.11.2023 um 20:53 schrieb Ian Lance Taylor: > >> On Fri, Jan 20, 2023 at 2:55 AM Björn Schäpers wrote: > >>> > >>> From: Björn S

Go patch committed: Don't pass iota value to lowering pass

2024-01-22 Thread Ian Lance Taylor
This patch to the Go frontend stops passing the iota value to the lowering pass. It is no longer used. The iota value is now handled in the determine-types pass. Bootstrapped and ran Go testsuite on x86_64-pc-linux-gnu. Committed to mainline. Ian 896148947b9ff4845c8bc334f8eff30f91ff3c9a diff

Re: Go patch committed: Move lowering pass after check types pass

2024-01-18 Thread Ian Lance Taylor
On Mon, Dec 18, 2023 at 5:32 PM Ian Lance Taylor wrote: > > This Go frontend patch moves the lowering pass after the type > determination and the type checking passes. This lets us simplify > some of the code that determines the type of an expression, which > previously had to

Go patch committed: Move lowering pass after check types pass

2023-12-18 Thread Ian Lance Taylor
This Go frontend patch moves the lowering pass after the type determination and the type checking passes. This lets us simplify some of the code that determines the type of an expression, which previously had to work correctly both before and after type determination. I'm doing this to help with

Re: [PATCH] libiberty: Fix build with GCC < 7

2023-12-05 Thread Ian Lance Taylor
On Tue, Dec 5, 2023 at 2:06 PM Jakub Jelinek wrote: > > Ok for trunk (both gcc and binutils)? > > 2023-12-05 Jakub Jelinek > > * configure.ac (HAVE_X86_SHA1_HW_SUPPORT): Verify __get_cpuid and > __get_cpuid_count are not implicitly declared. > * configure: Regenerated.

Re: Darwin: Replace environment runpath with embedded [PR88590]

2023-11-30 Thread Ian Lance Taylor
On Thu, Nov 30, 2023 at 11:58 AM Ian Lance Taylor wrote: > > On Thu, Nov 30, 2023 at 11:56 AM Iain Sandoe wrote: > > > > > On 30 Nov 2023, at 19:43, Ian Lance Taylor wrote: > > > > > > On Sun, Oct 22, 2023 at 2:18 PM FX Coudert wrote: > > &g

Re: [PATCH] libgo, libstdc++: Regenerate GCC_CHECK_ASSEMBLER_HWCAP users

2023-11-30 Thread Ian Lance Taylor
On Thu, Nov 30, 2023 at 11:46 AM Ian Lance Taylor wrote: > > On Thu, Nov 30, 2023 at 1:30 AM Rainer Orth > wrote: > > > > the gcc-autoregen bot correctly complained that the libgo and libstdc++ > > configure scripts hadn't been regenerated. I'd have commited the >

Re: Darwin: Replace environment runpath with embedded [PR88590]

2023-11-30 Thread Ian Lance Taylor
On Thu, Nov 30, 2023 at 11:56 AM Iain Sandoe wrote: > > > On 30 Nov 2023, at 19:43, Ian Lance Taylor wrote: > > > > On Sun, Oct 22, 2023 at 2:18 PM FX Coudert wrote: > >> > >> Thanks a lot Alexandre for the review! > > > > This patch chang

Re: [PATCH 4/4] libbacktrace: get debug information for loaded dlls

2023-11-30 Thread Ian Lance Taylor
On Fri, Jan 20, 2023 at 2:55 AM Björn Schäpers wrote: > > From: Björn Schäpers > > Fixes https://github.com/ianlancetaylor/libbacktrace/issues/53, except > that libraries loaded after the backtrace_initialize are not handled. > But as far as I can see that's the same for elf. Thanks, but I

Re: [PATCH] libgo, libstdc++: Regenerate GCC_CHECK_ASSEMBLER_HWCAP users

2023-11-30 Thread Ian Lance Taylor
On Thu, Nov 30, 2023 at 1:30 AM Rainer Orth wrote: > > the gcc-autoregen bot correctly complained that the libgo and libstdc++ > configure scripts hadn't been regenerated. I'd have commited the > following as obvious (just whitespace change), but since libgo is > imported from upstream, I'm

Re: Darwin: Replace environment runpath with embedded [PR88590]

2023-11-30 Thread Ian Lance Taylor
On Sun, Oct 22, 2023 at 2:18 PM FX Coudert wrote: > > Thanks a lot Alexandre for the review! This patch changed the files lingo/configure.ac and libgo/configure. Those files live in an upstream repository and should be changed there and then merged into the GCC repo, as described in

Re: [PATCH 3/4] libbacktrace: work with aslr on windows

2023-11-30 Thread Ian Lance Taylor
On Mon, Nov 20, 2023 at 11:58 AM Björn Schäpers wrote: > > An updated version, using neither A or W, but just the macro. Thanks. Committed as follows. Ian 1017495bc91d40570f58c37e88ca013164782129 diff --git a/libbacktrace/pecoff.c b/libbacktrace/pecoff.c index 56af4828e27..f976a963bf3 100644

Re: [PATCH 2/4] libbacktrace: detect executable path on windows

2023-11-29 Thread Ian Lance Taylor
On Mon, Nov 20, 2023 at 11:57 AM Björn Schäpers wrote: > > this is what I'm using with GCC 12 and 13 on my windows machines, rebased onto > the current HEAD. Thanks. Committed as follows. Ian * fileline.c: Include if available. (windows_get_executable_path): New

libstdc++ patch RFA: Fix dl_iterate_phdr configury for libbacktrace

2023-11-02 Thread Ian Lance Taylor
The libbacktrace sources, as used by libstdc++-v3, fail to correctly determine whether the system supports dl_iterate_phdr. The issue is that the libbacktrace configure assumes that _GNU_SOURCE is defined during compilation, but the libstdc++-v3 configure does not do that. This configury failure

Re: [PATCH] testsuite: Fix _BitInt in gcc.misc-tests/godump-1.c

2023-10-25 Thread Ian Lance Taylor
On Tue, Oct 24, 2023, 11:03 AM Jeff Law wrote: > > > On 10/24/23 09:26, Stefan Schulze Frielinghaus wrote: > > Currently _BitInt is only supported on x86_64 which means that for other > > targets all tests fail with e.g. > > > > gcc.misc-tests/godump-1.c:237:1: sorry, unimplemented:

Go patch committed: Move Selector_expression up in file

2023-10-23 Thread Ian Lance Taylor
This patch to the Go frontend just moves Selector_expression up in file. This is a mechanical change to expressions.cc. This will make Selector_expression visible to Builtin_call_expression for later work. This produces a very large "git --diff", but "git diff --minimal" is clear. Bootstrapped

Go patch committed: Make xx_constant_value methods non-const

2023-10-23 Thread Ian Lance Taylor
This patch to the Go frontend changes the Expression {numeric,string,boolean}_constant_value methods to be non-const. This does not affect anything immediately, but will be useful for later CLs in this series. The only real effect is to Builtin_call_expression::do_export, which remains const and

Go patch committed: Pass Gogo to Runtime::make_call

2023-10-23 Thread Ian Lance Taylor
This Go frontend patches passes the Gogo IR pointer to Runtime::make_call. This is a boilerplate change that doesn't affect compiler output. It's not currently used but will be used by later CLs in this series. Bootstrapped and ran Go testsuite on x86_64-pc-linux-gnu. Committed to mainline.

Go patch committed: Add Expression::is_untyped method

2023-10-23 Thread Ian Lance Taylor
This Go frontend patches adds an Expression::is_untyped method. This method is not currently used by anything, but it will be used by later changes in this series. Bootstrapped and ran Go testsuite on x86_64-pc-linux-gnu. Committed to mainline. Ian ac50e9b72bf9bb6d5b28096bb164fb050db6e290 diff

libgo patch committed: Add missing type conversion

2023-10-23 Thread Ian Lance Taylor
This libgo patch adds a missing type conversion. The gofrontend incorrectly accepted code that was missing a type conversion. The test case for this is bug518.go in https://go.dev/cl/536537. Future CLs in this series will detect the type error. Bootstrapped and ran Go testsuite on

Go patch committed: Remove the traverse_assignments code

2023-10-22 Thread Ian Lance Taylor
This patch to the Go frontend removes the traverse_assignments support. The last caller was removed in https://go.dev/cl/18261 in 2016. Bootstrapped and ran Go testsuite on x86_64-pc-linux-gnu. Committed to mainline. Ian a6e74b0b3316f3f0b2096d6a175c31bed58ae4ed diff --git

Go patch committed: Remove name_ field from Type_switch_statement

2023-10-22 Thread Ian Lance Taylor
This patch to the Go frontend removes the name_ field from the Type_switch_statement class. It's not used for anything. Bootstrapped and ran Go testsuite on x86_64-pc-linux-gnu. Committed to mainline. Ian 1a1fba1e25779247a4969789885ce80b7b4a2359 diff --git a/gcc/go/gofrontend/MERGE

Go patch committed: pass Gogo to more passes

2023-10-22 Thread Ian Lance Taylor
This patch to the G frontend passes a pointer to the Gogo IR to the determine types pass and the type verification pass. This is a straight refactoring that does not change the compiler behavior. This is in preparation for future CLs that rearrange the pass ordering. This introduces one new

Re: [PATCH v2] libiberty: Use posix_spawn in pex-unix when available.

2023-10-03 Thread Ian Lance Taylor
On Tue, Oct 3, 2023 at 12:04 PM Brendan Shanks wrote: > > + ret = posix_spawnattr_init (); > + if (ret) { *err = ret; *errmsg = "posix_spawnattr_init"; goto exit; } Sorry, but let's keep the formatting used in the rest of the file. if (ret != 0) { *err = ret; *errmsg =

Re: [PATCH] libiberty: Use posix_spawn in pex-unix when available.

2023-10-02 Thread Ian Lance Taylor
On Fri, Sep 29, 2023 at 12:18 PM Brendan Shanks wrote: > > + #define ERR_ON_FAILURE(ret, func) \ > +do { if (ret) { *err = ret; *errmsg = func; goto exit; } else {} } while > (0) Thanks, but please don't use a macro that changes control flow. Ian

Re: libgo: Consider '--with-build-sysroot=[...]' for target libraries' build-tree testing (instead of build-time 'CC' etc.) [PR109951] (was: [PATCH 3/4] libgo/test: Fix compilation for build sysroot)

2023-09-12 Thread Ian Lance Taylor via Gcc-patches
On Tue, Sep 12, 2023 at 4:16 AM Thomas Schwinge wrote: > > As we've found, this is conceptually problematic, as discussed in > > "Consider '--with-build-sysroot=[...]' for target libraries' build-tree > testing (instead of

godump.cc patch committed: Handle _BitInt

2023-09-06 Thread Ian Lance Taylor via Gcc-patches
This patch to godump.cc adds support for BITINT_TYPE. Bootstrapped and ran godump and Go tests on x86_64-pc-linux-gnu. Committed to mainline. Ian gcc/ PR go/111310 * godump.cc (go_format_type): Handle BITINT_TYPE. gcc/testsuite/ PR go/111310 *

libgo patch committed: permit $AR to include options

2023-09-06 Thread Ian Lance Taylor via Gcc-patches
This libgo patch changes the go tool to permit the AR environment variable to include options. This mirrors the way it already handles the CC environment variable. This ports https://go.dev/cl/526275 to the gofrontend repo. This is needed for gccgo testing because the top-level GCC Makefile now

Re: [RFC] GCC Security policy

2023-08-08 Thread Ian Lance Taylor via Gcc-patches
On Tue, Aug 8, 2023 at 7:37 AM Jakub Jelinek wrote: > > BTW, I think we should perhaps differentiate between production ready > libraries (e.g. libgcc, libstdc++, libgomp, libatomic, libgfortran, > libquadmath, > libssp) vs. e.g. the sanitizer libraries which are meant for debugging and > I

Re: [RFC] GCC Security policy

2023-08-08 Thread Ian Lance Taylor via Gcc-patches
On Tue, Aug 8, 2023 at 6:02 AM Jakub Jelinek via Gcc-patches wrote: > > On Tue, Aug 08, 2023 at 02:52:57PM +0200, Richard Biener via Gcc-patches > wrote: > > There's probably external tools to do this, not sure if we should replicate > > things in the driver for this. > > > > But sure, I think

Re: [PATCH] [libbacktrace] fix up broken test

2023-08-03 Thread Ian Lance Taylor via Gcc-patches
On Thu, Aug 3, 2023 at 6:27 AM Richard Biener via Gcc-patches wrote: > > zstdtest has some inline data where some testcases lack the > uncompressed length field. Thus it computes that but still > ends up allocating memory for the uncompressed buffer based on > that (zero) length. Oops. Causes

libbacktrace patch committed

2023-07-31 Thread Ian Lance Taylor via Gcc-patches
This libbacktrace patch, based on one by Andres Freund, uses the _pgmptr variable declared on Windows to find the executable file name if none is specified. Bootstrapped and ran libbacktrace testsuite on x86_64-pc-linux-gnu. Committed to mainline. Ian Patch from Andres Freund: * configure.ac:

libgo patch committet: Don't collect package CGOLDFLAGS

2023-07-20 Thread Ian Lance Taylor via Gcc-patches
This libgo patch to the go command sources stops collecting package CGOLDFLAGS when using gccgo. The flags are already collected via cmd/cgo. The gccgo_link_c test is tweaked to do real linking as with this change the cgo ldflags are not fully reflected in go build -n output, since they now only

Re: Merge from trunk to gccgo branch

2023-06-26 Thread Ian Lance Taylor via Gcc-patches
I merged trunk revision 3a39a31b8ae9c6465434aefa657f7fcc86f905c0 to the gccgo branch. Ian

Go patch committed: Support -fgo-importcfg

2023-06-26 Thread Ian Lance Taylor via Gcc-patches
The gc Go compiler has a -importcfg option that takes a file that provides a mapping from import paths to the files that satisfy those imports. This is used by the go build tool to let the compiler read imported packages directly out of the build cache. Without this option the go build tool has

Go patch committed: Support bootstrapping Go 1.21

2023-06-23 Thread Ian Lance Taylor via Gcc-patches
compiler, libgo: support bootstrapping gc compiler In the Go 1.21 release the package internal/profile imports internal/lazyregexp. That works when bootstrapping with Go 1.17, because that compiler has internal/lazyregep and permits importing it. We also have internal/lazyregexp in libgo, but

Re: [PATCH 1/2] go: update usage of TARGET_AIX to TARGET_AIX_OS

2023-06-22 Thread Ian Lance Taylor via Gcc-patches
On Thu, Jun 22, 2023, 4:47 PM Peter Bergner wrote: > On 6/22/23 6:37 PM, Peter Bergner via Gcc-patches wrote: > > On 6/16/23 12:01 PM, Ian Lance Taylor via Gcc-patches wrote: > >> On Fri, Jun 16, 2023 at 9:00 AM Paul E. Murphy via Gcc-patches > >> wrote: > &

Go patch committed: Determine types of Slice_{value, info} expressions

2023-06-21 Thread Ian Lance Taylor via Gcc-patches
This patch to the Go frontend determines the types of a couple of expressions types that accidentally failed to recurse into their subexpressions. The test case for this is https://go.dev/cl/505015. Bootstrapped and ran Go testsuite on x86_64-pc-linux-gnu. Committed to mainline. Ian

Merge from trunk to gccgo branch

2023-06-21 Thread Ian Lance Taylor via Gcc-patches
I merged trunk revision 577223aebc7acdd31e62b33c1682fe54a622ae27 to the gccgo branch. Ian

Re: libgo patch committed: Use a C function to call mmap

2023-06-20 Thread Ian Lance Taylor via Gcc-patches
On Tue, Jun 20, 2023 at 11:35 AM Andreas Schwab wrote: > > On Jun 20 2023, Ian Lance Taylor via Gcc-patches wrote: > > > This libgo patches changes the runtime pacakge to use a C function to call > > mmap. > > > > The final argument to mmap, of type off_t, varies

libgo patch committed: Use a C function to call mmap

2023-06-20 Thread Ian Lance Taylor via Gcc-patches
This libgo patches changes the runtime pacakge to use a C function to call mmap. The final argument to mmap, of type off_t, varies. In https://go.dev/cl/445375 (https://gcc.gnu.org/pipermail/gcc-patches/2022-October/604158.html) we changed it to always use the C off_t type, but that broke 32-bit

libgo patch committed: Add benchmarks and examples to test list

2023-06-16 Thread Ian Lance Taylor via Gcc-patches
In https://go.dev/cl/384695 (https://gcc.gnu.org/pipermail/gcc-patches/2022-February/590289.html) I simplified the code that built lists of benchmarks, examples, and fuzz tests, and managed to break it. This patch corrects the code to once again make the benchmarks available, and to run the

Re: [PATCH 1/2] go: update usage of TARGET_AIX to TARGET_AIX_OS

2023-06-16 Thread Ian Lance Taylor via Gcc-patches
On Fri, Jun 16, 2023 at 9:00 AM Paul E. Murphy via Gcc-patches wrote: > > TARGET_AIX is defined to a non-zero value on linux and maybe other > powerpc64le targets. This leads to unexpected behavior such as > dropping the .go_export section when linking a shared library > on linux/powerpc64le. >

Re: [PATCH] libgcc: Use initarray section type for .init_stack

2023-05-31 Thread Ian Lance Taylor via Gcc-patches
On Wed, May 31, 2023 at 12:41 AM Kewen.Lin via Gcc-patches wrote: > > >> libgcc/ChangeLog: > >> > >> * config/i386/morestack.S: Use @init_array rather than > >> @progbits for section type of section .init_array. > >> * config/rs6000/morestack.S: Likewise. > >> *

libgo patch committed: Add syscall.prlimit

2023-05-11 Thread Ian Lance Taylor via Gcc-patches
As of https://go.dev/cl/476695 the package golang.org/x/sys/unix expects a syscall.prlimit function to exist. This libgo patch adds that function. This is for https://go.dev/issue/46279 and https://go.dev/issue/59712. Since this is a small patch and is needed to compile the widely used

libgo patch committed: Remove test ordering dependency in mime

2023-04-07 Thread Ian Lance Taylor via Gcc-patches
This libgo patch removes a test ordering dependency in the mime package. This is a backport of https://go.dev/cl/421442 from the upstream repo. This fixes https://go.dev/issue/51648. Bootstrapped and ran mime tests on x86_64-pc-linux-gnu. Committed to mainline. Ian

Merge from trunk to gccgo branch

2023-03-29 Thread Ian Lance Taylor via Gcc-patches
I merged trunk revision aa8f4242efc99f24de73c59d53996f28db28c13f to the gccgo branch. Ian

Go patch committed: Mark Call_expression multi-results as result struct

2023-03-28 Thread Ian Lance Taylor via Gcc-patches
This patch to the Go frontend marks a Call_expression multiple results struct as a result struct. In https://go.dev/cl/343873 we stopped padding zero-sized trailing fields in functions that return multiple results where the last result is zero-sized. This CL makes the corresponding change on the

libbacktrace patch committed: Tweaks to zstd decompression

2023-03-28 Thread Ian Lance Taylor via Gcc-patches
In looking over the recently committed support for zstd decompression in libbacktrace, I found a few minor cases that needed fixing. Bootstrapped and tested on x86_64-pc-linux-gnu. Committed to mainline. Ian * elf.c (elf_zstd_read_fse): Call elf_fetch_bits after reading bits, not before. Add

Re: [PATCH] go: Fix up go.test/test/fixedbugs/bug207.go failure [PR109258]

2023-03-24 Thread Ian Lance Taylor
Jakub Jelinek writes: > 2023-03-24 Jakub Jelinek > > PR middle-end/109258 > * go-gcc.cc (Gcc_backend): Add new static data members builtin_pure > and builtin_nothrow. > (Gcc_backend::Gcc_backend): Pass builtin_pure | builtin_nothrow for > BUILT_IN_MEMCMP. >

Go patch committed: Add missing Slice_info_expression::do_traverse

2023-03-22 Thread Ian Lance Taylor via Gcc-patches
This patch to the Go frontend adds the missing Slice_info_expression::do_traverse method. Lack of the method caused https://go.dev/issue/59169. The test case is https://go.dev/cl/478217. Bootstrapped and ran Go testsuite on x86_64-pc-linux-gnu. Committed to mainline and GCC 12 branch. Ian

Add notes for Go to gcc 12 and 13 changes file

2023-03-20 Thread Ian Lance Taylor via Gcc-patches
I committed this patch to the gcc-wwwdocs repo to add some notes about Go to the gcc 12 and 13 changes file. Ian pat e24f9ef56c11c69fc07bddf9a708ea2fc662f2b3 diff --git a/htdocs/gcc-12/changes.html b/htdocs/gcc-12/changes.html index c47d3285..d565c217 100644 --- a/htdocs/gcc-12/changes.html +++

Re: Now gcc-13: [Fwd: [PATCH] gcc-12: Re-enable split-stack support for GNU/Hurd.]

2023-03-15 Thread Ian Lance Taylor via Gcc-patches
nks! > > > > ------ Forwarded message -- > From: Svante Signell > To: gcc-patches > Cc: Ian Lance Taylor , Matthias Klose > Bcc: > Date: Wed, 23 Feb 2022 11:13:50 +0100 > Subject: [PATCH] gcc-12: Re-enable split-stack support for GNU/Hurd. > Hello, > &

Re: Patch ping: Re: [PATCH] libgcc, i386, optabs, v2: Add __float{, un}tibf to libgcc and expand BF -> integral through SF intermediate [PR107703]

2023-03-10 Thread Ian Lance Taylor
Jakub Jelinek writes: > On Wed, Mar 01, 2023 at 01:32:43PM +0100, Jakub Jelinek via Gcc-patches wrote: >> On Wed, Nov 16, 2022 at 12:51:14PM +0100, Jakub Jelinek via Gcc-patches >> wrote: >> > On Wed, Nov 16, 2022 at 10:06:17AM +0100, Jakub Jelinek via >> > Gcc-patches wrote: >> > > Thoughts on

Re: [PATCH] Always define `WIN32_LEAN_AND_MEAN` before

2023-03-05 Thread Ian Lance Taylor via Gcc-patches
On Fri, Mar 3, 2023 at 10:47 PM Xi Ruoyao wrote: > > On Sat, 2023-01-07 at 06:52 +, Jonathan Yong via Gcc-patches wrote: > > On 1/6/23 18:10, Jakub Jelinek wrote: > > > On Sat, Jan 07, 2023 at 02:01:05AM +0800, LIU Hao via Gcc-patches > > > wrote: > > > > libgomp/ > > > > > > > > PR

Re: [PATCH][stage1] Remove conditionals around free()

2023-03-01 Thread Ian Lance Taylor
Bernhard Reutner-Fischer writes: > libgo/runtime/go-setenv.c|6 ++ > libgo/runtime/go-unsetenv.c |3 +-- Files in the libgo directory are mirrored from upstream sources, as described in libgo/README.gcc. Please don't change them in the gcc repository. Thanks. Ian

Re: [PATCH 2/4] libbacktrace: detect executable path on windows

2023-02-05 Thread Ian Lance Taylor via Gcc-patches
On Sun, Feb 5, 2023 at 1:21 AM Björn Schäpers wrote: > > Am 24.01.2023 um 19:32 schrieb Ian Lance Taylor: > > On Tue, Jan 24, 2023 at 10:12 AM Eli Zaretskii via Gcc-patches > > wrote: > >> > >>> From: Ian Lance Taylor > >>> Date: Tue, 24 Jan

Re: [PATCH 2/4] libbacktrace: detect executable path on windows

2023-01-24 Thread Ian Lance Taylor via Gcc-patches
On Tue, Jan 24, 2023 at 10:12 AM Eli Zaretskii via Gcc-patches wrote: > > > From: Ian Lance Taylor > > Date: Tue, 24 Jan 2023 09:58:10 -0800 > > Cc: g...@hazardy.de, gcc-patches@gcc.gnu.org, g...@gcc.gnu.org > > > > I'd rather that the patch loo

Re: [PATCH 2/4] libbacktrace: detect executable path on windows

2023-01-24 Thread Ian Lance Taylor via Gcc-patches
On Tue, Jan 24, 2023 at 8:53 AM Eli Zaretskii via Gcc-patches wrote: > > > From: Ian Lance Taylor > > Date: Tue, 24 Jan 2023 06:35:21 -0800 > > Cc: g...@hazardy.de, gcc-patches@gcc.gnu.org, g...@gcc.gnu.org > > > > > > On Windows it seems that MAX_PATH is n

Re: [PATCH 2/4] libbacktrace: detect executable path on windows

2023-01-24 Thread Ian Lance Taylor via Gcc-patches
On Tue, Jan 24, 2023 at 5:11 AM Eli Zaretskii via Gcc-patches wrote: > > > Date: Mon, 23 Jan 2023 15:00:56 -0800 > > Cc: gcc-patches@gcc.gnu.org, g...@gcc.gnu.org > > From: Ian Lance Taylor via Gcc > > > > > +#ifdef HAVE_WINDOWS_H > > > + > >

Re: [PATCH 2/4] libbacktrace: detect executable path on windows

2023-01-23 Thread Ian Lance Taylor via Gcc-patches
On Fri, Jan 20, 2023 at 2:56 AM Björn Schäpers wrote: > > From: Björn Schäpers > > This is actually needed so that libstdc++'s implementation > to be able to work on windows. > > Tested on x86_64-linux and i686-w64-mingw32. > > -- >8 -- > > * configure.ac: Add a check for windows.h. >

Re: [PATCH 1/4] libbacktrace: change all pc related variables to uintptr_t

2023-01-20 Thread Ian Lance Taylor via Gcc-patches
On Fri, Jan 20, 2023 at 2:54 AM Björn Schäpers wrote: > > From: Björn Schäpers > > It's the right thing to do, since the PC shouldn't go out of the > uintptr_t domain, and in backtrace_pcinfo the pc is uintptr_t. > This is a preparation for a following patch. > > Tested on x86_64-linux and

Go patch committed: Define builtin functions

2023-01-17 Thread Ian Lance Taylor via Gcc-patches
This patch by Andrew Pinski defines two builtin functions that are used by the middle-end. This fixes PR 108426. Bootstrapped and tested on x86_64-pc-linux-gnu. Committed to mainline. Ian PR go/108426 * go-gcc.cc (Gcc_backend::Gcc_backend): Define __builtin_ctzl and

libbacktrace patch committed: Only test --build-id if supported

2023-01-06 Thread Ian Lance Taylor via Gcc-patches
PR 108297 points out that there are systems that use ELF but for which the linker does not support the --build-id option. This libbacktrace patch skips --build-id tests when it doesn't work. Bootstrapped and ran libbacktrace tests on x86_64-pc-linux-gnu. Committed to mainline. Ian PR

Re: [PATCH] go: fix clang warnings

2022-12-22 Thread Ian Lance Taylor via Gcc-patches
On Wed, Dec 21, 2022 at 12:05 AM Martin Liška wrote: > > The patch fixes the following Clang warnings: > > gcc/go/gofrontend/escape.cc:1290:17: warning: private field 'fn_' is not used > [-Wunused-private-field] > gcc/go/gofrontend/escape.cc:3478:19: warning: private field 'context_' is not >

Re: [PATCH] libgo: check if -lucontext is required for {make, set, get}context

2022-12-20 Thread Ian Lance Taylor via Gcc-patches
On Mon, Dec 19, 2022 at 8:59 AM wrote: > > From: Sören Tempel > > This patch is similar to the existing check for librt. If libucontext > is installed and libucontext.a provides the aforementioned symbols, then > it is added to $LIBS. If not, no error is emitted. We could, > alternatively, also

Re: Add zstd support to libbacktrace

2022-12-16 Thread Ian Lance Taylor via Gcc-patches
Some more tweaks of the libbacktrace zstd decompressor to make decompressing slightly faster: unpack all the literal data into the output buffer, rather than using scratch space. Bootstrapped and ran libbacktrace tests on x86_64-pc-linux-gnu. Committed to mainline. Ian * elf.c

libgo patch committed: Bump major version

2022-12-12 Thread Ian Lance Taylor via Gcc-patches
This libgo patch bumps the major version. The current version is the same as for GCC 12, but there have been minor changes like new type descriptors that make it impossible to run Go programs built with GCC 12 with the current GCC. This fixes https://gcc.gnu.org/PR108057. Bootstrapped on

Re: Add zstd support to libbacktrace

2022-12-09 Thread Ian Lance Taylor via Gcc-patches
On Wed, Dec 7, 2022 at 4:22 PM Ian Lance Taylor wrote: > > This patch adds zstd support to libbacktrace, to support the new > linker option --compress-debug-sections=zstd. This patch rewrites and simplifies the main zstd decompression loop using some ideas from the reference imple

Add zstd support to libbacktrace

2022-12-07 Thread Ian Lance Taylor via Gcc-patches
This patch adds zstd support to libbacktrace, to support the new linker option --compress-debug-sections=zstd. The zstd format is fairly complicated, so it's likely that there are some bugs here. It does pass the tests, at least. Unfortunately this decompressor only runs at about 1/3 the speed

Re: [PATCH v2] libgo: Don't rely on GNU-specific strerror_r variant on Linux

2022-11-30 Thread Ian Lance Taylor via Gcc-patches
On Tue, Nov 29, 2022 at 4:10 PM Ian Lance Taylor wrote: > > On Tue, Nov 29, 2022 at 9:54 AM wrote: > > > > From: Sören Tempel > > > > On glibc, there are two versions of strerror_r: An XSI-compliant and a > > GNU-specific version. The latter is only avail

Re: [PATCH v2] libgo: Don't rely on GNU-specific strerror_r variant on Linux

2022-11-29 Thread Ian Lance Taylor via Gcc-patches
On Tue, Nov 29, 2022 at 9:54 AM wrote: > > From: Sören Tempel > > On glibc, there are two versions of strerror_r: An XSI-compliant and a > GNU-specific version. The latter is only available on glibc. In order > to avoid duplicating the post-processing code of error messages, this > commit

Re: [PATCH] lto: Stream current working directory for first streamed relative filename and adjust relative paths [PR93865]

2022-11-14 Thread Ian Lance Taylor via Gcc-patches
On Thu, Sep 10, 2020 at 1:39 AM Jakub Jelinek via Gcc-patches wrote: > > If the gcc -c -flto ... commands to compile some or all objects are run in a > different directory (or in different directories) from the directory in > which the gcc -flto link line is invoked, then the .debug_line will be

Go patch committed: Define __atomic_fetch_add functions

2022-11-09 Thread Ian Lance Taylor via Gcc-patches
This patch to the GCC-specific part of the Go frontend defines the __atomic_fetch_add functions. The frontend only generates calls to the __atomic_add_fetch functions, but in some cases the middle-end can transform the latter into the former. This patch is originally by Marc Poulhiès. This

  1   2   3   4   5   6   7   8   9   10   >