[committed] d: Use __builtin_clear_padding for zeroing alignment holes after set

2025-04-29 Thread Iain Buclaw
Hi, In an earlier change, a wrapper function was added to set CONSTRUCTOR_ZERO_PADDING_BITS on all CONSTRUCTOR nodes. This removes all the old generated calls to built-in memset and memcpy as zero padding is now taken care of by the middle-end. The remaining constructors that weren't getting zero

[PATCH] Add m32c*-*-* to the list of obsolete targets

2025-04-25 Thread Iain Buclaw
Hi, This patch marks m32c*-*-* targets obsolete in GCC 16. The target has not had a maintainer since GCC 9 (r9-1950), and fails to compile even the simplest of functions since GCC 8 (r8-777, as reported in PR83670). OK for trunk? Regards, Iain. --- contrib/ChangeLog: * config-list.mk:

Re: [PATCH] libphobos: enable for sparc64-unknown-linux-gnu

2025-04-22 Thread Iain Buclaw
Excerpts from Sam James's message of April 20, 2025 2:46 am: > This bootstraps with some test failures but works well enough to build > 11..15. > > libphobos/ChangeLog: > > * configure.tgt: Add sparc64-unknown-linux-gnu as a supported target. > --- > As discussed on IRC. OK? I'd like to bac

[committed] d: Fix infinite loop regression in CTFE

2025-04-18 Thread Iain Buclaw
Hi, This patch merges the D front-end with upstream dmd 956e73d64e. An infinite loop was introduced by a previous refactoring in the semantic pass for DeclarationExp nodes. Ensure the loop properly terminates and add tests cases. Bootstrapped and regression tested on x86_64-linux-gnu/-m32, and c

[committed] d: Fix ICE: type variant differs by TYPE_MAX_VALUE with -g [PR119826]

2025-04-15 Thread Iain Buclaw
Hi, This patch fixes the ICE in PR119826. Forward referenced enum types were never fixed up after the main ENUMERAL_TYPE was finished. All flags set are now propagated to all variants after its mode, size, and alignment has been calculated. Bootstrapped and regression tested on x86_64-linux-gnu

Re: [PATCH] wwwdocs: Document changes to the D front-end

2025-04-15 Thread Iain Buclaw
Ping. If no obvious grammar errors are flagged, I'll likely just commit this later today. Thanks, Iain. Excerpts from Iain Buclaw's message of März 20, 2025 12:25 pm: > Hi, > > This patch adds D front-end section to the GCC changes pages. When > inspecting this, I noticed that the previous two

[committed] d: Fix internal compiler error: in visit, at d/decl.cc:838 [PR119799]

2025-04-15 Thread Iain Buclaw
Hi, This patch fixes the ICE in PR119799. This was caused by a check in the D front-end disallowing static VAR_DECLs with a size `0'. While empty structs in D are given the size `1', the same symbol coming from ImportC modules do infact have no size, so allow C variables to pass the check as wel

[committed] d: Fix ICE in dwarf2out_imported_module_or_decl, at dwarf2out.cc:27676 [PR119817]

2025-04-15 Thread Iain Buclaw
Hi, This patch fixes the ICE in PR119817. The ImportVisitor method for handling the importing of overload sets was pushing NULL_TREE to the array of import decls, which in turn got passed to `debug_hooks->imported_module_or_decl', triggering the observed internal compiler error. NULL_TREE is ret

[committed] d: Fix -fonly= argument only matches when including full path [PR119758]

2025-04-12 Thread Iain Buclaw
Hi, This patch fixes a couple issues with the `-fonly=' option in the D front-end driver. Using `strcmp' to match the `-fonly=' argument with the input source file made the feature inflexible to use. By mistake, the driver was also found to omit all other modules on the command line as well, whi

[committed] d: Add option to include imported modules in the compilation [PR109023]

2025-04-12 Thread Iain Buclaw
Hi, This patch adds the ability to include imported modules in the compilation, as if they were given on the command line. When this option is enabled, all imported modules are compiled except those that are part of libphobos. Bootstrapped and regression tested on x86_64-linux-gnu/-m32, and comm

[committed] d: Merge upstream dmd 1b34fea478, phobos 40ffbb364

2025-04-11 Thread Iain Buclaw
Hi, This patch merges the D front-end compiler with upstream dmd 1b34fea478, and the standard runtime library with upstream phobos 40ffbb364. Synchronizing the recent bug fixes targeted for v2.111.1. D front-end changes: - Import latest fixes from dmd v2.111.1-rc.1. Phobos changes:

[committed] d: Fix infinite loop in isAliasThisTuple

2025-04-10 Thread Iain Buclaw
Hi, This reverts a change in the upstream D implementation of the compiler, as the refactoring introduced a regression. Bootstrapped and regression tested on x86_64-linux-gnu/-m32, and committed to mainline. Regards, Iain. --- gcc/d/ChangeLog: * dmd/MERGE: Merge upstream dmd 51816cd01d

[committed] d: Fix forward referenced enums missing type names in debug info [PR118309]

2025-04-09 Thread Iain Buclaw
Hi, This patch fixes a crash seen when gdb was debugging D programs. Calling `rest_of_type_compilation' as the D types were built meant that debug info was being emitted before all forward references were resolved, resulting in DW_AT_name's to be missing. Instead, defer outputting type debug inf

