On Wed, May 15, 2019 at 2:46 PM Richard Sandiford
wrote:
>
> Max Filippov writes:
> > Let backends call assemble_start_function after they have generated
> > thunk function body so that a constant pool could be output if it is
> > required. This may help backends to a
Change that moved assemble_start_function/assemble_end_function to
backends missed aarch64. Fix that.
Committed as obvious.
gcc/
2019-05-17 Max Filippov
* config/aarch64/aarch64.c (aarch64_output_mi_thunk): Call
assemble_start_function and assemble_end_function.
---
gcc
to fix it differently?
---8<---
>From bad901880a3f9fc69726aa082e2b2c674bacca94 Mon Sep 17 00:00:00 2001
From: Max Filippov
Date: Mon, 7 Jan 2019 18:22:12 -0800
Subject: [PATCH] gcc: move assemble_start_function / assemble_end_function to
output_mi_thunk
Let backends call assemble_start_fun
Sorry, wrong list, meant to send to g...@gcc.gnu.org
--
Thanks.
-- Max
On Fri, Jan 11, 2019 at 10:50 AM Jeff Law wrote:
> I think this needs to defer to gcc-10
Ok, will resend when in stage1.
--
Thanks.
-- Max
This enables options -fstack-usage and -Wstack-usage.
2016-08-21 Max Filippov
gcc/
* config/xtensa/xtensa.c (xtensa_expand_prologue): Update
current_function_static_stack_size variable with the static
stack frame size of the current function when
On Fri, Aug 26, 2016 at 9:24 AM, augustine.sterl...@gmail.com
wrote:
> On Fri, Aug 26, 2016 at 12:02 AM, Max Filippov wrote:
>> This enables options -fstack-usage and -Wstack-usage.
>>
>> 2016-08-21 Max Filippov
>> gcc/
>> * config/xtensa/xtensa.c
>From 62ab7123e73563b43f1833842a419aa66eca7ce2 Mon Sep 17 00:00:00 2001
From: Max T Woodbury
Date: Mon, 23 Oct 2017 16:58:49 -0400
Copyright 2017 Max TenEyck Woodbury, Durham North Carolina
all rights assigned to the Free Software Foundation, Inc., 23 Oct 2017
The Problem:
There i
2017-09-11 Max Filippov
gcc/
* expmed.c (emit_store_flag_int): Initialize rtx tem.
---
gcc/expmed.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/gcc/expmed.c b/gcc/expmed.c
index 7f0cb0a0ec05..945ab3d656a2 100644
--- a/gcc/expmed.c
+++ b/gcc/expmed.c
@@ -5601,7
2017-09-11 Max Filippov
gcc/
* config/xtensa/xtensa.c (xtensa_mem_offset): Check that both
words of E_DImode object are reachable by xtensa_uimm8x4 access.
---
gcc/config/xtensa/xtensa.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/gcc/config/xtensa/xtensa.c b/gcc/config
On Mon, Sep 11, 2017 at 2:18 PM, augustine.sterl...@gmail.com
wrote:
> On Mon, Sep 11, 2017 at 2:16 PM, Max Filippov wrote:
>> 2017-09-11 Max Filippov
>> gcc/
>> * config/xtensa/xtensa.c (xtensa_mem_offset): Check that both
>> words of E_DIm
Hi Richard,
On Mon, Sep 11, 2017 at 2:36 PM, Richard Sandiford
wrote:
> Max Filippov writes:
>> 2017-09-11 Max Filippov
>> gcc/
>> * expmed.c (emit_store_flag_int): Initialize rtx tem.
>
> LGTM, thanks, but I can't approve it.
>
> This makes the
gcc/
2017-03-27 Max Filippov
* config/xtensa/xtensa-protos.h
(xtensa_initial_elimination_offset): New declaration.
* config/xtensa/xtensa.c (xtensa_initial_elimination_offset):
New function. Move its body from the INITIAL_ELIMINATION_OFFSET
macro
On Mon, May 8, 2017 at 4:24 PM, augustine.sterl...@gmail.com
wrote:
> On Mon, May 8, 2017 at 3:55 PM, Max Filippov wrote:
>> gcc/
>> 2017-03-27 Max Filippov
>>
>> * config/xtensa/xtensa-protos.h
>> (xtensa_initial_elimination_offset): New
data structure, initialization macros, redefines XCHAL_* macros to
access this structure and declares function for loading configuration
dynamically.
Max Filippov (5):
gcc: xtensa: allow XCHAL_* macros to be non-constant
gcc: xtensa: make configuration dynamic
gcc: xtensa: support dynconfig on wi
XCHAL_* macros from the xtensa-config.h are used in a number of places
that require them to be preprocessor constants. Rewrite these places so
that non-constant XCHAL_* definitions could be used there.
2017-05-22 Max Filippov
gcc/
* config/xtensa/xtensa.c (xtensa_option_override
2017-05-22 Max Filippov
gcc/
* config/xtensa/xtensa-config.c (dlfcn.h, windows.h): New
#include'd headers.
(RTLD_LAZY): New macro definition.
(dlopen, dlsym, dlclose, dlerror): New function definitions.
---
gcc/config/xtensa/xtensa-config.c
efine reusable function xtensa_load_config that tries to load
configuration and return an address of an exported object from it.
Define the function xtensa_get_config that uses xtensa_load_config to
get structure xtensa_config, either dynamically configured or the
default.
2017-05-22 Max Filippov
Provide essential XCHAL_* configuration parameters as __XCHAL_* built-in
macros. This way it will be possible to use them in libgcc and libc
without need to patch libgcc or libc source for the specific xtensa core
configuration.
2017-05-22 Max Filippov
gcc/
* config/xtensa/xtensa
Now that gcc provides __XCHAL_* definitions use them instead of XCHAL_*
definitions from the include/xtensa-config.h. That makes libgcc
dynamically configurable for the target xtensa core.
2017-05-22 Max Filippov
include/
* xtensa-config-builtin.h: New File.
libgcc/
* config
On Mon, May 22, 2017 at 2:30 PM, augustine.sterl...@gmail.com
wrote:
> On Mon, May 22, 2017 at 2:09 PM, Max Filippov wrote:
>> XCHAL_* macros from the xtensa-config.h are used in a number of places
>> that require them to be preprocessor constants. Rewrite these places so
>&
On Thu, May 25, 2017 at 11:24 AM, augustine.sterl...@gmail.com
wrote:
> On Mon, May 22, 2017 at 2:09 PM, Max Filippov wrote:
>> Now that XCHAL_* macros don't have to be preprocessor constants add
>> include/xtensa-dynconfig.h that defines them as fields of a structure
On Fri, May 26, 2017 at 7:44 AM, Ian Lance Taylor wrote:
> On Thu, May 25, 2017 at 1:31 PM, Max Filippov wrote:
>> On Thu, May 25, 2017 at 11:24 AM, augustine.sterl...@gmail.com
>> wrote:
>>
>>> Please note that by using a plugin mechanism, there are licensing
HOST_WIDE_INT may not be long as assumed in print_operand and
xtensa_emit_call. Use HOST_WIDE_INT_PRINT_DEC/HOST_WIDE_INT_PRINT_HEX
format strings instead of %ld/0x%lx. This fixes incorrect assembly code
generation by the compiler running on armhf host.
2017-05-28 Max Filippov
gcc
2017-05-28 Max Filippov
gcc/
* config/xtensa/xtensa.c (xtensa_initial_elimination_offset):
Mark 'to' argument with ATTRIBUTE_UNUSED.
---
gcc/config/xtensa/xtensa.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/gcc/config/xtensa/xtensa.c b/gcc/con
On Mon, May 29, 2017 at 9:08 AM, augustine.sterl...@gmail.com
wrote:
> On Mon, May 29, 2017 at 4:11 AM, Max Filippov wrote:
>> 2017-05-28 Max Filippov
>> gcc/
>> * config/xtensa/xtensa.c (xtensa_initial_elimination_offset):
>> Mark 'to' arg
On Mon, May 29, 2017 at 9:08 AM, augustine.sterl...@gmail.com
wrote:
> On Mon, May 29, 2017 at 4:11 AM, Max Filippov wrote:
>> HOST_WIDE_INT may not be long as assumed in print_operand and
>> xtensa_emit_call. Use HOST_WIDE_INT_PRINT_DEC/HOST_WIDE_INT_PRINT_HEX
>> format s
Use new FPU instruction sequences documented in the ISA book to
implement __divsf3, __divdf3, __recipsf2, __recipdf2, __rsqrtsf2,
__rsqrtdf2 and __ieee754_sqrtf and __ieee754_sqrt.
2013-02-12 Ding-Kai Chen
libgcc/
* config/xtensa/ieee754-df.S (__recipdf2, __rsqrtdf2,
__ieee754_s
Define LIB2ADDEH_XTENSA_UNWIND_DW2_FDE to unwind-dw2-fde.c in
xtensa/t-elf and to unwind-dw2-fde-dip.c in xtensa/t-linux and use
LIB2ADDEH_XTENSA_UNWIND_DW2_FDE in LIB2ADDEH definition.
2016-10-17 Max Filippov
libgcc/
* config/xtensa/t-elf (LIB2ADDEH_XTENSA_UNWIND_DW2_FDE): New
2016-05-24 Max Filippov
gcc/
* config/xtensa/xtensa.opt (mpreferred-stack-boundary=): New
option.
* config/xtensa/xtensa.h (STACK_BOUNDARY): Redefine as 64 for
windowed ABI/32 for call0 ABI.
(PREFERRED_STACK_BOUNDARY): New definition.
* config
On Tue, Oct 18, 2016 at 11:22 AM, augustine.sterl...@gmail.com
wrote:
> On Fri, Oct 14, 2016 at 12:14 PM, Max Filippov wrote:
>>
>> Use new FPU instruction sequences documented in the ISA book to
>> implement __divsf3, __divdf3, __recipsf2, __recipdf2, __rsqrts
On Tue, Oct 18, 2016 at 11:22 AM, augustine.sterl...@gmail.com
wrote:
> On Mon, Oct 17, 2016 at 4:23 PM, Max Filippov wrote:
>> Define LIB2ADDEH_XTENSA_UNWIND_DW2_FDE to unwind-dw2-fde.c in
>> xtensa/t-elf and to unwind-dw2-fde-dip.c in xtensa/t-linux and use
>> LIB2ADDEH_
n structure. Implement predicate for the "return" pattern
as a function. Don't communicate completion of epilogue generation
through zeroing of xtensa_current_frame_size, add explicit epilogue_done
variable to the machine_function structure. Don't update stack frame
layout aft
On Tue, Nov 1, 2016 at 9:28 AM, augustine.sterl...@gmail.com
wrote:
> On Mon, Oct 31, 2016 at 11:32 PM, Max Filippov wrote:
>> 2016-10-26 Max Filippov
>> gcc/
>> * config/xtensa/xtensa-protos.h
>> (xtensa_use_return_instruction_p): New prototype.
handling literals of any
power of 2 size not less than 4.
2016-11-01 Max Filippov
gcc/
* config/xtensa/xtensa.c (xtensa_output_integer_literal_parts):
New function.
(xtensa_output_literal): Use xtensa_output_integer_literal_parts
to format MODE_INT and MODE_PARTIAL_INT
With jump trampolines implemented in binutils since 2.25 and enabled by
default this test no longer fails on xtensa.
2016-11-01 Max Filippov
gcc/testsuite/
* gcc.c-torture/compile/20001226-1.c: Don't xfail on xtensa.
---
gcc/testsuite/gcc.c-torture/compile/20001226-1.c | 1 -
1
On Wed, Nov 2, 2016 at 10:23 AM, augustine.sterl...@gmail.com
wrote:
> On Tue, Nov 1, 2016 at 12:11 PM, Max Filippov wrote:
>> xtensa gcc gets ICE on pr59037.c test because its xtensa_output_literal
>> function cannot handle integer literals of sizes other than 4 and 8,
>>
On Wed, Nov 2, 2016 at 10:22 AM, augustine.sterl...@gmail.com
wrote:
> On Tue, Nov 1, 2016 at 12:45 PM, Max Filippov wrote:
>> With jump trampolines implemented in binutils since 2.25 and enabled by
>> default this test no longer fails on xtensa.
>>
>> 2016-11-01 Max
2016-11-29 Max Filippov
gcc/
* config/xtensa/xtensa.c (hwloop_optimize): Don't emit zero
overhead loop start between a call and its CALL_ARG_LOCATION
note.
---
gcc/config/xtensa/xtensa.c | 5 -
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/gcc/c
On Tue, Nov 29, 2016 at 2:16 PM, augustine.sterl...@gmail.com
wrote:
> On Tue, Nov 29, 2016 at 2:08 PM, Max Filippov wrote:
>> 2016-11-29 Max Filippov
>> gcc/
>> * config/xtensa/xtensa.c (hwloop_optimize): Don't emit zero
>> overhead l
more than 256 KBytes of code.
Don't turn constants into literals, instead use MOVI instruction to load
them into registers and let the assembler turn them into literals as
necessary.
2015-08-11 Max Filippov
gcc/
* config/xtensa/constraints.md (define_constraint "Y"): New
On Wed, Aug 12, 2015 at 7:35 PM, augustine.sterl...@gmail.com
wrote:
> On Tue, Aug 11, 2015 at 6:09 PM, Max Filippov wrote:
>> With support from assembler this option allows compiling huge functions,
>> where single literal pool at the beginning of a function may not be
>&
-cancelx21,
nptl/tst-cleanupx1,
nptl/tst-cleanupx3,
nptl/tst-oncex3,
nptl/tst-oncex4.
Max Filippov (3):
xtensa: reimplement register spilling
xtensa: use unwind-dw2-fde-dip instead of unwind-dw2-fde
xtensa: fix _Unwind_GetCFA
libgcc/config/xtensa/lib2funcs.S | 30
Spilling windowed registers in userspace is much easier, more portable,
less error-prone and equally effective as in kernel. Now that register
spilling syscall is considered obsolete in the xtensa linux kernel
replace it with CALL12 followed by series of ENTRY in libgcc.
2015-08-18 Max Filippov
ontext->sp from _Unwind_GetCFA makes all CFA values valid and
matching code that used them.
2015-08-18 Max Filippov
libgcc/
* config/xtensa/unwind-dw2-xtensa.c (_Unwind_GetCFA): Return
context->sp instead of context->cfa.
---
libgcc/config/xtensa/unwind-dw2-xtensa.c
This allows having exception cleanup code in binaries that don't
register their unwind tables.
2015-08-18 Max Filippov
libgcc/
* config/xtensa/t-windowed (LIB2ADDEH): Replace unwind-dw2-fde
with unwind-dw2-fde-dip.
---
libgcc/config/xtensa/t-windowed | 2 +-
1 file chang
On Tue, Aug 18, 2015 at 3:50 AM, augustine.sterl...@gmail.com
wrote:
> On Mon, Aug 17, 2015 at 2:59 PM, Max Filippov wrote:
>> 2015-08-18 Max Filippov
>> libgcc/
>> * config/xtensa/lib2funcs.S (__xtensa_libgcc_window_spill): Use
>> CALL12 followed
2015-09-15 Max Filippov
gcc/
* config/xtensa/xtensa.c (xtensa_call_tls_desc): Use a10 or a2
to pass TLS call argument, according to current ABI.
* config/xtensa/xtensa.md (tls_call pattern): Use callx8 or
callx0 for TLS call, according to current ABI.
---
gcc
Hi Sterling,
this series fixes two bugs in Xtensa call0 ABI support: callx8
unconditionally used for TLS calls and missing signal frame unwinding code
for xtensa_fallback_frame_state.
With these fixes uClibc testsuite results for windowed and call0 ABIs become
identical.
Max Filippov (2
2015-09-15 Max Filippov
gcc/
* config/xtensa/xtensa.h (DWARF_ALT_FRAME_RETURN_COLUMN): New
definition.
(DWARF_FRAME_REGISTERS): Reserve space for one extra register in
call0 ABI.
libgcc/
* config/xtensa/linux-unwind.h (xtensa_fallback_frame_state
12-30 Max Filippov
* config/xtensa/xtensa.c (hwloop_optimize, hwloop_fail,
hwloop_pattern_reg, xtensa_doloop_hooks, xtensa_reorg_loops):
put under #if TARGET_LOOPS guard.
---
gcc/config/xtensa/xtensa.c | 8
1 file changed, 8 insertions(+)
diff --git a/gcc/c
On Mon, Jan 5, 2015 at 7:21 PM, augustine.sterl...@gmail.com
wrote:
> [Adding Felix]
>
> On Mon, Dec 29, 2014 at 3:12 PM, Max Filippov wrote:
>>
>> Currently building gcc for xtensa configuration with XCHAL_HAVE_LOOPS
>> set to 0 fails with the following error:
>&
t.
Xtensa is now supported by the QEMU, so probably question mark in its 'S' slot
may be removed.
--
Thanks.
-- Max
nsa.cc | 3 +++
> gcc/config/xtensa/xtensa.md | 12 ++--
> 2 files changed, 9 insertions(+), 6 deletions(-)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed to master
--
Thanks.
-- Max
allocated registers that satisfy the above constraints.
> ---
> gcc/config/xtensa/xtensa.md | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed to master
--
Thanks.
-- Max
7b lra(_IO_FILE*, int)
/home/jcmvbkbc/ws/tensilica/gcc/gcc/gcc/lra.cc:2636
0xbdbe77 do_reload
/home/jcmvbkbc/ws/tensilica/gcc/gcc/gcc/ira.cc:5987
0xbdbe77 execute
/home/jcmvbkbc/ws/tensilica/gcc/gcc/gcc/ira.cc:6175
--
Thanks.
-- Max
retw.n
>
> gcc/ChangeLog:
>
> * config/xtensa/xtensa.cc (xtensa_register_move_cost):
> Add appropriate move costs between AR_REGS and FP_REGS.
> ---
> gcc/config/xtensa/xtensa.cc | 28 +++++++-
> 1 file changed, 19 insertions(+), 9 deletions(-)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed to master.
That's a nice fix, thank you Suwa-san!
--
Thanks.
-- Max
Add new function check_effective_target_xtensa_atomic and use it in the
check_effective_target_sync_int_long and
check_effective_target_sync_char_short.
gcc/testsuite/ChangeLog:
* lib/target-supports.exp
(check_effective_target_xtensa_atomic): New function.
(check_effectiv
| 1 -
> 1 file changed, 1 deletion(-)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed the whole series to master with minor fixups in descriptions.
--
Thanks.
-- Max
ointer
-funroll-loops -fpeel-loops -ftracer -finline-functions execution
test
+FAIL: gfortran.dg/out_of_range_2.f90 -O3 -g execution test
+FAIL: gfortran.dg/out_of_range_2.f90 -Os execution test
At first glance they may be related to the rounding mode settings,
let me take a closer look.
--
Thanks.
-- Max
statements.
> (lsfsi2, *lsfsi2_2x, *lsfsi2_scaled):
> New insn patterns.
> ---
> gcc/config/xtensa/xtensa.cc | 16 ++++
> gcc/config/xtensa/xtensa.md | 50 -
> 2 files changed, 54 insertions(+), 12 deletions(-)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed to master.
--
Thanks.
-- Max
On Thu, Jun 5, 2025 at 7:20 PM Takayuki 'January June' Suwa
wrote:
>
> On 2025/06/06 8:55, Max Filippov wrote:
>
> > On Thu, Jun 05, 2025 at 09:19:19PM +0900, Takayuki 'January June' Suwa
> > wrote:
> >> On 2025/06/05 5:09, Max Filippov wr
On Thu, Jun 05, 2025 at 09:19:19PM +0900, Takayuki 'January June' Suwa wrote:
> On 2025/06/05 5:09, Max Filippov wrote:
> > On Tue, Jun 3, 2025 at 7:44 AM Takayuki 'January June' Suwa
> > wrote:
> > >
> > > By using the previously unused
Ne plus rien recevoir de notre part
sn attribute related to TARGET_DENSITY.
> (*extzvsi-1bit_addsubx): Ditto.
> ---
> gcc/config/xtensa/xtensa.md | 11 ++-
> 1 file changed, 6 insertions(+), 5 deletions(-)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed to master with a more readable subject line.
--
Thanks.
-- Max
ion.
> * config/xtensa/xtensa.md (*subsi3_from_const):
> New insn_and_split pattern.
> ---
> gcc/config/xtensa/constraints.md | 2 +-
> gcc/config/xtensa/xtensa-protos.h | 1 +
> gcc/config/xtensa/xtensa.cc | 7 +++
> gcc/config/xtensa/xtensa.md | 24
> 4 files changed, 33 insertions(+), 1 deletion(-)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed to master.
--
Thanks.
-- Max
/config/xtensa/xtensa.md | 4 +-
> 3 files changed, 172 insertions(+), 154 deletions(-)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed to master.
--
Thanks.
-- Max
/20070623-1.c)
when an overflow occurs, e.g. for op0 == INT_MIN, op1 == INT_MAX.
Maybe the dedicated instructions salt / saltu could be used in that pattern?
They don't have their own XCHAL_* macros, but according to the ISA book
they were introduced in RG-2015.0, which I believe could be tested as follows:
#define TARGET_SALT (XTENSA_MARCH_EARLIEST >= 27)
--
Thanks.
-- Max
o_op1));
> + emit_insn (gen_subsi3 (hi_dest, hi_op0, hi_op1));
> + emit_cmp_and_jump_insns (lo_op0, lo_op1, GEU, const0_rtx,
> + SImode, true, label = gen_label_rtx ());
> + emit_insn (gen_addsi3 (hi_dest, hi_dest, constm1_rtx));
> + emit_label (label);
> + DONE;
> +})
> +
> (define_insn "subsf3"
>[(set (match_operand:SF 0 "register_operand" "=f")
> (minus:SF (match_operand:SF 1 "register_operand" "f")
> --
> 2.30.2
--
Thanks.
-- Max
swapped.
> In addition, replace use of code iterator with new operator
> predicate.
> (*shlrd_const, *shlrd_per_byte):
> Likewise regarding the code iterator.
> ---
> gcc/config/xtensa/predicates.md | 3 ++
> gcc/config/xtensa/xtensa.md | 81 ++++++---
> 2 files changed, 58 insertions(+), 26 deletions(-)
Regtested for target=xtensa-linux-uclibc, no new regressions.
I can also confirm that the pattern is now used as expected in
the case where I previously had an issue. Thanks for fixing that!
Committed to master.
--
Thanks.
-- Max
struc-
> tion idioms described in the Xtensa ISA reference manual (p. 600).
> ---
> gcc/config/xtensa/xtensa.md | 52 +
> 1 file changed, 52 insertions(+)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed to master.
--
Thanks.
-- Max
rtx_code_label *label;
> + if (rtx_equal_p (operands[0], operands[1])
> + || rtx_equal_p (operands[0], operands[2])
> + || ! REG_P (operands[1]) || ! REG_P (operands[2]))
I wonder if these additional conditions are necessary, given that
the operands have the "register_operand" predicates?
--
Thanks.
-- Max
rtran build, all
with the similar diagnostic:
gcc/libgfortran/intrinsics/erfc_scaled_inc.c:179:1: error: unrecognizable insn:
179 | }
| ^
(insn 23 22 24 2 (set (reg:CC 18 b0)
(lt:CC (const_double:SF 0.0 [0x0.0p+0])
(reg/v:SF 96 [ x ])))
"gcc/libgfortran/intrinsics/erfc_scaled_inc.c":111:18 -1
(nil))
during RTL pass: vregs
--
Thanks.
-- Max
IN, *eqne_INT_MIN):
> New insn_and_split patterns.
> ---
> gcc/config/xtensa/xtensa.md | 64 +
> 1 file changed, 64 insertions(+)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed to master.
--
Thanks.
-- Max
fig/xtensa/xtensa.md | 53 +
> 3 files changed, 106 insertions(+), 9 deletions(-)
This version performs much better than v1, but there's still new
testsuite failure in the gcc.c-torture/execute/bitfld-3.c
and the following change in the generated code
from:
l32i.n a11, a7, 8
l8uia9, a7, 12
movia10, 0xff
add.n a9, a9, a10
addi.n a7, a11, -1
movi.n a10, 1
movi.n a6, 0
moveqz a10, a6, a11
to:
l32i.n a10, a7, 8
l8uia9, a7, 12
movia11, 0xff
add.n a9, a9, a11
addi.n a7, a10, -1
movi.n a11, 1
mov.n a10, a11
movnez a10, a11, a11
suggests that the pattern movsicc_ne0_reg_zero does not work correctly
when its operands overlap.
--
Thanks.
-- Max
On Mon, Jun 5, 2023 at 8:15 AM Max Filippov wrote:
>
> Hi Suwa-san,
>
> On Mon, Jun 5, 2023 at 2:37 AM Takayuki 'January June' Suwa
> wrote:
> >
> > This patch optimizes the boolean evaluation of EQ/NE against zero
> > by adding two insn_and_split patte
gt; +XTENSA_CPU_CPP_BUILTIN(XTENSA_MARCH_EARLIEST);
> \
> +XTENSA_CPU_CPP_BUILTIN(XCHAL_HAVE_CLAMPS);
> \
> +XTENSA_CPU_CPP_BUILTIN(XCHAL_HAVE_DEPBITS);
> \
> +XTENSA_CPU_CPP_BUILTIN(XCHAL_HAVE_EXCLUSIVE);
> \
> +XTENSA_CPU_CPP_BUILTIN(XCHAL_HAVE_XEA3);
> \
>} while (0)
>
> #define CPP_SPEC " %(subtarget_cpp_spec) "
> --
> 2.34.1
>
--
Thanks.
-- Max
ctive values.
Just notice that it adds two leading underscores in front of the names.
> But the value must be set to make it work correctly.
> It uses builtin_define() instead builtin_define_with_int_value()
>
> I will check how it could be soved with the loop approach.
--
Thanks.
-- Max
ts for keeping backwards
compatibility with the overlay-based configuration method (:
I did the same for the uClibc, but the change is still in my queue:
https://github.com/jcmvbkbc/uclibc-ng-xtensa/commit/842aede0537812a0d2158433c5e048ee87324075
--
Thanks.
-- Max
On Thu, Jul 20, 2023 at 10:45 AM Alexey Lapshin
wrote:
>
> On Thu, 2023-07-20 at 08:25 -0700, Max Filippov wrote:
> > But it defines them with their respective values.
> > Just notice that it adds two leading underscores in front of the names.
>
> Why builtin macros
als.
--
Thanks.
-- Max
n order to catch the issue.
> ---
> gcc/config/xtensa/xtensa.md | 35 +--
> .../gcc.target/xtensa/constsynth_double.c | 2 +-
> 2 files changed, 9 insertions(+), 28 deletions(-)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed to master.
--
Thanks.
-- Max
the seed into a Narrow Move Immediate instruction "MOVI.N"
> when the Code Density Option is configured.
> ---
> gcc/config/xtensa/xtensa.cc | 58 ++---
> 1 file changed, 29 insertions(+), 29 deletions(-)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed to master.
--
Thanks.
-- Max
ecause the comparison
> expressions that don't satisfy such checks are determined as
> compile-time constants and thus will be optimized away before
> RTL expansion.
> ---
> gcc/config/xtensa/xtensa.md | 73 ++---
> 1 file changed, 44 insertions(+), 29 deletions(-)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed to master.
--
Thanks.
-- Max
ged, 1 insertion(+), 1 deletion(-)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed to master.
--
Thanks.
-- Max
nsertions(+)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed to master.
--
Thanks.
-- Max
---
> gcc/config/xtensa/xtensa.cc | 1 +
> 1 file changed, 1 insertion(+)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed to master.
--
Thanks.
-- Max
s(+), 5 deletions(-)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed to master.
--
Thanks.
-- Max
nsa-linux-uclibc, no new regressions.
Committed to master.
--
Thanks.
-- Max
a_constantsynth_2insn):
> Add new pattern for the abovementioned case.
> ---
> gcc/config/xtensa/xtensa.cc | 12 ++--
> 1 file changed, 10 insertions(+), 2 deletions(-)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed to master.
--
Thanks.
-- Max
inux-uclibc, no new regressions.
Committed to master.
--
Thanks.
-- Max
ed, 1 insertion(+), 1 deletion(-)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed to master.
--
Thanks.
-- Max
clibc, no new regressions.
Committed to master.
--
Thanks.
-- Max
; + int array[1]; /* requires large stack. */
> + foo();
> + asm volatile("" : : "m"(array));
> + return a;
> +}
> +
> +/* register A15 is the reservoir of the stack pointer and cannot be
> eliminated if the frame pointer is needed.
> + other registers still can be, but through the frame pointer rather the
> stack pointer. */
> +int test2(int a) {
> + int* p = __builtin_alloca(16);
> + foo();
> + asm volatile("" : : "r"(p));
> + return a;
> +}
> +
> +/* in -O0 the composite hard registers may still remain unsplitted at
> pro_and_epilogue and must be excluded. */
> +extern double bar(void);
> +int __attribute__((optimize(0))) test3(int a) {
> + return bar() + a;
> +}
> +
> +/* { dg-final { scan-assembler-times "mov\t|mov.n\t" 21 } } */
This test looks quite fragile as the number of movs would vary
when the testsuite is run with additional options.
> +/* { dg-final { scan-assembler-times "a15, 8" 2 } } */
> --
> 2.30.2
--
Thanks.
-- Max
clibc, no new regressions.
Committed to master.
--
Thanks.
-- Max
gcc/
PR target/108876
* config/xtensa/xtensa.cc (xtensa_expand_epilogue): Drop emit_use
for A0_REG.
* config/xtensa/xtensa.md (sibcall, sibcall_internal)
(sibcall_value, sibcall_value_internal): Add 'use' expression
for A0_REG.
---
gcc/config/xtensa/
xtensa/xtensa.md | 12 ++--
> 1 file changed, 6 insertions(+), 6 deletions(-)
Regtested for target=xtensa-linux-uclibc, no new regressions.
Committed to master.
--
Thanks.
-- Max
same place as (return) in the normal call).
> * config/xtensa/xtensa.md
> (sibcall, sibcall_internal, sibcall_value, sibcall_value_internal):
> Revert changes by the previous patch.
> ---
> gcc/config/xtensa/xtensa.cc | 4 +++-
> gcc/config/xtensa/xtensa.md | 20 +++-
> 2 files changed, 10 insertions(+), 14 deletions(-)
I've reverted my fix and committed this fix minus the revert.
--
Thanks.
-- Max
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
This reverts commit b2ef02e8cbbaf95fee98be255f697f47193960ec.
---
gcc/config/xtensa/xtensa.cc | 2 ++
gcc/config/xtensa/xtensa.md | 20 +++-
2 files changed, 9 insertions(+), 13 deletions(-)
diff --git a/gcc/config/xtensa/xtensa.cc b/gcc/config/xtensa/xtensa.cc
index 5c1c713e122d
101 - 200 of 353 matches
Mail list logo