[commited, gcc13] ipa: Compare jump functions in ICF (PR 113907)

2024-05-14 Thread Martin Jambor
-13 branch. Martin gcc/ChangeLog: 2024-05-14 Martin Jambor PR ipa/113907 * ipa-prop.h (ipa_jump_functions_equivalent_p): Declare. (values_equal_for_ipcp_p): Likewise. * ipa-prop.cc (ipa_agg_pass_through_jf_equivalent_p): New function

[PATCH] sra: Do not leave work for DSE (that it can sometimes not perform)

2024-05-03 Thread Martin Jambor
benefit, could it possibly be backported to gcc-14 branch even if it is not a regression (at least not in the last decade) in a few weeks? Thanks, Martin gcc/ChangeLog: 2024-04-18 Martin Jambor * tree-sra.cc (sra_modify_assign): Remove the original statement also when dealing

Re: [wwwdocs] Add znver5 to GCC 14 changes

2024-05-03 Thread Martin Jambor
Hi Gerald, On Fri, May 03 2024, Gerald Pfeifer wrote: > Hi Martin, > > On Thu, 2 May 2024, Martin Jambor wrote: >> + GCC now supports AMD CPUs based on the znver5 core via >> +-march=znver5. Based on ISA extensions enabled on >> +a znver4 core, the switch

[wwwdocs] Add znver5 to GCC 14 changes

2024-05-02 Thread Martin Jambor
Hello, based on input from AMD, I'd like to commit the following to the wwwdocs repo to point out new support for Zen 5 based AMD CPUs in GCC 14? Is it OK? Any suggestions, comments or questions? Thanks, Martin diff --git a/htdocs/gcc-14/changes.html b/htdocs/gcc-14/changes.html index

Re: [wwwdocs] Porting-to-14: Mention new pragma GCC Target behavior

2024-05-02 Thread Martin Jambor
Hi, On Wed, May 01 2024, Gerald Pfeifer wrote: > On Tue, 30 Apr 2024, Martin Jambor wrote: >> +Pragma GCC Target now affects preprocessor >> symbols > > Note the id: should be "gcc-target-pragma", though I even suggest to > simplify and say "target-pr

Re: [wwwdocs] Porting-to-14: Mention new pragma GCC Target behavior

2024-04-30 Thread Martin Jambor
Hi, On Thu, Apr 25 2024, Jakub Jelinek wrote: > On Thu, Apr 25, 2024 at 02:34:22PM +0200, Martin Jambor wrote: >> when looking at a package build issue with GCC 14, Michal Jireš noted a >> different behavior of pragma GCC Target. This snippet tries to describe >> the gist of

[wwwdocs] Porting-to-14: Mention new pragma GCC Target behavior

2024-04-25 Thread Martin Jambor
Hello, when looking at a package build issue with GCC 14, Michal Jireš noted a different behavior of pragma GCC Target. This snippet tries to describe the gist of the problem. I have left it in the C section even though it is not really C specific, but could not think of a good name for a new

Re: [PATCH] contrib/check-params-in-docs.py: Ignore target-specific params

2024-04-12 Thread Martin Jambor
Hi, On Fri, Apr 12 2024, Filip Kastl wrote: > On Thu 2024-04-11 20:51:55, Thomas Schwinge wrote: >> Hi! >> >> On 2024-04-11T19:52:51+0200, Martin Jambor wrote: >> > contrib/check-params-in-docs.py is a script that checks that all >> > options repo

[PATCH] contrib/check-params-in-docs.py: Ignore gcn-preferred-vectorization-factor

2024-04-11 Thread Martin Jambor
configured. This patch makes the script silently about this particular fact. I'll push the patch as obvious momentarily. Martin contrib/ChangeLog: 2024-04-11 Martin Jambor * check-params-in-docs.py (ignored): Add gcn-preferred-vectorization-factor. --- contrib/check-params

[wwwdocs, committed] Fix link to "Feature Test Macros" in "Porting to GCC 14" page

2024-04-10 Thread Martin Jambor
Hi, Michal Jireš found out that the link to Feature Test Macros on the Porting to GCC 14 page was broken, it misses a "/latest/" directory in the middle of the path. I'll commit the following as obvious. Thanks, Martin --- htdocs/gcc-14/porting_to.html | 2 +- 1 file changed, 1 insertion(+),

Re: [PATCH] ICF: Make ICF and SRA agree on padding

2024-04-08 Thread Martin Jambor
Hello, On Sun, Apr 07 2024, Xi Ruoyao wrote: > On Thu, 2024-04-04 at 23:19 +0200, Martin Jambor wrote: >> The patch has been approved by Honza in Bugzilla. (I hope.  He did write >> it looked reasonable.)  Together with the patch for PR 113907, it has >> passed bootstrap,

[PATCH] ipa: Force args obtined through pass-through maps to the expected type (PR 113964)

