]> git.ipfire.org Git - thirdparty/gcc.git/log
thirdparty/gcc.git
11 months agofixed typo Thesis
kubaneko [Tue, 9 May 2023 20:10:59 +0000 (20:10 +0000)] 
fixed typo

11 months agoAdd parameters to control histogram profiling and peeling
Honza [Tue, 9 May 2023 14:26:00 +0000 (16:26 +0200)] 
Add parameters to control histogram profiling and peeling

11 months agoMinor heuristics improvements
Honza [Sun, 7 May 2023 19:47:26 +0000 (21:47 +0200)] 
Minor heuristics improvements

11 months agoDo not use params to determine histogram sizes
Honza [Sun, 7 May 2023 19:45:42 +0000 (21:45 +0200)] 
Do not use params to determine histogram sizes

11 months agoDo not use params for determining histogram sizes
Honza [Sun, 7 May 2023 19:44:46 +0000 (21:44 +0200)] 
Do not use params for determining histogram sizes

11 months agoFix reading of histograms.
Honza [Sun, 7 May 2023 19:44:07 +0000 (21:44 +0200)] 
Fix reading of histograms.

11 months agoFix bug in identifying number of exits of the loop.
Honza [Sun, 7 May 2023 19:42:59 +0000 (21:42 +0200)] 
Fix bug in identifying number of exits of the loop.

11 months agoBetter -fopt-info
Honza [Sun, 7 May 2023 15:58:54 +0000 (17:58 +0200)] 
Better -fopt-info

11 months agoconstrained the parameters
kubaneko [Tue, 2 May 2023 20:03:19 +0000 (20:03 +0000)] 
constrained the parameters

11 months agodivided histogram_counters.hist into two .exp and .lin, changed histogram maintaining...
kubaneko [Tue, 2 May 2023 18:24:16 +0000 (18:24 +0000)] 
divided histogram_counters.hist into two .exp and .lin, changed histogram maintaining so exp does not try to recover lin and added some cleanup to histogram versioning

11 months agoClear profile in vectorizer.
Honza [Mon, 1 May 2023 22:39:34 +0000 (00:39 +0200)] 
Clear profile in vectorizer.

11 months agoFix use of estimates.
Honza [Mon, 1 May 2023 22:18:57 +0000 (00:18 +0200)] 
Fix use of estimates.

11 months agoUse histogram in loop vectorizer heuristics
Honza [Mon, 1 May 2023 22:13:52 +0000 (00:13 +0200)] 
Use histogram in loop vectorizer heuristics

11 months agoDo not instrument loops with known number of iterations and with no instrumentable...
Honza [Mon, 1 May 2023 21:50:31 +0000 (23:50 +0200)] 
Do not instrument loops with known number of iterations and with no instrumentable exits.

11 months agoAdd histogram based loop versioning.
Honza [Mon, 1 May 2023 19:52:20 +0000 (21:52 +0200)] 
Add histogram based loop versioning.

12 months agoadded modulo histogram and improved garbage collection
kubaneko [Tue, 25 Apr 2023 08:09:35 +0000 (08:09 +0000)] 
added modulo histogram and improved garbage collection

12 months agochanged from total size to exponential size
kubaneko [Mon, 24 Apr 2023 07:54:30 +0000 (07:54 +0000)] 
changed from total size to exponential size

12 months agoAdd -fuse-histogram-in-peeling
Honza [Sat, 22 Apr 2023 10:49:51 +0000 (12:49 +0200)] 
Add -fuse-histogram-in-peeling

12 months agoMerge final fix for copy header from master
Honza [Sat, 22 Apr 2023 09:28:41 +0000 (11:28 +0200)] 
Merge final fix for copy header from master

12 months agoImprove optimization info on peeling.
Honza [Sat, 22 Apr 2023 09:05:01 +0000 (11:05 +0200)] 
Improve optimization info on peeling.

12 months agohubicka bug fix
kubaneko [Fri, 21 Apr 2023 15:34:54 +0000 (15:34 +0000)] 
hubicka bug fix

12 months agoaggresive histogram
kubaneko [Thu, 20 Apr 2023 14:48:35 +0000 (14:48 +0000)] 
aggresive histogram