[committed] d: Use CONSTRUCTOR_ZERO_PADDING_BITS in the D FE [PR117832]

2025-04-09 Thread Iain Buclaw
Hi, This patch adds a new wrapper function for `build_constructor', and calls it instead to ensure that all CONSTRUCTOR nodes explicitly created by the front-end have CONSTRUCTOR_ZERO_PADDING_BITS set. Some places may not be necessary as it's guaranteed for there to be no padding in the type, suc

[committed] libphobos: Merge with upstream phobos 35977c802

2025-04-08 Thread Iain Buclaw
Hi, This patch merges the D standard library with upstream phobos 35977c802. Synchronizes recent bug fixes targeted for v2.111.1. Bootstrapped and regression tested on x86_64-linux-gnu/-m32, and committed to mainline. Regards, Iain. --- libphobos/ChangeLog: * src/MERGE: Merge upstream

[committed] d: Bump front-end language version to v2.111.0

2025-04-04 Thread Iain Buclaw
Hi, This patch merges the front-end language implementation and runtime library with upstream dmd c6863be720, and the standard library with phobos 60034b56e. Synchronizing with the upstream release of v2.111.0. Bootstrapped and regression tested on x86_64-linux-gnu/-m32, and committed to mainlin

[committed] libphobos: Add module declaration to rt.invariant

2025-04-04 Thread Iain Buclaw
Hi, This patch adds a module declaration to the rt/invariant.d module, preventing conflicts with a user-provided `invariant.d' module. Bootstrapped and regression tested on x86_64-linux-gnu/-m32, and committed to mainline. Regards, Iain. --- gcc/d/ChangeLog: * runtime.def (INVARIANT):

[committed] d: Fix error using UFCS in a speculative context

2025-04-02 Thread Iain Buclaw
Hi, This patch merges the D front-end with upstream dmd ed17b3e95d. Reverts a change in the upstream D implementation of the compiler, as it is no longer necessary since another fix for opDispatch got applied in the same area (merged in r12-6003-gfd43568cc54e17). Bootstrapped and regression test

[committed] d: Fix error with -Warray-bounds and -O2 [PR117002]

2025-03-31 Thread Iain Buclaw
Hi, This patch fixes an error raised by the middle-end when compiling with the options `-Warray-bounds -O2'. The record layout of class types in D don't get any tail padding, so it is possible for the `classInstanceSize' to not be a multiple of the `classInstanceAlignment'. Rather than setting t

[PING][PATCH] Makefile.tpl: Implement per-stage GDCFLAGS [PR116975]

2025-03-26 Thread Iain Buclaw
Ping. Excerpts from Iain Buclaw's message of März 3, 2025 11:14 pm: > Hi, > > This patch implements STAGE1_GDCFLAGS and others to the configure > machinery, allowing the GDCFLAGS for each bootstrap stage of building > gdc to be overriden, as is the case with CXXFLAGS for other front-ends. > > Th

[committed] d: import __stdin causes compilation to pause while reading from stdin

2025-03-26 Thread Iain Buclaw
Hi, This patch merges the D front-end with upstream dmd 02a64d2e13. Moves the special handling of reading from stdin out of the language semantic routines. All references to `__stdin.d` have also been removed from the front-end implementation. Bootstrapped and regression tested on x86_64-linux-g

[committed] testsuite: d: Break up Wbuiltin_declaration_mismatch2.d into smaller tests

2025-03-24 Thread Iain Buclaw
Hi, This patch splits Wbuiltin_declaration_mismatch2.d into multiple tests. When looking at failures on ARM64, this aided in understanding which specific tests weren't passing. Regression tested on x86_64-linux-gnu, committed to mainline. Regards, Iain. --- gcc/testsuite/ChangeLog: * g

[committed] d: Fix ICE type variant differs by TYPE_PACKED [PR117621]

2025-03-23 Thread Iain Buclaw
Hi, r13-1104-gf4c3ce32fa54c1 introduced a regression, which had an accidental self assignment of TYPE_PACKED when it should have been assigned to the type's variants. This patch fixes that. Bootstrapped and regression tested on x86_64-linux-gnu/-m32, committed to mainline, and backported to relea

[committed] d: Add C++23 to CppStdRevision enum