2024-04-05 Thread Martin Jambor
, the reporter has also run the testsuite with this patch on riscv64 and reported in Bugzilla there were no issues. OK for master and GCC 13? Thanks, Martin gcc/ChangeLog: 2024-04-04 Martin Jambor PR ipa/113964 * ipa-param-manipulation.cc (ipa_param_adjustments::modify_call

[PATCH] ICF: Make ICF and SRA agree on padding

2024-04-04 Thread Martin Jambor
Martin Jambor PR ipa/113359 * ipa-icf-gimple.h (func_checker): New members safe_for_total_scalarization_p, m_total_scalarization_limit_known_p and m_total_scalarization_limit. (func_checker::func_checker): Initialize new member variables. * ipa-icf

[PATCH] ipa: Compare jump functions in ICF (PR 113907)

2024-04-04 Thread Martin Jambor
. Martin gcc/ChangeLog: 2024-03-20 Martin Jambor PR ipa/113907 * ipa-prop.h (class ipa_vr): Declare new overload of a member function equal_p. (ipa_jump_functions_equivalent_p): Declare. * ipa-prop.cc (ipa_vr::equal_p): New function

Re: [PATCH] ipa: Avoid duplicate replacements in IPA-SRA transformation phase

2024-03-28 Thread Martin Jambor
Hello, and ping, please. (In my copy I have fixed the formatting issue spotted by Jakub.) Martin On Fri, Mar 15 2024, Martin Jambor wrote: > Hi, > > when the analysis part of IPA-SRA figures out that it would split out > a scalar part of an aggregate which is known by IPA-C

Re: [PATCH] tree-optimization/113727 - bogus SRA with BIT_FIELD_REF

2024-03-20 Thread Martin Jambor
Hello, On Tue, Mar 19 2024, Richard Biener wrote: > When SRA analyzes BIT_FIELD_REFs it handles writes and not byte > aligned reads differently from byte aligned reads. Instead of > trying to create replacements for the loaded portion the former > cases try to replace the base object while

[PATCH] ipa: Avoid duplicate replacements in IPA-SRA transformation phase

2024-03-15 Thread Martin Jambor
the source code to optimize for this unlikely case is worth it but if need be, it can of course be done. Bootstrapped and tested on x86_64-linux. OK for master and eventually also the gcc-13 branch? Thanks, Martin gcc/ChangeLog: 2024-03-15 Martin Jambor PR ipa/111571 * ipa

[PATCH] ipa: Fix C++ member ptr indirect inlining (PR 114254, PR 108802)

2024-03-08 Thread Martin Jambor
), I'm fine with pushing them to master now but I can also wait until the next stage 1. Thanks, Martin gcc/ChangeLog: 2024-03-06 Martin Jambor PR ipa/108802 PR ipa/114254 * ipa-prop.cc (ipa_get_stmt_member_ptr_load_param): Fix case looking at COMPONENT_REFs

Re: [PATCH] ipa: Avoid excessive removing of SSAs (PR 113757)

2024-03-07 Thread Martin Jambor
Hello, and ping please. Martin On Thu, Feb 08 2024, Martin Jambor wrote: > Hi, > > PR 113757 shows that the code which was meant to debug-reset and > remove SSAs defined by LHSs of calls redirected to > __builtin_unreachable can trigger also when speculative > devirtualizat

[PATCH] ipa: Create indirect call edges also for lambdas

2024-02-21 Thread Martin Jambor
for master even now? Thanks, Martin gcc/ChangeLog: 2024-02-20 Martin Jambor PR ipa/108802 * ipa-prop.cc (ipa_get_stmt_member_ptr_load_param): Also recognize loads from a pointer parameter. (ipa_analyze_indirect_call_uses): Likewise. gcc/testsuite/ChangeLog

[PATCH] ipa: Convert lattices from pure array to vector (PR 113476)