12 months agodivision bugfix
kubaneko [Tue, 18 Apr 2023 15:36:45 +0000 (15:36 +0000)] 
division bugfix

12 months agobug fix
kubaneko [Sat, 15 Apr 2023 20:32:57 +0000 (20:32 +0000)] 
bug fix

12 months agognu formating
kubaneko [Sat, 15 Apr 2023 15:32:31 +0000 (15:32 +0000)] 
gnu formating

12 months agofixed warnings
kubaneko [Fri, 14 Apr 2023 14:46:41 +0000 (14:46 +0000)] 
fixed warnings

12 months agoremove histograms when the sum is 0
kubaneko [Thu, 13 Apr 2023 16:56:13 +0000 (16:56 +0000)] 
remove histograms when the sum is 0

12 months agofixed some bugs
kubaneko [Thu, 13 Apr 2023 15:31:32 +0000 (15:31 +0000)] 
fixed some bugs

12 months agopeeling bug, copy header, precision adjusting
kubaneko [Sat, 8 Apr 2023 11:32:48 +0000 (11:32 +0000)] 
peeling bug, copy header, precision adjusting

12 months agomemory management of peeling
kubaneko [Sat, 8 Apr 2023 08:08:13 +0000 (08:08 +0000)] 
memory management of peeling

12 months agofixed peeling bug
kubaneko [Fri, 7 Apr 2023 21:45:09 +0000 (21:45 +0000)] 
fixed peeling bug

12 months agorepaired copy header for histograms
kubaneko [Fri, 7 Apr 2023 19:34:43 +0000 (19:34 +0000)] 
repaired copy header for histograms

12 months agoextracted adjust_loop_estimates_minus
kubaneko [Fri, 7 Apr 2023 18:04:30 +0000 (18:04 +0000)] 
extracted adjust_loop_estimates_minus

12 months agofixed a bug
kubaneko [Fri, 7 Apr 2023 10:20:08 +0000 (10:20 +0000)] 
fixed a bug

12 months agoadded adjusted flag
kubaneko [Fri, 7 Apr 2023 08:26:52 +0000 (08:26 +0000)] 
added adjusted flag

12 months agofixed bug
kubaneko [Wed, 5 Apr 2023 15:50:26 +0000 (15:50 +0000)] 
fixed bug

12 months agoworst case adjusted
kubaneko [Wed, 5 Apr 2023 15:42:12 +0000 (15:42 +0000)] 
worst case adjusted

12 months agorenaming and comments
kubaneko [Wed, 5 Apr 2023 14:50:16 +0000 (14:50 +0000)] 
renaming and comments

12 months agofixed bugs
kubaneko [Wed, 5 Apr 2023 14:44:52 +0000 (14:44 +0000)] 
fixed bugs

12 months agofixed bug
kubaneko [Mon, 3 Apr 2023 13:42:46 +0000 (13:42 +0000)] 
fixed bug

12 months agochange of peeled probabilities
kubaneko [Sun, 2 Apr 2023 15:03:07 +0000 (15:03 +0000)] 
change of peeled probabilities

13 months agopeeling improvements
kubaneko [Wed, 29 Mar 2023 13:40:21 +0000 (13:40 +0000)] 
peeling improvements

13 months agofixed histogram loading
kubaneko [Wed, 29 Mar 2023 12:30:20 +0000 (12:30 +0000)] 
fixed histogram loading

13 months agobetter peeling prototype
kubaneko [Tue, 28 Mar 2023 18:18:51 +0000 (18:18 +0000)] 
better peeling prototype

13 months agochanged where iterations between linear portion and the next pow2 go
kubaneko [Mon, 27 Mar 2023 15:59:53 +0000 (15:59 +0000)] 
changed where iterations between linear portion and the next pow2 go

13 months agofixed byg
kubaneko [Wed, 15 Mar 2023 21:09:45 +0000 (21:09 +0000)] 
fixed byg

13 months agosome minor divise fixes
kubaneko [Wed, 15 Mar 2023 08:16:04 +0000 (08:16 +0000)] 
some minor divise fixes

13 months agofixed up fix-up functions
kubaneko [Wed, 15 Mar 2023 00:21:44 +0000 (00:21 +0000)] 
fixed up fix-up functions