2025-03-22 Thread Iain Buclaw
Hi, This patch merges the D front-end with upstream dmd 94950cae58. D front-end changes: - The compiler now accepts `-fextern-std=c++23' Bootstrapped and regression tested on x86_64-linux-gnu/-m32, and committed to mainline. Regards, Iain. --- gcc/d/ChangeLog: * dmd/MERGE: Me

[committed] d: Bump front-end language version to v2.111.0-rc.1.

2025-03-22 Thread Iain Buclaw
Hi, This patch merges the D front-end with upstream dmd 032e24446b. The language version is now v2.111.0-rc.1. Bootstrapped and regression tested on x86_64-linux-gnu/-m32, and committed to mainline. Regards, Iain. --- gcc/d/ChangeLog: * dmd/MERGE: Merge upstream dmd 032e24446b.

[committed] libphobos: Fix IEEE typo in std.numeric link

2025-03-22 Thread Iain Buclaw
Hi, This patch merges libphobos with upstream phobos d4c9efef1. Regards, Iain. --- libphobos/ChangeLog: * src/MERGE: Merge upstream phobos d4c9efef1. Reviewed-on: https://github.com/dlang/phobos/pull/10700 --- libphobos/src/MERGE | 2 +- libphobos/src/std/numeric.d | 2 +- 2 f

[committed] d: Indexing a cast(AA) yields no lvalue anymore

2025-03-22 Thread Iain Buclaw
Hi, This patch merges the D front-end with upstream dmd 8db14cf846. Bootstrapped and regression tested on x86_64-linux-gnu/-m32, and committed to mainline. Regards, Iain. --- gcc/d/ChangeLog: * dmd/MERGE: Merge upstream dmd 8db14cf846. Reviewed-on: https://github.com/dlang/dmd/pull/21

[committed] d: Improve UFCS/property error message

2025-03-22 Thread Iain Buclaw
Hi, This patch merges the D front-end with upstream dmd 9d2f034398. Bootstrapped and regression tested on x86_64-linux-gnu/-m32, and committed to mainline. Regards, Iain. --- gcc/d/ChangeLog: * dmd/MERGE: Merge upstream dmd 9d2f034398. Reviewed-on: https://github.com/dlang/dmd/pull/21

[committed] d: Fix quoted command-line options to match lang.opt [PR118545]

2025-03-20 Thread Iain Buclaw
Hi, It was noticed that not all D language options get a url in diagnostics. These have been checked and fixed as necessary. Bootstrapped and regression tested on x86_64-linux-gnu/-m32, and committed to mainline. Regards, Iain. --- PR d/118545 gcc/d/ChangeLog: * d-lang.cc (d_h

[PATCH] wwwdocs: Document changes to the D front-end

2025-03-20 Thread Iain Buclaw
Hi, This patch adds D front-end section to the GCC changes pages. When inspecting this, I noticed that the previous two releases has been missed/forgot about as well. Ran all pages through the w3c validator and got no reported errors. OK? Thanks, Iain. --- * htdocs/gcc-13/changes.html:

[GCC-14][committed] d: Merge upstream dmd, druntime af92b68a81, phobos c970ca67f

2025-03-19 Thread Iain Buclaw
Hi, This patch merges the D front-end and run-time libraries with the upstream dmd 2.108.1 release. D front-end changes: - Import dmd v2.108.1. D runtime changes: - Import druntime v2.108.1. Phobos changes: - Import phobos v2.108.1. Bootstrapped and regression tested

[committed] libphobos: Fix std.getopt doesn't accept const(string)[] anymore

2025-03-18 Thread Iain Buclaw
Hi, This patch was cherry-picked from upstream phobos commit 79cbde1ab. Bootstrapped and regression tested on x86_64-linux-gnu/-m32 and committed to mainline. Regards, Iain. --- libphobos/ChangeLog: * src/MERGE: Merge upstream phobos 79cbde1ab. Reviewed-on: https://github.com/dlang/ph

[committed] libphobos: Avoid setting union members in std.json, set the whole union instead

2025-03-18 Thread Iain Buclaw
Hi, This patch was cherry-picked from upstream phobos commit cafe86453. Bootstrapped and regression tested on x86_64-linux-gnu/-m32 and committed to mainline. Regards, Iain. --- libphobos/ChangeLog: * src/MERGE: Merge upstream phobos cafe86453. Reviewed-on: https://github.com/dlang/ph

[committed] libphobos: Merge changes in upstream druntime testsuite

2025-03-18 Thread Iain Buclaw
Hi, This patch merges libphobos with upstream druntime d2ee11364c. Regtested on x86_64-linux-gnu/-m32 and committed to mainline. Regards, Iain. --- libphobos/ChangeLog: * libdruntime/MERGE: Merge upstream druntime d2ee11364c. * testsuite/libphobos.aa/test_aa.d: Add new test.

[committed] d: Add missing Declaration bitfield setters/getters

2025-03-18 Thread Iain Buclaw
Hi, This patch merges the D front-end with upstream dmd fde0f8c40a. Bootstrapped and regression tested on x86_64-linux-gnu, committed to mainline. Regards, Iain. --- gcc/d/ChangeLog: * dmd/MERGE: Merge upstream dmd fde0f8c40a. Reviewed-on: https://github.com/dlang/dmd/pull/21014 ---

[committed] d: Update the copyright years of dmd sources to 2025

2025-03-18 Thread Iain Buclaw
Hi, This patch merges the D front-end with upstream dmd 51be8bb729. Updates all copyright years from 2024 -> 2025. Regards, Iain. --- gcc/d/ChangeLog: * dmd/MERGE: Merge upstream dmd 51be8bb729. Reviewed-on: https://github.com/dlang/dmd/pull/20958 --- gcc/d/dmd/MERGE

[committed] libphobos: Merge upstream phobos 0faae92d6

2025-03-12 Thread Iain Buclaw
Hi, This patch merges the D standard library with upstream phobos 0faae92d6. Synchronizing with the upstream release of v2.111.0-beta.1. Phobos changes: - Import phobos v2.111.0-beta.1. - Added `bitCast' function to `std.conv'. - Added `readfln' and `File.readfln' functi

[committed] d: Fix regression returning from function with invariants [PR119139]