2024-02-19 Thread Martin Jambor
On Tue, Feb 13 2024, Martin Jambor wrote: > On Mon, Feb 12 2024, Jan Hubicka wrote: >>> Believe it or not, even though I have re-worked the internals of the >>> lattices completely, the array itself is older than my involvement with >>> GCC (or at least with ipa-

[PATCH] testsuite: Fix guality/ipa-sra-1.c to work with return IPA-VRP

2024-02-14 Thread Martin Jambor
nge for me to commit without approval which I will do later today. Thanks, Martin gcc/testsuite/ChangeLog: 2024-02-14 Martin Jambor * gcc.dg/guality/ipa-sra-1.c (get_val1): Move up in the file. (get_val2): Likewise. (bar): Do not return a constant. Extend xfail

Re: [PATCH] ipa: call destructors on lattices before freeing them (PR 113476)

2024-02-14 Thread Martin Jambor
::meet_with_1 on the preprocessed source >> (dwarf2out.i) attached to Bugzilla. The patch also passes bootstrap and >> LTO bootstrap and testing on x86_64-linux. >> >> OK for master? >> >> Thanks, >> >> Martin >> >> >&g

Re: [PATCH] ipa: call destructors on lattices before freeing them (PR 113476)

2024-02-13 Thread Martin Jambor
On Mon, Feb 12 2024, Jan Hubicka wrote: >> Believe it or not, even though I have re-worked the internals of the >> lattices completely, the array itself is older than my involvement with >> GCC (or at least with ipa-cp.c ;-). >> >> So it being an array and not a vector is historical coincidence,

Re: [PATCH] ipa: call destructors on lattices before freeing them (PR 113476)

2024-02-12 Thread Martin Jambor
t_with_1 on the preprocessed source >> (dwarf2out.i) attached to Bugzilla. The patch also passes bootstrap and >> LTO bootstrap and testing on x86_64-linux. >> >> OK for master? >> >> Thanks, >> >> Martin >> >> >> gcc/ChangeLog:

[PATCH] ipa: call destructors on lattices before freeing them (PR 113476)

2024-02-12 Thread Martin Jambor
, Martin gcc/ChangeLog: 2024-02-09 Martin Jambor PR tree-optimization/113476 * ipa-prop.h (ipa_node_params::~ipa_node_params): Moved... * ipa-cp.cc (ipa_node_params::~ipa_node_params): ...here. Added destruction of lattices. --- gcc/ipa-cp.cc | 17

Re: [RFC] GCC Security policy

2024-02-12 Thread Martin Jambor
Hi, On Fri, Feb 09 2024, Siddhesh Poyarekar wrote: > On 2024-02-09 10:38, Martin Jambor wrote: >> If anyone is interested in scoping this and then mentoring this as a >> Google Summer of Code project this year then now is the right time to >> speak up! > > I can help

Re: [RFC] GCC Security policy

2024-02-09 Thread Martin Jambor
Hi, On Tue, Aug 08 2023, Richard Biener via Gcc-patches wrote: > On Tue, Aug 8, 2023 at 2:33 PM Siddhesh Poyarekar wrote: >> >> On 2023-08-08 04:16, Richard Biener wrote: >> > On Mon, Aug 7, 2023 at 7:30 PM David Edelsohn via Gcc-patches >> > wrote: >> >> >> >> FOSS Best Practices recommends

[PATCH] ipa: Avoid excessive removing of SSAs (PR 113757)

2024-02-08 Thread Martin Jambor
have also LTO-bootstrapped and LTO-profilebootstrapped the patch on x86_64-linux. OK for master? Thanks, Martin gcc/ChangeLog: 2024-02-07 Martin Jambor PR ipa/113757 * tree-inline.cc (redirect_all_calls): Remove code adding SSAs to id->killed_new_ssa_names.

Re: [PATCH] ipa-cp: Fix check for exceeding param_ipa_cp_value_list_size (PR 113490)

2024-01-24 Thread Martin Jambor
ractice the limit >> is of course very likely to be the same, but I fixed this aspect of >> the condition too. I briefly audited all other uses of opt_for_fn in >> ipa-cp.cc and all the others looked OK. >> >> Bootstrapped and tested on x86_64-linux. OK for maste

[PATCH] ipa-cp: Fix check for exceeding param_ipa_cp_value_list_size (PR 113490)

2024-01-20 Thread Martin Jambor
of opt_for_fn in ipa-cp.cc and all the others looked OK. Bootstrapped and tested on x86_64-linux. OK for master? Thanks, Martin gcc/ChangeLog: 2024-01-19 Martin Jambor PR ipa/113490 * ipa-cp.cc (ipcp_lattice::add_value): Bail out if value count is equal or greater

[PATCH] sra: Disqualify bases of operands of asm gotos

2024-01-17 Thread Martin Jambor
gotos, we need to punt. Bootstrapped and tested on x86_64-linux, OK for master? It will need some tweaking for release branches, is it in principle OK for them too (after testing)? Thanks, Martin gcc/ChangeLog: 2024-01-17 Martin Jambor PR tree-optimization/110422 * tree

Re: [PATCH] sra: Partial fix for BITINT_TYPEs [PR113120]

2024-01-17 Thread Martin Jambor
Hi, On Wed, Jan 10 2024, Jakub Jelinek wrote: > Hi! > > As changed in other parts of the compiler, using > build_nonstandard_integer_type is not appropriate for arbitrary precisions, > especially if the precision comes from a BITINT_TYPE or something based on > that, build_nonstandard_integer_type

[PATCH] ipa: Self-DCE of uses of removed call LHSs (PR 108007)

2024-01-16 Thread Martin Jambor
-bootstrap and testing on x86_64-linux, bootstrap, LTO-bootstrap and testing on ppc64le-linux and bootstrap and LTO-bootstrap on Aarch64, testsuite there is still running, OK if it passes? Thanks Martin gcc/ChangeLog: 2024-01-12 Martin Jambor PR ipa/108007 PR ipa/112616

Re: [wwwdocs] gcc-14/changes.html: OpenMP - improve wording

2024-01-09 Thread Martin Jambor
Hi Tobias, On Mon, Jan 08 2024, Tobias Burnus wrote: > The attached patch there was no patch attached to your message. Martin > does a tiny updated to the OpenMP features (AMD GCN > now also has an optimized memcpy_rect not only nvptx), but the main > change is some shifting around to make

Re: [PATCH] tree-optimization/111807 - ICE in verify_sra_access_forest

2023-12-13 Thread Martin Jambor
a queries (0.129265 per modref query) 1341403 base compares (0.033408 per modref query) PTA query stats: pt_solution_includes: 36784449 disambiguations, 46141210 queries pt_solutions_intersect: 4519320 disambiguations, 17082083 queries gcc/ChangeLog: 2023-12-13 Martin Jambor PR

[PATCH] SRA: Force gimple operand in an additional corner case (PR 112822)

2023-12-12 Thread Martin Jambor
. Despite the above, is the patch OK for master? Thanks, Martin gcc/ChangeLog: 2023-12-12 Martin Jambor PR tree-optimization/112822 * tree-sra.cc (load_assign_lhs_subreplacements): Invoke force_gimple_operand_gsi also when LHS has partial stores and RHS

Re: [PATCH] tree-sra: Avoid returns of references to SRA candidates

2023-11-29 Thread Martin Jambor
Hi, On Tue, Nov 28 2023, Jan Hubicka wrote: >> On Tue, 28 Nov 2023, Martin Jambor wrote: >> >> > On Tue, Nov 28 2023, Richard Biener wrote: >> > > On Mon, 27 Nov 2023, Martin Jambor wrote: >> > > >> > >> Hi, >> > >>

Re: [PATCH] tree-sra: Avoid returns of references to SRA candidates

2023-11-28 Thread Martin Jambor
On Tue, Nov 28 2023, Richard Biener wrote: > On Mon, 27 Nov 2023, Martin Jambor wrote: > >> Hi, >> >> The enhancement to address PR 109849 contained an importsnt thinko, >> and that any reference that is passed to a function and does not >> escape, must also no

[PATCH] tree-sra: Avoid returns of references to SRA candidates

2023-11-27 Thread Martin Jambor
: 2023-11-27 Martin Jambor PR tree-optimization/112711 PR tree-optimization/112721 * tree-sra.cc (build_access_from_call_arg): New parameter CAN_BE_RETURNED, disqualify any candidate passed by reference if it is true. Adjust leading comment

Re: [PATCH] sra: SRA of non-escaped aggregates passed by reference to calls

2023-11-24 Thread Martin Jambor
Hello, thanks a lot for your review. On Fri, Nov 17 2023, Richard Biener wrote: > On Thu, 16 Nov 2023, Martin Jambor wrote: > >> Hello, >> >> PR109849 shows that a loop that heavily pushes and pops from a stack >> implemented by a C++ std::vec results in slow code

Re: libstdc++: Speed up push_back

2023-11-24 Thread Martin Jambor
Hello, On Thu, Nov 23 2023, Jonathan Wakely wrote: > On Thu, 23 Nov 2023 at 15:34, Jan Hubicka wrote: >> [...] >> >> I also wonder, if default operator new and malloc can be handled as not >> reading/modifying anything visible to the user code. > > No, there's no way to know if the default

[PATCH] Bump LTO_minor_version

2023-11-20 Thread Martin Jambor
4fcf9 has changed LTO format and therefore we should bump the minor version of the GCC 13 LTO format. gcc/ChangeLog: 2023-11-20 Martin Jambor * lto-streamer.h (LTO_minor_version): Bump. --- gcc/lto-streamer.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/

Re: Propagate value ranges of return values

2023-11-20 Thread Martin Jambor
Hi, thanks for working on this. On Sun, Nov 19 2023, Jan Hubicka wrote: > Hi, > this is updated version which also adds testuiste compensation > I lost earlier while maintaining the patch in my testing tree. > There are quite few testcases that use constant return values to hide > something from

[PATCH] sra: SRA of non-escaped aggregates passed by reference to calls

2023-11-16 Thread Martin Jambor
on these two architectures but as I'm sending this). OK for master? Thanks, Martin gcc/ChangeLog: 2023-11-16 Martin Jambor PR middle-end/109849 * tree-sra.cc (passed_by_ref_in_call): New. (sra_initialize): Allocate passed_by_ref_in_call. (sra_deinitialize

[PATCH] gcc/configure: Regenerate

2023-11-07 Thread Martin Jambor
On Mon, Nov 06 2023, Martin Jambor wrote: > [...] > > I'm not sure what that means, whether a wrong version of > autoconf/automake was used (though when I accidentally tried that, it > has always complained loudly) or if some environment difference can > cause this. Perha

[PATCH] Fix configure script comments(!?!) (Was: Re: [PATCH] genemit: Split insn-emit.cc into ten files)

2023-11-06 Thread Martin Jambor
Hello, On Thu, Oct 12 2023, Robin Dapp wrote: > [...] > gcc/ChangeLog: > > PR bootstrap/84402 > PR target/111600 > > * Makefile.in: Handle split insn-emit.cc. > * configure: Regenerate. > * configure.ac: Add --with-insnemit-partitions. > * genemit.cc

[PATCH] Fortran: Fix generate_error library function fnspec

2023-11-03 Thread Martin Jambor
and tested on x86_64-linux. OK for master? 2023-11-02 Martin Jambor * trans-decl.cc (gfc_build_builtin_function_decls): Fix fnspec of generate_error. --- gcc/fortran/trans-decl.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gcc/fortran/trans-decl.cc b

Re: [PATCH 2/3] ipa: Prune any IPA-CP aggregate constants known by modref to be killed (111157)

2023-10-30 Thread Martin Jambor
Hello, On Thu, Oct 05 2023, Jan Hubicka wrote: >> gcc/ChangeLog: >> >> 2023-09-19 Martin Jambor >> >> PR ipa/57 >> * ipa-prop.h (struct ipa_argagg_value): Newf flag killed. >> * ipa-modref.cc (ipcp_argagg_and_kill_overlap_p): New

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

2023-10-30 Thread Martin Jambor
Hello Iain, On Tue, Aug 15 2023, FX Coudert via Gcc-patches wrote: > [...] > From e1cf04cadb9fa065fb3f7d6bccf9ed6f1e9e3fc1 Mon Sep 17 00:00:00 2001 > From: Iain Sandoe > Date: Sun, 28 Mar 2021 14:48:17 +0100 > Subject: [PATCH 2/4] Darwin: Allow for configuring Darwin to use embedded >

[PATCH 2/3] ipa: Prune any IPA-CP aggregate constants known by modref to be killed (111157)

2023-10-05 Thread Martin Jambor
tch It does not try to look up anything in the load lists, this will be done as a follow-up in order to ease review. gcc/ChangeLog: 2023-09-19 Martin Jambor PR ipa/57 * ipa-prop.h (struct ipa_argagg_value): Newf flag killed. * ipa-modref.cc (ipcp_argagg_and_kill_over

[PATCH 3/3] ipa: Limit pruning of IPA-CP aggregate constants if there are loads

2023-10-05 Thread Martin Jambor
103669 (to get a clobber/kill) in a way that ipa-modref can still track things. Therefore I am not sure if we actually want this patch. gcc/ChangeLog: 2023-10-04 Martin Jambor * ipa-modref.cc (ipcp_argagg_and_access_must_overlap_p): New function

[PATCH 1/3] ipa-cp: Templatize filtering of m_agg_values

2023-10-05 Thread Martin Jambor
gcc.dg/ipa/pr108959.c. gcc/ChangeLog: 2023-09-13 Martin Jambor PR ipa/57 * ipa-prop.h (ipcp_transformation): New member function template remove_argaggs_if. * ipa-sra.cc (zap_useless_ipcp_results): Use remove_argaggs_if to filter aggreagate constants

[PATCH] Revert "ipa: Self-DCE of uses of removed call LHSs (PR 108007)"

2023-10-05 Thread Martin Jambor
Hello, I am going to commit the following patch to fix PR 111688 (bootstrap on ppc64le broken) and will re-fix 108007 (issues with IPA-SRA when user explicitely turns off DCE) when I figure out what's going wrong. Sorry for the breakage, Martin [PATCH] Revert "ipa: Self-DCE of uses of

[committed] ipa-modref: Fix dumping

2023-10-03 Thread Martin Jambor
as obvious after including it in a bootstrap and testing on an x86_64-linux. Thanks, Martin gcc/ChangeLog: 2023-09-21 Martin Jambor * ipa-modref.h (modref_summary::dump): Make const. * ipa-modref.cc (modref_summary::dump): Likewise. (dump_lto_records): Dump to out instead

Re: [PATCH] ipa: Self-DCE of uses of removed call LHSs (PR 108007)

2023-10-03 Thread Martin Jambor
es of SSAs does not bring them up. During tree-inline they are handled especially at the end, I assume in order to make sure that relative ordering of UIDs are the same with and without debug info. This means that during tree-inline we need to make a hash of killed SSAs, that we already have in

[PATCH] contrib/mklog.py: Fix issues reported by flake8

2023-10-03 Thread Martin Jambor
, Martin contrib/ChangeLog: 2023-10-03 Martin Jambor * mklog.py (skip_line_in_changelog): Compare to None using is instead of ==, add an extra newline after the function. --- contrib/mklog.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/contrib/mklog.py b

Re: [PATCH] ipa: Self-DCE of uses of removed call LHSs (PR 108007)

2023-09-19 Thread Martin Jambor
Hello, and ping. Thanks, Martin On Fri, Sep 01 2023, Martin Jambor wrote: > Hello > > and ping. > > Thanks, > > Martin > > > On Fri, May 12 2023, Martin Jambor wrote: >> Hi, >> >> PR 108007 is another manifestation where we rely on DCE to clean

Re: [PATCH] ipa-sra: Allow IPA-SRA in presence of returns which will be removed

2023-09-18 Thread Martin Jambor
Hello, and ping. Thanks, Martin On Fri, Sep 01 2023, Martin Jambor wrote: > Hello > > and ping. > > Thanks, > > Martin > > > On Fri, Aug 18 2023, Martin Jambor wrote: >> Hi, >> >> testing on 32bit arm revealed that even the simplest case of P

[PATCH] math-opts: Add dbgcounter for FMA formation

2023-09-07 Thread Martin Jambor
would not also make the code unnecessarily more complicated. Bootstrapped and tested on x86_64-linux. OK for master? Thanks, Martin gcc/ChangeLog: 2023-09-06 Martin Jambor * dbgcnt.def (form_fma): New. * tree-ssa-math-opts.cc: Include dbgcnt.h

Re: [PATCH] ipa: Self-DCE of uses of removed call LHSs (PR 108007)

2023-09-01 Thread Martin Jambor
Hello and ping. Thanks, Martin On Fri, May 12 2023, Martin Jambor wrote: > Hi, > > PR 108007 is another manifestation where we rely on DCE to clean-up > after IPA-SRA and if the user explicitely switches DCE off, IPA-SRA > can leave behind statements which are fed unini

Re: [PATCH] ipa-sra: Allow IPA-SRA in presence of returns which will be removed

2023-09-01 Thread Martin Jambor
Hello and ping. Thanks, Martin On Fri, Aug 18 2023, Martin Jambor wrote: > Hi, > > testing on 32bit arm revealed that even the simplest case of PR 110378 > was still not resolved there because destructors were returning this > pointer. Needless to say, the return value of th

[PATCH] ipa-sra: Allow IPA-SRA in presence of returns which will be removed

2023-08-18 Thread Martin Jambor
in such cases. Bootstrapped, LTO-bootstrapped and tested on x86_64-linux. OK for master? Thanks, Martin gcc/ChangeLog: 2023-08-18 Martin Jambor PR ipa/110378 * ipa-param-manipulation.cc (ipa_param_body_adjustments::mark_dead_statements): Verify that any return

Re: [PATCH] Fortran: Avoid accessing gfc_charlen when not looking at BT_CHARACTER (PR 110677)

2023-08-15 Thread Martin Jambor
Hello, On Mon, Aug 14 2023, Harald Anlauf via Gcc-patches wrote: > Hi Martin, > > Am 14.08.23 um 19:39 schrieb Martin Jambor: >> Hello, >> >> this patch addresses an issue uncovered by the undefined behavior >> sanitizer. In function resolve_structure_cons

[PATCH] Fortran: Avoid accessing gfc_charlen when not looking at BT_CHARACTER (PR 110677)

2023-08-14 Thread Martin Jambor
unwanted because comp->ts.type in those cases is BT_CLASS and not BT_CHARACTER. This patch simply adds a check to make sure it is only accessed in those cases. I have verified that the UPBSAN failure goes away with this patch, it also passes bootstrap and testing on x86_64-linux. OK for master? T

Re: [PATCH 2/2] ipa-cp: Feed results of IPA-CP into value numbering

2023-08-13 Thread Martin Jambor
Hello Richi, it took me quite time to get back to this but it might have actually helped because it forced me to re-read the code around and in turn simplify the patch. On Mon, Jun 12 2023, Richard Biener wrote: > On Fri, 9 Jun 2023, Martin Jambor wrote: > [...] >> @@ -23

Re: [PATCH] ipa-sra: Don't consider CLOBBERS as writes preventing splitting

2023-08-11 Thread Martin Jambor
Hello, On Fri, Aug 11 2023, Christophe Lyon wrote: > Hi Martin, > > > On Fri, 4 Aug 2023 at 18:26, Martin Jambor wrote: > >> Hello, >> >> On Wed, Aug 02 2023, Richard Biener wrote: >> > On Mon, Jul 31, 2023 at 7:05 PM Martin Jambor wrote: >> >&

Re: [PATCH] ipa-sra: Don't consider CLOBBERS as writes preventing splitting

2023-08-04 Thread Martin Jambor
Hello, On Wed, Aug 02 2023, Richard Biener wrote: > On Mon, Jul 31, 2023 at 7:05 PM Martin Jambor wrote: >> >> Hi, >> >> when IPA-SRA detects whether a parameter passed by reference is >> written to, it does not special case CLOBBERs which means it often >&

[PATCH] ipa-sra: Don't consider CLOBBERS as writes preventing splitting

2023-07-31 Thread Martin Jambor
testcases in the PR need surprisingly more effort but the simple one can be fixed now easily by this patch and I'll work on the others incrementally. Bootstrapped and currently undergoing testsuite run on x86_64-linux. OK if it passes too? Thanks, Martin gcc/ChangeLog: 2023-07-31 Martin Jambor

Re: [PATCH] Read global value/mask in IPA.

2023-07-31 Thread Martin Jambor
Hello, On Tue, Jul 18 2023, Aldy Hernandez wrote: > On 7/17/23 15:14, Aldy Hernandez wrote: >> Instead of reading the known zero bits in IPA, read the value/mask >> pair which is available. >> >> There is a slight change of behavior here. I have removed the check >> for SSA_NAME, as the ranger

Re: [PATCH] mklog: Add --append option to auto add generate ChangeLog to patch file

2023-07-21 Thread Martin Jambor
Hello Lehua, On Fri, Jul 21 2023, Lehua Ding wrote: > Hi Martin, > > > By the way, is there a standard format required for these Python files? Generally, our Python coding conventions are at https://gcc.gnu.org/codingconventions.html#python > I see that other Python files have similar format

Re: [PATCH] mklog: Add --append option to auto add generate ChangeLog to patch file

2023-07-21 Thread Martin Jambor
Hello Lehua, On Fri, Jul 21 2023, Lehua Ding wrote: > Hi Martin, > > > this patch caused flake8 to complain about contrib/mklog.py: > > $ flake8 contrib/mklog.py > contrib/mklog.py:377:80: E501 line too long (85 79 characters) > contrib/mklog.py:388:26: E127 continuation line over-indented

Re: [PATCH] mklog: Add --append option to auto add generate ChangeLog to patch file

2023-07-21 Thread Martin Jambor
Hello Lehua, On Wed, Jul 12 2023, Lehua Ding wrote: > Hi, > > This tiny patch add --append option to mklog.py that support add generated > ChangeLog to the corresponding patch file. With this option there is no need > to manually copy the generated ChangeLog to the patch file. e.g.: > > Run

[committed] Document new analyzer parameters

2023-07-20 Thread Martin Jambor
Hi, This patch documents the analyzer parameters introduced in r14-2029-g0e466e978c7286 also in gcc/doc/invoke.texi. Committed as obvious after testing with make pdf and make info and eyeballing the result. Thanks, Martin 2023-07-20 Martin Jambor * doc/invoke.texi (analyzer-text

[committed] Restore bootstrap by removing unused variable in tree-ssa-loop-ivcanon.cc

2023-07-17 Thread Martin Jambor
/ChangeLog: 2023-07-17 Martin Jambor * tree-ssa-loop-ivcanon.cc (try_peel_loop): Remove unused variable entry_count. --- gcc/tree-ssa-loop-ivcanon.cc | 1 - 1 file changed, 1 deletion(-) diff --git a/gcc/tree-ssa-loop-ivcanon.cc b/gcc/tree-ssa-loop-ivcanon.cc index bdb738af7a8

Re: [PATCH] Export value/mask known bits from IPA.

2023-07-17 Thread Martin Jambor
Hi Aldy, On Mon, Jul 17 2023, Aldy Hernandez wrote: > Currently IPA throws away the known 1 bits because VRP and irange have > traditionally only had a way of tracking known 0s (set_nonzero_bits). > With the ability to keep all the known bits in the irange, we can now > save this between passes.

Re: [PATCH 3/3] analyzer: add text-art visualizations of out-of-bounds accesses [PR106626]

2023-06-30 Thread Martin Jambor
Hi David, On Wed, May 31 2023, David Malcolm via Gcc-patches wrote: > This patch extends -Wanalyzer-out-of-bounds so that, where possible, it > will emit a text art diagram visualizing the spatial relationship between [...] > > gcc/ChangeLog: > PR analyzer/106626 > * Makefile.in

[committed] Regenrate lto-plugin/Makefile.in

2023-06-30 Thread Martin Jambor
Hi, On Thu, Jun 29 2023, Marek Polacek wrote: > On Thu, Jun 29, 2023 at 05:58:22PM +0200, Martin Jambor wrote: [...] >> >> Unfortunately I won't have time to actually look at this in the next 2-3 >> weeks, so I am inclined to just trust the verification script (whic

Re: [PATCH] configure: Implement --enable-host-bind-now

2023-06-29 Thread Martin Jambor
Hi, On Tue, Jun 27 2023, Marek Polacek wrote: > On Tue, Jun 27, 2023 at 01:39:16PM +0200, Martin Jambor wrote: >> Hello, >> >> On Tue, May 16 2023, Marek Polacek via Gcc-patches wrote: >> > As promised in the --enable-host-pie patch, this patch adds another >&g

Re: Enable ranger for ipa-prop

2023-06-27 Thread Martin Jambor
On Tue, Jun 27 2023, Jan Hubicka wrote: > Hi, > as shown in the testcase (which would eventually be useful for > optimizing std::vector's push_back), ipa-prop can use context dependent ranger > queries for better value range info. > > Bootstrapped/regtested x86_64-linux, OK? > > Honza > >

Re: [PATCH] configure: Implement --enable-host-bind-now

2023-06-27 Thread Martin Jambor
Hello, On Tue, May 16 2023, Marek Polacek via Gcc-patches wrote: > As promised in the --enable-host-pie patch, this patch adds another > configure option, --enable-host-bind-now, which adds -z now when linking > the compiler executables in order to extend hardening. BIND_NOW with RELRO > allows

Re: [PATCH] Convert remaining uses of value_range in ipa-*.cc to Value_Range.

2023-06-26 Thread Martin Jambor
Hi, On Mon, May 22 2023, Aldy Hernandez via Gcc-patches wrote: > Minor cleanups to get rid of value_range in IPA. There's only one left, > but it's in the switch code which is integer specific. > > OK? With the same request that... > > gcc/ChangeLog: > > * ipa-cp.cc

Re: [PATCH] Implement ipa_vr hashing.

2023-06-26 Thread Martin Jambor
Hi, On Mon, May 22 2023, Aldy Hernandez via Gcc-patches wrote: > Implement hashing for ipa_vr. When all is said and done, all these > patches incurr a 7.64% slowdown for ipa-cp, with is entirely covered by > the similar 7% increase in this area last week. So we get type agnostic > ranges with

Re: [PATCH] Convert ipa_jump_func to use ipa_vr instead of a value_range.

2023-06-26 Thread Martin Jambor
Hi, On Mon, May 22 2023, Aldy Hernandez via Gcc-patches wrote: > This patch converts the ipa_jump_func code to use the type agnostic > ipa_vr suitable for GC instead of value_range which is integer specific. > > I've disabled the range cacheing to simplify the patch for review, but > it is

[PATCH] ipa-sra: Disable candidates with no known callers (PR 110276)

2023-06-16 Thread Martin Jambor
caller into the early checks and makes the node a non-candidate for any transformation if it does not. Bootstrapped and tested on x86_64-linux, LTO bootstrap is still underway. OK if it passes too? Thanks, Martin gcc/ChangeLog: 2023-06-16 Martin Jambor PR ipa/110276 * ipa

[PATCH] Regenerate some autotools generated files (Was: Re: [PATCH v3] configure: Implement --enable-host-pie)

2023-06-16 Thread Martin Jambor
On Fri, Jun 16 2023, Marek Polacek wrote: > On Fri, Jun 16, 2023 at 12:26:23PM +0200, Martin Jambor wrote: >> Hello, >> >> On Thu, Jun 15 2023, Marek Polacek via Gcc-patches wrote: >> > On Mon, Jun 05, 2023 at 09:06:43PM -0600, Jeff Law wrote: >> >> &

Re: [PATCH v3] configure: Implement --enable-host-pie

2023-06-16 Thread Martin Jambor
Hello, On Thu, Jun 15 2023, Marek Polacek via Gcc-patches wrote: > On Mon, Jun 05, 2023 at 09:06:43PM -0600, Jeff Law wrote: >> >> >> On 6/5/23 10:18, Marek Polacek via Gcc-patches wrote: >> > Ping. Anyone have any further comments? >> Given this was approved before, but got reverted due to

Re: [PATCH] ipa: Self-DCE of uses of removed call LHSs (PR 108007)

2023-06-13 Thread Martin Jambor
Ping. Thanks, Martin On Fri, May 12 2023, Martin Jambor wrote: > Hi, > > PR 108007 is another manifestation where we rely on DCE to clean-up > after IPA-SRA and if the user explicitely switches DCE off, IPA-SRA > can leave behind statements which are fed uninitialized values a

Re: [PATCH] Convert ipcp_vr_lattice to type agnostic framework.

2023-06-10 Thread Martin Jambor
Hi, thanks for dealing with my requests. On Wed, Jun 07 2023, Aldy Hernandez wrote: > On 5/26/23 18:17, Martin Jambor wrote: >> Hello, >> >> On Mon, May 22 2023, Aldy Hernandez wrote: >>> I've adjusted the patch with some minor cleanups that came up when I >&

Re: [PATCH 2/2] ipa-cp: Feed results of IPA-CP into value numbering

2023-06-09 Thread Martin Jambor
Hi, thanks for looking at this. On Fri, Jun 02 2023, Richard Biener wrote: > On Mon, 29 May 2023, Martin Jambor wrote: > [...] >> diff --git a/gcc/tree-ssa-sccvn.cc b/gcc/tree-ssa-sccvn.cc >> index 27c84e78fcf..33215b5fc82 100644 >> --- a/gcc/tree-ssa-sccvn.cc >&g

Re: [RFC] light expander sra for parameters and returns

2023-06-01 Thread Martin Jambor
Hi, On Tue, May 30 2023, Richard Biener wrote: > On Mon, 29 May 2023, Jiufu Guo wrote: > >> Hi, >> >> Previously, I was investigating some struct parameters and returns related >> PRs 69143/65421/108073. >> >> Investigating the issues case by case, and drafting patches for each of >> them one

Re: [PATCH 1/2] ipa-cp: Avoid long linear searches through DECL_ARGUMENTS

2023-05-31 Thread Martin Jambor
Hello, On Wed, May 31 2023, Richard Biener wrote: > On Tue, May 30, 2023 at 4:21 PM Jan Hubicka wrote: >> >> > On Mon, May 29, 2023 at 6:20 PM Martin Jambor wrote: >> > > >> > > Hi, >> > > >> > > there have been concerns

[PATCH 2/2] ipa-cp: Feed results of IPA-CP into value numbering

2023-05-29 Thread Martin Jambor
. Bootstrapped, LTO-bootstrapped and LTO-profiledbootstrapped and tested on x86_64-linux. OK for trunk? Thanks, Martin gcc/ChangeLog: 2023-05-26 Martin Jambor PR ipa/68930 PR ipa/92497 * ipa-prop.h (ipcp_get_aggregate_const): Declare. * ipa-prop.cc

[PATCH 1/2] ipa-cp: Avoid long linear searches through DECL_ARGUMENTS

2023-05-29 Thread Martin Jambor
excercised. OK for master? Thanks, Martin gcc/ChangeLog: 2023-05-26 Martin Jambor * ipa-prop.h (struct ipcp_transformation): Rearrange members according to C++ class coding convention, add m_tree_to_idx, get_param_index and maybe_create_parm_idx_map. * ipa-cp.cc

Re: [PATCH] Implement ipa_vr hashing.

2023-05-29 Thread Martin Jambor
Hi, On Mon, May 22 2023, Aldy Hernandez via Gcc-patches wrote: > Implement hashing for ipa_vr. When all is said and done, all these > patches incurr a 7.64% slowdown for ipa-cp, with is entirely covered by > the similar 7% increase in this area last week. So we get type agnostic > ranges with

[COMMITTED] MAINTAINERS file: Replace spaces with tabs

2023-05-29 Thread Martin Jambor
Hi, This change, separating Benjamin's name and email address with tabs rather than spaces, makes contrib/check-MAINTAINERS.py script happy about our MAINTAINERS file again, so I tool the liberty of committing this as obvious. Thanks, Martin ChangeLog: 2023-05-29 Martin Jambor

Re: [PATCH] Convert ipcp_vr_lattice to type agnostic framework.

2023-05-26 Thread Martin Jambor
Hello, On Mon, May 22 2023, Aldy Hernandez wrote: > I've adjusted the patch with some minor cleanups that came up when I > implemented the rest of the IPA revamp. > > Rested. OK? > > On Wed, May 17, 2023 at 4:31 PM Aldy Hernandez wrote: >> >> This converts the lattice to store ranges in

Re: [PATCH] Provide an API for ipa_vr.

2023-05-24 Thread Martin Jambor
Hello, On Wed, May 17 2023, Aldy Hernandez wrote: > This patch encapsulates the ipa_vr internals into an API. It also > makes it type agnostic, in preparation for upcoming changes to IPA. > > Interestingly, there's a 0.44% improvement to IPA-cp, which I'm sure > we'll soak up with future changes

Re: [committed] libstdc++: Disable cacheline alignment for DJGPP [PR109741]

2023-05-17 Thread Martin Jambor
Hello, On Tue, May 16 2023, Jonathan Wakely via Gcc-patches wrote: > Tested powerpc64le-linux. Builds OK on djgpp too. > > Pushed to trunk. > > -- >8 -- > > DJGPP (and maybe other targets) uses MAX_OFILE_ALIGNMENT=16 which means > that globals (and static objects) can't have alignment greater

Re: [PATCH 1/2] c++: potentiality of templated memfn call [PR109480]

2023-05-12 Thread Martin Jambor
Hello Patrick, On Wed, May 03 2023, Patrick Palka via Gcc-patches wrote: > [...] > > Subject: [PATCH] c++: potentiality of templated memfn call [PR109480] > > Here we're incorrectly deeming the templated call a.g() inside b's > initializer as potentially constant, despite g being non-constexpr, >

  1   2   3   4   5   6   7   8   9   10   >