13 months agoadded param range
kubaneko [Tue, 14 Mar 2023 17:23:00 +0000 (17:23 +0000)] 
added param range

13 months agosome refactoring and added lto-streaming for histograms
kubaneko [Mon, 13 Mar 2023 21:31:03 +0000 (21:31 +0000)] 
some refactoring and added lto-streaming for histograms

13 months agomaintaining histogram prototype
kubaneko [Tue, 7 Mar 2023 20:09:11 +0000 (20:09 +0000)] 
maintaining histogram prototype

14 months agofixed error and improved peeling
kubaneko [Wed, 1 Mar 2023 20:30:09 +0000 (20:30 +0000)] 
fixed error and improved peeling

14 months agochange typo
kubaneko [Mon, 27 Feb 2023 15:18:25 +0000 (15:18 +0000)] 
change typo

14 months agoAdded histogram params to libgcov
kubaneko [Sun, 26 Feb 2023 19:17:42 +0000 (19:17 +0000)] 
Added histogram params to libgcov

14 months agoadded primitive peeling and stuff
kubaneko [Thu, 23 Feb 2023 17:04:31 +0000 (17:04 +0000)] 
added primitive peeling and stuff

14 months agoremoved hist_size
kubaneko [Wed, 22 Feb 2023 13:28:25 +0000 (13:28 +0000)] 
removed hist_size

14 months agocorrected shift
kubaneko [Wed, 22 Feb 2023 10:19:34 +0000 (10:19 +0000)] 
corrected shift

14 months agofixed vector allocation
kubaneko [Sat, 14 Jan 2023 22:04:29 +0000 (22:04 +0000)] 
fixed vector allocation

14 months agochanged vector from gc to heap
kubaneko [Sun, 8 Jan 2023 18:59:31 +0000 (18:59 +0000)] 
changed vector from gc to heap

14 months agovector for histogram_counters not working yet
kubaneko [Mon, 2 Jan 2023 14:54:29 +0000 (14:54 +0000)] 
vector for histogram_counters not working yet

14 months agostarted with conversion to parametric histograms
kubaneko [Sat, 31 Dec 2022 21:31:38 +0000 (21:31 +0000)] 
started with conversion to parametric histograms

14 months agonew create_iv
kubaneko [Tue, 22 Nov 2022 16:33:13 +0000 (16:33 +0000)] 
new create_iv

14 months agoredo stuff
kubaneko [Tue, 22 Nov 2022 16:32:49 +0000 (16:32 +0000)] 
redo stuff

14 months agofixed memory allocation for histogram_counters
kubaneko [Tue, 22 Nov 2022 13:12:55 +0000 (13:12 +0000)] 
fixed memory allocation for histogram_counters

14 months agoadded histogram_counters structure
kubaneko [Tue, 8 Nov 2022 15:27:20 +0000 (15:27 +0000)] 
added histogram_counters structure

14 months agotemporary log fix
kubaneko [Tue, 1 Nov 2022 19:36:38 +0000 (19:36 +0000)] 
temporary log fix

14 months agomessed with logarithms
kubaneko [Tue, 1 Nov 2022 17:48:30 +0000 (17:48 +0000)] 
messed with logarithms

14 months agoadded atomic counter
kubaneko [Tue, 1 Nov 2022 14:46:59 +0000 (14:46 +0000)] 
added atomic counter

14 months agoremoved wild fprint removed redundant struct fields
kubaneko [Sun, 23 Oct 2022 21:54:39 +0000 (21:54 +0000)] 
removed wild fprint removed redundant struct fields

14 months agoone histogram per loop, commit edges after deleting fake ones
kubaneko [Tue, 11 Oct 2022 16:42:27 +0000 (16:42 +0000)] 
one histogram per loop, commit edges after deleting fake ones

14 months agoadd loop_optimizer_init
kubaneko [Tue, 27 Sep 2022 12:47:59 +0000 (12:47 +0000)] 
add loop_optimizer_init

14 months agofixed loading found another bug
kubaneko [Mon, 26 Sep 2022 21:51:35 +0000 (21:51 +0000)] 
fixed loading found another bug