2025-03-11 Thread Iain Buclaw
Hi, An optimization was added in GDC-12 which sets the TREE_READONLY flag on all local variables with the storage class `const' assigned. For some reason, const is also being added by the front-end to `__result' variables in non-virtual functions, which ends up getting wrong code by the gimplify

[committed] libphobos: Default to libc closefrom in spawnProcessPosix [PR119112]

2025-03-10 Thread Iain Buclaw
Hi, This is a backport of two changes in upstream Phobos. - The current implementation of spawnProcessPosix is broken on systems with a large `ulimit -n' because it always OOMs making it impossible to spawn processes. Using the libc implementation, when available, for doing file descriptor operat

[PATCH] Makefile.tpl: Implement per-stage GDCFLAGS [PR116975]

2025-03-03 Thread Iain Buclaw
Hi, This patch implements STAGE1_GDCFLAGS and others to the configure machinery, allowing the GDCFLAGS for each bootstrap stage of building gdc to be overriden, as is the case with CXXFLAGS for other front-ends. This is limited to just the generation of recipes for the configure-stage-gcc and all

[committed] d: Fix comparing uninitialized memory in dstruct.d [PR116961]

2025-02-28 Thread Iain Buclaw
Hi, This patch fixes a case where the D language implementation was comparing objects with uninitialized memory. Explanation: Floating-point emulation in the D front-end is done via a type named `struct longdouble`, which in GDC is a small interface around the real_value type. Because the D code

[committed] libphobos: Run unittest tests with dg-runtest.

2025-02-27 Thread Iain Buclaw
Hi, This patches fixes the libphobos unittest testsuite to use `dg-runtest' test driver rather than `dg-test', same as all other libphobos tests. This prevents the tests from being ran multiple times when parallelized. Set `libphobos_test_name' as well so that all tests get a unique name. Regres

Re: [committed] d: Increase max parallelism of the D testsuite

2025-02-27 Thread Iain Buclaw
Excerpts from Lewis Hyatt's message of Februar 26, 2025 2:04 am: > On Tue, Feb 25, 2025 at 12:00 PM Iain Buclaw wrote: >> >> Hi, >> >> It was noticed that when running the testsuite for gdc and libphobos in >> parallel, this was capped at 10 simultaneous job

[committed] libphobos: Add script for extracting unittests from phobos

2025-02-25 Thread Iain Buclaw
Hi, This patch adds a script to parse all unittests annotated with three slashes (`///') and extracts them into a standalone test case. The intended use is for generating inexpensive tests to be ran for the phobos testsuite. Committed to mainline. Regards, Iain. --- libphobos/ChangeLog:

[committed] libphobos: Organize druntime and phobos tests under common directory

2025-02-25 Thread Iain Buclaw
Hi, This patch organizes the druntime and phobos tests to prepare for a future change where tests will be generated within these directories. The druntime and druntime_shared tests are identical, save for one compiled with `-static-libphobos' and the other `-shared-libphobos'. Move them to libpho

[committed] libphobos: Add scripts to update Makefile.am after an upstream merge

2025-02-25 Thread Iain Buclaw
Hi, These two scripts have been used for updating Makefile.am whenever there's been a file added/removed from either Druntime or Phobos since the start, but never included in the source tree. This patch finally adds them, rather than referencing an outdated gist. Committed to mainline. Regards,

[committed] d/i386: Add CET TargetInfo key and predefined version [PR118654]

2025-02-25 Thread Iain Buclaw
Hi, This patch adds a new i386 d_target_info_spec entry to handle requests for `__traits(getTargetInfo, "CET")', and add predefined target version `GNU_CET' when the option `-fcf-protecton' is used. Both TargetInfo key and predefined version have been added to the D front-end documentation. In t

[committed] d: Increase max parallelism of the D testsuite

2025-02-25 Thread Iain Buclaw
Hi, It was noticed that when running the testsuite for gdc and libphobos in parallel, this was capped at 10 simultaneous jobs each. Increase this limit to 128, which enables running for example `make check-d -j48` to complete in half the time. Bootstrapped and regression tested on x86_64-linux-g

Re: [PATCH v2 1/1] gdc: define ELFv1 and ELFv2 versions for powerpc

2025-02-15 Thread Iain Buclaw
Excerpts from liushuyu's message of Februar 13, 2025 10:00 pm: > From: Zixing Liu > > gcc/ChangeLog: > * config/rs6000/rs6000-d.cc: define ELFv1 and ELFv2 > version identifiers according to the target options. > > gcc/testsuite/ChangeLog: > * gdc.dg/ppcabi.d: Add a test to te

Re: [PATCH] libphobos: Disable libphobos.phobos/std/concurrency.d on macOS 13+ [PR111628]

2025-02-10 Thread Iain Buclaw
Thanks Rainer. This is fine until the cause is identified. Iain. On 10 February 2025 13:28:00 CET, Rainer Orth wrote: >The libphobos.phobos_shared/std/concurrency.d test just hangs on macOS >13 and beyond and isn't even termintated after the testsuite timeout is >exceeded. Thus, more and more

Re: [PATCH 0/1] gdc: define ELFv1, ELFv2 and D_PPCUseIEEE128 versions for powerpc

2025-02-09 Thread Iain Buclaw
Excerpts from liushuyu's message of Februar 6, 2025 2:02 am: > From: Zixing Liu > > This set of patches will add proper IEEE 128 quad precision marking to GDC > compiler, so that it works with the new changes in D standard library > where POWER system can use any math functions inside the standar

Re: [committed] libphobos: Add MIPS64 implementation of fiber_switchContext [PR118584]

2025-01-23 Thread Iain Buclaw
Excerpts from Maciej W. Rozycki's message of Januar 23, 2025 6:29 pm: > On Tue, 21 Jan 2025, Iain Buclaw wrote: > >> This patch adds a MIPS64 implementation of `fiber_switchContext', >> replacing the generic implementation. The `core.thread.fiber' module >>

[committed] libphobos: Add MIPS64 implementation of fiber_switchContext [PR118584]

2025-01-21 Thread Iain Buclaw
Hi, This patch adds a MIPS64 implementation of `fiber_switchContext', replacing the generic implementation. The `core.thread.fiber' module already defines version=AsmExternal on mips64el-linux-gnuabi64 targets. Committed to mainline. Regards, Iain. --- PR d/118584 libphobos/ChangeLog:

[GCC-12/13][committed] d: Fix ICE in build_deref, at d/d-codegen.cc:1650 [PR111650]

2025-01-21 Thread Iain Buclaw
Hi, This patch was committed some time ago in r14-10036, now it's being backported to the gcc-13 and gcc-12 release branches. The ICE in the D front-end was found to be caused by in some cases the hidden closure parameter type being generated too early for nested functions. Better to update the

[GCC-12][committed] d: Fix failing test with 32-bit compiler [PR114434]

2025-01-20 Thread Iain Buclaw
Hi, This is patch is a backport of r15-7071, with test included ad verbatim. Since the introduction of `gdc.test/runnable/test23514.d', it's exposed an incorrect compilation when adding a 64-bit constant to a link-time address. The current cast to `size_t' causes a loss of precision, which can r

[committed] d: Fix failing test with 32-bit compiler [PR114434]

2025-01-20 Thread Iain Buclaw
Hi, Since the introduction of `gdc.test/runnable/test23514.d', it's exposed an incorrect compilation when adding a 64-bit constant to a link-time address. The current cast to `size_t' causes a loss of precision, which can result in incorrect compilation. Bootstrapped and regtested on x86_64-linu

[GCC-14][committed] d: Fix ICE in expand_d_format when diagnosing empty enum [PR117115]

2025-01-17 Thread Iain Buclaw
Hi, This patch backports the individual fix for PR117115 from the upstream merge in r15-6824 into the releases/gcc-14 branch. Bootstrapped and regression tested on x86_64-linux-gnu/-m32, and committed to branch. Regards, Iain. --- PR d/117115 gcc/testsuite/ChangeLog: * gdc.dg/

[committed] d: Add testcase for fixed PR117115

2025-01-17 Thread Iain Buclaw
Hi, This patch adds a testcase for a PR that was fixed in upstream, and merged in r15-6824. Regression tested on x86_64-linux-gnu, and committed to mainline. Regards, Iain. --- PR d/117115 gcc/testsuite/ChangeLog: * gdc.dg/pr117115.d: New test. --- gcc/testsuite/gdc.dg/pr1171

[GCC-14][committed] d: Fix record layout of compiler-generated TypeInfo_Class [PR115249]

2025-01-16 Thread Iain Buclaw
Hi, This is the backport of r15-6983 to releases/gcc-14. In r14-8766, the layout of TypeInfo_Class changed in the runtime library, but didn't get reflected in the compiler-generated data, causing a corruption of runtime type introspection on BigEndian targets. This adjusts the size of the `Class

[committed] d: Fix record layout of compiler-generated TypeInfo_Class [PR115249]

2025-01-16 Thread Iain Buclaw
Hi, In r14-8766, the layout of TypeInfo_Class changed in the runtime library, but didn't get reflected in the compiler-generated data, causing a corruption of runtime type introspection on BigEndian targets. This adjusts the size of the `ClassFlags' field from uint to ushort, and adds a new ushor

[GCC-14][committed] d: Fix ICE in dmd.expressionsem.resolveLoc

2025-01-16 Thread Iain Buclaw
Hi, This patch backports the individual fix for PR116373 from the upstream merge in r15-6559-g332cf038fda109 into the releases/gcc-14 branch. Bootstrapped and regression tested on x86_64-linux-gnu/-m32, and committed to branch. Regards, Iain. --- PR d/116373 gcc/d/ChangeLog: *

[committed] d: Add testcase for fixed PR116373

2025-01-16 Thread Iain Buclaw
Hi, This patch adds a testcase for a PR that was fixed in upstream, and merged in r15-6559-g332cf038fda109. Regression tested on x86_64-linux-gnu, and committed to mainline. Regards, Iain. --- PR d/116373 gcc/testsuite/ChangeLog: * gdc.dg/pr116373.d: New test. --- gcc/testsui

Re: Ping: [PATCH] d,ada/spec: only sub nostd{inc,lib} rather than nostd{inc,lib}*

2025-01-16 Thread Iain Buclaw
Excerpts from Arsen Arsenović's message of Oktober 7, 2024 11:31 pm: > Ping on this patch. > Thanks, this is OK for D. Note, that the gdc driver does try to accomodate for mixing C++ and D code in the same application - so given: gdc a.d b.cc It adds -lstdc++ to the link command for conve