14 months agosquashed 2 commits
kubaneko [Thu, 22 Sep 2022 19:05:13 +0000 (19:05 +0000)] 
squashed 2 commits

fixed function calls and tried to load histogram

tried to add loading and failed

14 months agofixed what I broke
kubaneko [Sun, 18 Sep 2022 16:23:28 +0000 (16:23 +0000)] 
fixed what I broke

14 months agoadding histogram for empty bbs
Ondrej Kubanek [Sat, 20 Aug 2022 21:37:39 +0000 (23:37 +0200)] 
adding histogram for empty bbs

14 months agoRevert "Revert "tried fix create_iv and failed""
Ondrej Kubanek [Sat, 20 Aug 2022 20:21:31 +0000 (22:21 +0200)] 
Revert "Revert "tried fix create_iv and failed""

This reverts commit da5b7fc0fdf0227aa8347ffab1568198ccc58c43.

14 months agodeleted an assert to to test the if preheaders are needed in this case
Ondrej Kubanek [Sat, 20 Aug 2022 20:21:00 +0000 (22:21 +0200)] 
deleted an assert to to test the if preheaders are needed in this case

14 months agoRevert "tried fix create_iv and failed"
Ondrej Kubanek [Sat, 20 Aug 2022 20:19:09 +0000 (22:19 +0200)] 
Revert "tried fix create_iv and failed"

This reverts commit 082a5ebc956de41baf9d45ed609542ddd520df2d.

14 months agotried fix create_iv and failed
Ondrej Kubanek [Sat, 20 Aug 2022 20:14:46 +0000 (22:14 +0200)] 
tried fix create_iv and failed

14 months agoadded myself to maintainers
Ondrej Kubanek [Thu, 18 Aug 2022 21:44:08 +0000 (23:44 +0200)] 
added myself to maintainers

14 months agoRevert "test commit added myself to MAINTAINERS"
Ondrej Kubanek [Thu, 18 Aug 2022 21:39:58 +0000 (23:39 +0200)] 
Revert "test commit added myself to MAINTAINERS"

This reverts commit 79707034dca6941cf2b625f45ba0a08d3cd6753d.

14 months agofixed logarithm
Ondrej Kubanek [Wed, 27 Jul 2022 12:02:24 +0000 (14:02 +0200)] 
fixed logarithm

14 months agoloop counter prototype
Ondrej Kubanek [Wed, 27 Jul 2022 12:00:47 +0000 (14:00 +0200)] 
loop counter prototype

14 months agotest commit added myself to MAINTAINERS
Ondrej Kubanek [Wed, 13 Jul 2022 12:52:42 +0000 (14:52 +0200)] 
test commit added myself to MAINTAINERS

14 months agoadded histogram profiler and added it to division
Ondrej Kubanek [Tue, 12 Jul 2022 13:22:29 +0000 (15:22 +0200)] 
added histogram profiler and added it to division

14 months agotestsuite: Fix up modules.exp [PR108899]
Jakub Jelinek [Thu, 23 Feb 2023 16:17:05 +0000 (17:17 +0100)] 
testsuite: Fix up modules.exp [PR108899]

On Wed, Feb 22, 2023 at 02:33:42PM -0300, Alexandre Oliva via Gcc-patches wrote:
> When a multi-source module is found to be unsupported, we fail
> module_cmi_p and subsequent sources.  Override proc unsupported to
> mark the result in module_do, and test it to skip module_cmp_p and
> subsequent related tests.
>
> for  gcc/testsuite/ChangeLog
>
>       * g++.dg/modules/modules.exp: Override unsupported to update
>       module_do, and test it after dg-test.

This patch breaks testing with more than one set of options in
target board, like
make check-g++ RUNTESTFLAGS='--target_board=unix\{-m32,-m64\} modules.exp'
yields:
...
                 === g++ Summary for unix/-m32 ===

 # of expected passes            7217
 # of unexpected failures        1
 # of expected failures          18
 # of unsupported tests          2
 Running target unix/-m64