Re: [PATCH] D, Darwin: Restore bootstrap.

2025-01-14 Thread Iain Buclaw
Excerpts from Iain Sandoe's message of Januar 14, 2025 9:10 pm: > Tested on x86_64, i686 darwin17 and aarch64 darwin21, > OK for trunk, or alternate solution? > thanks, > Iain > Thank Iain, Could a pull request be made upstream here? https://github.com/dlang/dmd/pulls Location of this module i

[committed] d: Merge upstream dmd, druntime d6f693b46a, phobos 336bed6d8.

2025-01-14 Thread Iain Buclaw
Hi, This patch merges the D front-end and runtime library with upstream dmd d6f693b46a, and the standard library with phobos 336bed6d8. Synchronizing with the latest changes in v2.110.0. D front-end changes: - Import latest fixes from dmd v2.110.0-rc.1. D runtime changes: - Im

[committed] libphobos: Bump soname to version 6 [PR117701]

2025-01-13 Thread Iain Buclaw
Hi, This patch bumps the soname of libphobos from version 5 to version 6. Each major release is not binary compatible with the previous. Regstrapped on x86_64-linux-gnu, committed to mainline. Regards, Iain. --- PR d/117701 libphobos/ChangeLog: * configure: Regenerate.

Re: [PATCH] d, v2: give dependency files better filenames

2025-01-13 Thread Iain Buclaw
Excerpts from Jakub Jelinek's message of Januar 13, 2025 2:58 pm: > On Mon, Jan 13, 2025 at 02:45:28PM +0100, Arsen Arsenović wrote: >> > So the former d/.deps/file.Po which handled both d/dmd/common/file.d and >> > d/dmd/root/file.d in your case would be d/.deps/d-common-file.o.d and >> > d/.deps/

Re: [committed] testsuite, d: Fix failing pr110406.d test

2025-01-05 Thread Iain Buclaw
Excerpts from Rainer Orth's message of Januar 5, 2025 12:42 pm: > Hi Iain, > >> At some point during GCC 15 development, the compiler-generated code for >> D ModuleInfo support now gets transformed into the following on x86: >> >> _12 = (uint) &__stop_minfo; >> _13 = (uint) &__start_minfo;

[committed] d: Merge upstream dmd c11e1d1708, druntime e60bfd11bd, phobos 8729740e3

2025-01-05 Thread Iain Buclaw
Hi, This patch merges the D front-end with upstream dmd c11e1d1708. Synchronizing the compiler with the upstream release of v2.108.1. D front-end changes: - Import dmd v2.108.1. - Add experimental support for language editions, enabled by adding the UDA `@__edition_la

[committed] testsuite, d: Fix failing pr110406.d test

2025-01-05 Thread Iain Buclaw
Hi, At some point during GCC 15 development, the compiler-generated code for D ModuleInfo support now gets transformed into the following on x86: _12 = (uint) &__stop_minfo; _13 = (uint) &__start_minfo; _14 = (uint) &gdc.dso_slot; _15 = {1, _14, _13, _12}; gdc.dso_initialized

Re: [PATCH 02/52 v2] d: Replace use of LONG_DOUBLE_TYPE_SIZE

2024-06-04 Thread Iain Buclaw
Excerpts from Kewen.Lin's message of Juni 4, 2024 5:17 am: > Hi Iain, > > on 2024/6/3 22:39, Iain Buclaw wrote: >> Excerpts from Kewen.Lin's message of Juni 3, 2024 10:57 am: >>> Hi Iain, >>> >>> on 2024/6/3 16:40, Iain Buclaw wrote: >>&g

Re: [PATCH 02/52] d: Replace use of LONG_DOUBLE_TYPE_SIZE

2024-06-03 Thread Iain Buclaw
Excerpts from Kewen.Lin's message of Juni 3, 2024 10:57 am: > Hi Iain, > > on 2024/6/3 16:40, Iain Buclaw wrote: >> Excerpts from Kewen Lin's message of Juni 3, 2024 5:00 am: >>> Joseph pointed out "floating types should have their mode, >>> not a p

Re: [PATCH 02/52] d: Replace use of LONG_DOUBLE_TYPE_SIZE

2024-06-03 Thread Iain Buclaw
Excerpts from Kewen Lin's message of Juni 3, 2024 5:00 am: > Joseph pointed out "floating types should have their mode, > not a poorly defined precision value" in the discussion[1], > as he and Richi suggested, the existing macros > {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE will be replaced with a > hook mo

[committed] d: Fix ICE in build_deref, at d/d-codegen.cc:1650 [PR111650]

2024-04-19 Thread Iain Buclaw
Hi, This regression in the D front-end was found to be caused by in some cases the hidden closure parameter type being generated too early for nested functions. Better to update the type after the local closure/frame type has been completed. Bootstrapped and regression tested on x86_64-linux-gnu

[committed] d: Merge upstream dmd, druntime b65767825f, phobos 92dc5a4e9.

2024-04-06 Thread Iain Buclaw
Hi, This patch merges the D front-end and runtime library with upstream dmd b65767825f, and the standard library with phobos 92dc5a4e9. Synchronizing with the upstream release of v2.108.0. D front-end changes: - Import dmd v2.108.0. D runtime changes: - Import druntime v2.108.

Re: [PATCH] libphobos, Darwin: Enable libphobos for most Darwin.

2024-04-02 Thread Iain Buclaw
Excerpts from Iain Sandoe's message of April 2, 2024 1:51 pm: > I have been building and testing D/libphobos for some time and over > some GCC and OS releases. As discussed on IRC a while ago, I think > we're ready to enable this (it also avoids an annoying build fail at > stage 2 if one forgets t

[committed] d: Merge upstream dmd, druntime 855353a1d9

2024-03-17 Thread Iain Buclaw
Hi, This patch merges the D front-end and runtime library with upstream dmd 855353a1d9. D front-end changes: - Import dmd v2.108.0-rc.1. - Add support for Named Arguments for functions. - Hex strings now convert to integer arrays. D runtime changes: - Import dru

[committed] d: Fix -fpreview=in ICEs with forward referenced parameter [PR112285]

2024-03-10 Thread Iain Buclaw
Hi, This patch removes the early lowering of D AST types as GCC trees in Target::preferPassByRef, fixing both PR12285 and PR12290. The way that the target hook preferPassByRef is implemented, it relied on the GCC "back-end" tree type to determine whether or not to use `ref' ABI for D `in' paramet

Re: Frontend access to target features (was Re: [PATCH] libgccjit: Add ability to get CPU features)

2024-03-10 Thread Iain Buclaw
Excerpts from David Malcolm's message of März 5, 2024 4:09 pm: > On Thu, 2023-11-09 at 19:33 -0500, Antoni Boucher wrote: >> Hi. >> See answers below. >> >> On Thu, 2023-11-09 at 18:04 -0500, David Malcolm wrote: >> > On Thu, 2023-11-09 at 17:27 -0500, Antoni Boucher wrote: >> > > Hi. >> > > This

Re: [committed] d: Fix gdc -O2 -mavx generates misaligned vmovdqa instruction [PR114171]

2024-03-03 Thread Iain Buclaw
Excerpts from Andrew Pinski's message of März 3, 2024 11:49 pm: > On Sat, Mar 2, 2024 at 5:51 PM Iain Buclaw wrote: >> >> Hi, >> >> This patch fixes a wrong code issue in the D front-end where lowered >> struct comparisons would reinterpret fields with a d

[committed] d: Merge upstream dmd, druntime f8bae04558, phobos ba2ade9dec

2024-03-03 Thread Iain Buclaw
Hi, This patch merges the D front-end and runtime library with upstream dmd f8bae04558, and the standard library with phobos ba2ade9dec D front-end changes: - Import dmd v2.108.1-beta-1. D runtime changes: - Import druntime v2.108.1-beta-1. Phobos changes: - Import phobos v2.108.

Re: [committed] d: Fix gdc -O2 -mavx generates misaligned vmovdqa instruction [PR114171]

2024-03-03 Thread Iain Buclaw
Excerpts from Richard Biener's message of März 3, 2024 11:41 am: > > >> Am 03.03.2024 um 02:51 schrieb Iain Buclaw : >> >> Hi, >> >> This patch fixes a wrong code issue in the D front-end where lowered >> struct comparisons would reinter

[committed] d: Fix gdc -O2 -mavx generates misaligned vmovdqa instruction [PR114171]

2024-03-02 Thread Iain Buclaw
Hi, This patch fixes a wrong code issue in the D front-end where lowered struct comparisons would reinterpret fields with a different (usually bigger) alignment than the original. Use `build_aligned_type' to preserve the alignment when casting away for such comparisons. Bootstrapped and regressi

[committed][GCC13] d: Fix callee destructor call invalidates the live object [PR113758]

2024-03-02 Thread Iain Buclaw
Hi, This patch backports a fix to code generation when passing objects by invisible reference that have a defined cpctor or dtor. When generating the argument, check the isCalleeDestroyingArgs hook, and force a TARGET_EXPR to be created if true, so that a reference to the live object isn't passed

[committed][GCC13] d: Fix internal compiler error: in make_import, at d/imports.cc:48 [PR113125]

2024-03-02 Thread Iain Buclaw
Hi, This patch backports an ICE triggered in the D front-end. The cause of the ICE was that TYPE_DECLs were only being generated for structs with members, not opaque structs. Bootstrapped and regression tested on x86_64-linux-gnu/-m32, backported to releases/gcc-13, releases/gcc-12, and releases

[committed] d: Merge dmd, druntime ceff48bf7d, phobos dcbfbd43a

2024-02-25 Thread Iain Buclaw
Hi, This patch merges the D front-end and runtime library with upstream dmd ceff48bf7d, and the standard library with phobos dcbfbd43a. D front-end changes: - Import latest fixes from dmd v2.107.1-rc.1. D runtime changes: - Import latest fixes from druntime v2.107.1-rc.1.

Re: [PATCH v10 2/2] Add gcov MC/DC tests for GDC

2024-02-23 Thread Iain Buclaw
Excerpts from Jørgen Kvalsvik's message of Februar 23, 2024 12:18 pm: > This is a mostly straight port from the gcov-19.c tests from the C test > suite. The only notable differences from C to D are that D flips the > true/false outcomes for loop headers, and the D front end ties loop and > ternary

[committed] d: Add UTF BOM tests to gdc.dg testsuite

2024-02-19 Thread Iain Buclaw
Hi, This patch checks in a few combinations of UTF BOM/no-BOM tests to the gdc.dg testsuite. Some of these are part of the upstream DMD `gdc.test' testsuite, but they had been omitted because they get mangled by the lib/gdc-utils.exp helpers when parsing and staging the tests. Translate them over