...
 ERROR: tcl error sourcing /home/jakub/src/gcc/gcc/testsuite/g++.dg/modules/modules.exp.
 ERROR: tcl error code TCL OPERATION RENAME TARGET_EXISTS
 ERROR: can't rename to "saved-unsupported": command already exists
     while executing
 "rename unsupported saved-unsupported"
     (file "/home/jakub/src/gcc/gcc/testsuite/g++.dg/modules/modules.exp" line 322)
     invoked from within
 "source /home/jakub/src/gcc/gcc/testsuite/g++.dg/modules/modules.exp"
     ("uplevel" body line 1)
     invoked from within
 "uplevel #0 source /home/jakub/src/gcc/gcc/testsuite/g++.dg/modules/modules.exp"
     invoked from within
 "catch "uplevel #0 source $test_file_name" msg"

In other spots where we in *.exp files rename some routine, we guard that
and the following patch does that for modules.exp too.

Tested with running
make check-g++ RUNTESTFLAGS='--target_board=unix\{-m32,-m64\} modules.exp'
again which now works properly again.

2023-02-23  Jakub Jelinek  <jakub@redhat.com>

PR testsuite/108899
* g++.dg/modules/modules.exp: Only override unsupported if it
exists and saved-unsupported doesn't.

14 months agoFix memory leak in PTA
Richard Biener [Thu, 23 Feb 2023 13:09:04 +0000 (14:09 +0100)] 
Fix memory leak in PTA

When handle_lhs_call calls .create on the passed in vector it leaks
any previous allocated storage.  Avoid doing that and instead rely
on the caller for memory management, just truncate the vector.

* tree-ssa-structalias.cc (handle_lhs_call): Do not
re-create rhsc, only truncate it.

14 months agoc++: Fix up -fcontracts option description [PR108890]
Jakub Jelinek [Thu, 23 Feb 2023 14:27:31 +0000 (15:27 +0100)] 
c++: Fix up -fcontracts option description [PR108890]

This translation PR mentioned the description is a little bit weird.

2023-02-23  Jakub Jelinek  <jakub@redhat.com>

PR translation/108890
* c.opt (fcontracts): Fix description.

14 months agoipa-prop: Fix another case of missing BUILT_IN_UNREACHABLE_TRAP handling [PR106258]
Jakub Jelinek [Thu, 23 Feb 2023 14:24:43 +0000 (15:24 +0100)] 
ipa-prop: Fix another case of missing BUILT_IN_UNREACHABLE_TRAP handling [PR106258]

There is another spot that handles in IPA just BUILT_IN_UNREACHABLE and
not BUILT_IN_UNREACHABLE_TRAP.

This patch fixes that.

2023-02-23  Jakub Jelinek  <jakub@redhat.com>

PR middle-end/106258
* ipa-prop.cc (try_make_edge_direct_virtual_call): Handle
BUILT_IN_UNREACHABLE_TRAP like BUILT_IN_UNREACHABLE.

14 months agolibstdc++: Test that integral simd reductions are precise
Matthias Kretz [Tue, 21 Feb 2023 09:43:13 +0000 (10:43 +0100)] 
libstdc++: Test that integral simd reductions are precise

Signed-off-by: Matthias Kretz <m.kretz@gsi.de>
libstdc++-v3/ChangeLog:

* testsuite/experimental/simd/tests/reductions.cc: Introduce
max_distance as the type-dependent max error.

14 months agolibstdc++: Fix -Wsign-compare issue
Matthias Kretz [Tue, 21 Feb 2023 09:31:55 +0000 (10:31 +0100)] 
libstdc++: Fix -Wsign-compare issue

Signed-off-by: Matthias Kretz <m.kretz@gsi.de>
libstdc++-v3/ChangeLog:

* include/experimental/bits/simd_builtin.h (_S_set): Compare as
int. The actual range of these indexes is very small.

14 months agolibstdc++: Add missing constexpr on simd shift implementation
Matthias Kretz [Mon, 20 Feb 2023 16:35:59 +0000 (17:35 +0100)] 
libstdc++: Add missing constexpr on simd shift implementation

Resolves -Wtautological-compare warnings about `if
(__builtin_is_constant_evaluated())` in the implementations of these
functions.

Signed-off-by: Matthias Kretz <m.kretz@gsi.de>
libstdc++-v3/ChangeLog:

* include/experimental/bits/simd_x86.h (_S_bit_shift_left)
(_S_bit_shift_right): Declare constexpr. The implementation was
already expecting constexpr evaluation.

14 months agolibstdc++: Fix simd build failure on clang
Matthias Kretz [Mon, 20 Feb 2023 10:13:44 +0000 (11:13 +0100)] 
libstdc++: Fix simd build failure on clang

Clang does not support __attribute__ on lambdas. Therefore, only set
_GLIBCXX_SIMD_ALWAYS_INLINE_LAMBDA if __clang__ is not defined.

Signed-off-by: Matthias Kretz <m.kretz@gsi.de>
libstdc++-v3/ChangeLog:

PR libstdc++/108030
* include/experimental/bits/simd_detail.h
(_GLIBCXX_SIMD_ALWAYS_INLINE_LAMBDA): Define as empty for
__clang__.

14 months agolibstdc++: Simplify three helper functions into one
Matthias Kretz [Sat, 14 Jan 2023 22:32:38 +0000 (23:32 +0100)] 
libstdc++: Simplify three helper functions into one

Broadcast is a very common function. This should reduce compile-time
effort.

Signed-off-by: Matthias Kretz <m.kretz@gsi.de>
libstdc++-v3/ChangeLog:

PR libstdc++/108030
* include/experimental/bits/simd.h (__vector_broadcast):
Implement via __vector_broadcast_impl instead of
__call_with_n_evaluations + 2 lambdas.
(__vector_broadcast_impl): New.

14 months agoFix memory leak in if-conversion
Richard Biener [Thu, 23 Feb 2023 10:05:47 +0000 (11:05 +0100)] 
Fix memory leak in if-conversion

The following fixes if-conversion failing to release data-references
and the data-reference vector.

* tree-if-conv.cc (tree_if_conversion): Properly manage
memory of refs and the contained data references.

14 months agotree-optimization/108888 - call if-conversion
Richard Biener [Thu, 23 Feb 2023 10:03:03 +0000 (11:03 +0100)] 
tree-optimization/108888 - call if-conversion

The following makes sure to only predicate calls necessary.

PR tree-optimization/108888
* tree-if-conv.cc (if_convertible_stmt_p): Set PLF_2 on
calls to predicate.
(predicate_statements): Only predicate calls with PLF_2.

* g++.dg/torture/pr108888.C: New testcase.

14 months agoxtensa: Fix missing mode warnings in machine description
Takayuki 'January June' Suwa [Thu, 23 Feb 2023 03:42:32 +0000 (12:42 +0900)] 
xtensa: Fix missing mode warnings in machine description

gcc/ChangeLog:

* config/xtensa/xtensa.md
(zero_cost_loop_start, zero_cost_loop_end, loop_end):
Add missing "SI:" to PLUS RTXes.

14 months agoxtensa: fix PR target/108876
Max Filippov [Thu, 23 Feb 2023 06:08:21 +0000 (22:08 -0800)] 
xtensa: fix PR target/108876

In commit b2ef02e8cbbaf95fee98be255f697f47193960ec, the sibling call
insn included (use (reg:SI A0_REG)) to fix the problem, which added
a USE chain unconditionally to the data flow of register A0 during
the sibling call.

As a result, df_regs_ever_live_p (A0_REG) returns true, so even if
register A0 is not used outside of the sibling call insn, saves and
restores to stack slots are emitted in pro/epilogue, and finally
code size increases.
(This is why I never included (use A0) in sibling calls)

    /* example */
    extern int foo(int);
    int test(int a) {
      return foo(a * 3 + 1);
    }

;; before
    test:
addi sp, sp, -16 ;; unneeded stack frame allocation (induced)
s32i.n a0, sp, 12 ;; unneeded saving of register A0
l32i.n a0, sp, 12 ;; unneeded restoration of register A0
addx2 a2, a2, a2
addi.n a2, a2, 1
addi sp, sp, 16 ;; unneeded stack frame freeing (induced)
j.l foo, a9 ;; sibling call (truly needs register A0)

The essential cause is that we emit (use A0) *before* the insns that
does the stack pointer adjustment during epilogue expansion, so the
liveness of register A0 ends early, so register A0 is reused afterwards.