Re: [PATCH] testsuite: gdc: Require ucn in gdc.test/runnable/mangle.d etc. [PR104739]

2024-02-14 Thread Iain Buclaw
Excerpts from Rainer Orth's message of Februar 14, 2024 11:51 am: > gdc.test/runnable/mangle.d and two other tests come out UNRESOLVED on > Solaris with the native assembler: > > UNRESOLVED: gdc.test/runnable/mangle.d compilation failed to produce > executable > UNRESOLVED: gdc.test/runnable/ma

[committed] libphobos: Bump soname version to 5 [PR113667]

2024-02-12 Thread Iain Buclaw
Hi, This patch bumps the soname version of libphobos. Each major release is not binary compatible with the previous. Bootstrapped and regression tested on x86_64-linux-gnu/-m32, committed to mainline. Regards, Iain. --- PR d/113667 libphobos/ChangeLog: * configure: Regenerate

[committed] d: Fix internal compiler error: in make_import, at d/imports.cc:48 [PR113125]

2024-02-12 Thread Iain Buclaw
Hi, This patch fixes an ICE triggered in the D front-end. The cause of the ICE was that TYPE_DECLs were only being generated for structs with members, not opaque structs. PR d/113125 Bootstrapped and regression tested on x86_64-linux-gnu/-m32, committed to mainline. Regards, Iain. ---

[committed] d: Fix callee destructor call invalidates the live object [PR113758]

2024-02-12 Thread Iain Buclaw
Hi, This patch fixes code generation problem with passing objects by invisible reference - because of a defined cpctor or dtor. When generating the argument, check the isCalleeDestroyingArgs hook, and force a TARGET_EXPR to be created if true, so that a reference to the live object isn't passed d

[committed] d: Merge dmd, druntime 11240a9663

2024-02-12 Thread Iain Buclaw
Hi, This patch merges the D front-end and core runtime library with upstream dmd 11240a9663. Included in the merge are the fix for PR113772, and new testsuite directives to enable fixing PR104739. D front-end changes: - Import latest fixes from dmd v2.107.0. D runtime changes:

[committed] d: Merge dmd, druntime a6f1083699, phobos 31dedd7da

2024-02-03 Thread Iain Buclaw
Hi, This patch merges the D front-end and runtime library with upstream dmd a6f1083699, and the standard library with phobos 31dedd7da. D front-end changes: - Import dmd v2.107.0. - Character postfixes can now also be used for integers of size two or four. D run-time c

[committed] d: Merge dmd. druntime e770945277, phobos 6d6e0b9b9

2024-02-03 Thread Iain Buclaw
Hi, This patch merges the D front-end and runtime library with upstream dmd e770945277, and the standard runtime library with phobos 6d6e0b9b9. Synchronizing with the upstream release candidate as of 2024-01-27. D front-end changes: - Import latest fixes from dmd v2.107.0-beta.1. - Hex

Re: [PATCH] testsuite, GDC: Update link flags [PR112861].

2024-01-28 Thread Iain Buclaw
Excerpts from Iain Sandoe's message of Januar 28, 2024 4:02 pm: > Tested on i686, x86_64, aarch64 Darwin, x86_64, aarch64 Linux, > OK for trunk? > thanks, > Iain > OK. Thanks again! Iain.

Re: [PATCH] testsuite, libphobos: Update link flags [PR112864].

2024-01-28 Thread Iain Buclaw
Excerpts from Iain Sandoe's message of Januar 28, 2024 4:03 pm: > Tested on i686, x86_64, aarch64 Darwin, x86_64, aarch64 Linux, > OK for trunk? > thanks, > Iain > Thanks Iain! OK. Seems reasonable to me. Iain.

Re: [PATCH v9 2/2] Add gcov MC/DC tests for GDC

2023-12-31 Thread Iain Buclaw
Excerpts from Jørgen Kvalsvik's message of Dezember 31, 2023 4:51 pm: > This is a mostly straight port from the gcov-19.c tests from the C test > suite. The only notable differences from C to D are that D flips the > true/false outcomes for loop headers, and the D front end ties loop and > ternary

Re: [committed] d: Merge upstream dmd, druntime 2bbf64907c, phobos b64bfbf91

2023-12-11 Thread Iain Buclaw
Excerpts from Iain Buclaw's message of Dezember 11, 2023 11:07 am: > Hi, > > This patch merges the D front-end and runtime library with upstream dmd > 2bbf64907c, and the standard library with phobos b64bfbf91. > > Synchronizing with the upstream release of v2.106.0. > ... > diff --git a/gcc/d

[committed] d: Merge upstream dmd, druntime 2bbf64907c, phobos b64bfbf91

2023-12-11 Thread Iain Buclaw
Hi, This patch merges the D front-end and runtime library with upstream dmd 2bbf64907c, and the standard library with phobos b64bfbf91. Synchronizing with the upstream release of v2.106.0. D front-end changes: - Import dmd v2.106.0. D runtime changes: - Import druntime v2.106.0. Phob

  1   2   3   4   5   6   7   8   9   10   >