This patch fixes the problem and avoids such regression by doing the
emit of (use A0) in the sibling call epilogue expansion at the end.

;; after
test:
addx2 a2, a2, a2
addi.n a2, a2, 1
j.l foo, a9

>From RTL-pass "315r.rnreg" by
"gfortran -O3 -funroll-loops -mabi=call0 -S -da gcc-gnu/gcc/testsuite/gfortran.dg/allocate_with_source_5.f90":

    ;; Function selector_init (__selectors_MOD_selector_init, funcdef_no=2, decl_uid=987, cgraph_uid=3, symbol_order=4)
    ...
    (insn 3807 3806 3808 121 (set (reg:SI 15 a15)
            (mem/c:SI (plus:SI (reg/f:SI 1 sp)
                    (const_int 268 [0x10c])) [31  S4 A32])) "gcc-gnu/gcc/testsuite/gfortran.dg/allocate_with_source_5.f90":35:30 53 {movsi_internal}
         (nil))
    (insn 3808 3807 3809 121 (set (reg:SI 7 a7)
            (const_int 288 [0x120])) "gcc-gnu/gcc/testsuite/gfortran.dg/allocate_with_source_5.f90":35:30 53 {movsi_internal}
         (nil))
    (insn 3809 3808 3810 121 (set (reg/f:SI 1 sp)
            (plus:SI (reg/f:SI 1 sp)
                (reg:SI 7 a7))) "gcc-gnu/gcc/testsuite/gfortran.dg/allocate_with_source_5.f90":35:30 1 {addsi3}
         (expr_list:REG_DEAD (reg:SI 9 a9)
            (nil)))
    (insn 3810 3809 721 121 (use (reg:SI 0 a0)) "gcc-gnu/gcc/testsuite/gfortran.dg/allocate_with_source_5.f90":35:30 -1
         (expr_list:REG_DEAD (reg:SI 0 a0)
            (nil)))
    (call_insn/j 721 3810 722 121 (call (mem:SI (symbol_ref:SI ("free") [flags 0x41]  <function_decl 0x7f7c885f6000 __builtin_free>) [0 __builtin_free S4 A32])
            (const_int 0 [0])) "gcc-gnu/gcc/testsuite/gfortran.dg/allocate_with_source_5.f90":35:30 discrim 1 106 {sibcall_internal}
         (expr_list:REG_DEAD (reg:SI 2 a2)
            (expr_list:REG_CALL_DECL (symbol_ref:SI ("free") [flags 0x41]  <function_decl 0x7f7c885f6000 __builtin_free>)
                (expr_list:REG_EH_REGION (const_int 0 [0])
                    (nil))))
        (expr_list:SI (use (reg:SI 2 a2))
            (nil)))

(IMHO the "rnreg" pass doesn't take REG_ALLOC_ORDER into account;
it just seems to allocate registers in fixed_regs index order,
which may have hurt register A0 that became allocatable in the recent
patch)

gcc/ChangeLog:
PR target/108876

* config/xtensa/xtensa.cc (xtensa_expand_epilogue):
Emit (use (reg:SI A0_REG)) at the end in the sibling call
(i.e. the same place as (return) in the normal call).

14 months agoRevert "gcc: xtensa: fix PR target/108876"
Max Filippov [Thu, 23 Feb 2023 06:07:58 +0000 (22:07 -0800)] 
Revert "gcc: xtensa: fix PR target/108876"

This reverts commit b2ef02e8cbbaf95fee98be255f697f47193960ec.

14 months agodocs: Reorder @opindex before corresponding options
Arsen Arsenović [Thu, 23 Feb 2023 01:06:49 +0000 (02:06 +0100)] 
docs: Reorder @opindex before corresponding options

gcc/d/ChangeLog:

* gdc.texi: Reorder @opindex commands to precede @items they
relate to.

gcc/ChangeLog:

* doc/cppdiropts.texi: Reorder @opindex commands to precede
@items they relate to.
* doc/cppopts.texi: Ditto.
* doc/cppwarnopts.texi: Ditto.
* doc/invoke.texi: Ditto.
* doc/lto.texi: Ditto.

gcc/fortran/ChangeLog:

* invoke.texi: Reorder @opindex commands to precede @items they
relate to.