[ranger] Fix wrong code for boolean negation in condition at -O

2020-11-09 Thread Eric Botcazou
it is not also changed. Given that the ranger turns bitwise AND/OR into logical AND/OR for booleans, the patch does the same for bitwise NOT, exactly as in the above fix. Bootstrapped/regtested on x86-64/Linux, OK for the mainline? 2020-11-09 Eric Botcazou * range-op.cc (opera

Re: [PATCH] Better __ashlDI3, __ashrDI3 and __lshrDI3 functions, plus fixed __bswapsi2 function

2020-11-10 Thread Eric Botcazou
re precisely meant to be used when GCC cannot do that. -- Eric Botcazou

[Ada] Fix internal error with Shift_Right operator on signed type

2020-11-11 Thread Eric Botcazou
This is a regression present on the mainline and 10 branch in the form of an ICE with a shift operator applied to a variable of a signed type, and which is caused by a type mismatch. Tested on x86-64/Linux, applied on the mainline and 10 branch. 2020-11-11 Eric Botcazou * gcc

[Ada] Fix internal error on chain of constants with -gnatc

2020-11-11 Thread Eric Botcazou
This is a rather obscure case not really worth commenting. :-) Tested on x86-64/Linux, applied on the mainline. 2020-11-11 Eric Botcazou * gcc-interface/decl.c (gnat_to_gnu_entity) : In case the constant is not being defined, get the expression in type annotation

[Ada] Fix segfault on elaboration of empty 1-element array at -O

2020-11-11 Thread Eric Botcazou
This is another rather obscure case where the elaboration of an empty array whose base type is an array type of length at most 1 goes awry when the code is compiled with optimization. Tested on x86-64/Linux, applied on the mainline, 10 and 9 branches. 2020-11-11 Eric Botcazou

[Ada] Fix biased integer arithmetic

2020-11-11 Thread Eric Botcazou
The Ada compiler uses a biased representation when a size clause reserves fewer bits than normal either for the lower or for the upper bound. Tested on x86-64/Linux, applied on the mainline, 10 and 9 branches. 2020-11-11 Eric Botcazou * gcc-interface/trans.c (build_binary_op_trapv

[patch] Enhance debug info for fixed-point types

2020-11-11 Thread Eric Botcazou
that we would need to lift in order to be able to represent more fixed-point types. Since it's only used by the Ada compiler, this is probably non-controversial but someone still needs to approve the change. Thanks in advance. 2020-11-11 Eric Botcazou * dwarf2out.h (s

Re: [Ping][GCC][IRA] Revert 11b8091fb to fix Bug 93221

2020-01-28 Thread Eric Botcazou
> Ping! Eric, do you have any objections to reverting? See my comment posted in the audit trail of the TN on 01/20... -- Eric Botcazou

Re: [cris-decc0 0/14] A set of compare-elimination-fixes.

2020-02-12 Thread Eric Botcazou
erall, with sporadic regressions in delay slot filling. The transition to LRA looks more problematic. -- Eric Botcazou

[SPARC] Fix PR target/93704

2020-02-14 Thread Eric Botcazou
assembler. So if the compiler is configured with the GNU assembler and the Solaris linker, then TARGET_GNU_TLS is set instead and the limitation is not enforced. Tested on SPARC/Solaris and SPARC64/Linux, applied on all active branches. 2020-02-14 Eric Botcazou PR target/93704

[c-family] Fix duplicates for anonymous structures with -fdump-ada-spec

2020-02-14 Thread Eric Botcazou
. 2020-02-14 Eric Botcazou * c-ada-spec.c: Include bitmap.h. (dump_ada_double_name): Rename into... (dump_anonymous_type_name): ...this. Always use the TYPE_UID. (dump_ada_array_type): Adjust to above renaming. Robustify. (dump_nested_types_1): New

[patch] Fix debug info for packed array types in Ada

2021-09-03 Thread Eric Botcazou
for: FAIL: gdb.ada/arrayptr.exp: scenario=minimal: print pa_ptr.all FAIL: gdb.ada/arrayptr.exp: scenario=minimal: print pa_ptr.all(3) in the GDB testsuite. Tested on x86-64/Linux, both GCC and GDB, OK for the mainline? 2021-09-03 Eric Botcazou * dwarf2out.c (modified_type_die

[i386] Fix PR C++/64697

2021-09-03 Thread Eric Botcazou
call_ZTH1s and the cmpq keeps a relocation that does not overflow. Tested on x86-64/Windows, OK for mainline, 11 and 10 branches? 2021-09-03 Eric Botcazou * config/i386/i386.c (legitimate_pic_address_disp_p): For PE-COFF, do not return true for external weak function

[c-family] Improve compatibility of -fdump-ada-spec with warnings

2021-09-03 Thread Eric Botcazou
This makes sure that the style and warning settings used in the C/C++ bindings generated by -fdump-ada-spec do not leak into the units that use them. Tested on x86-64/Linux, applied on the mainline. 2021-09-03 Eric Botcazou c-family/ * c-ada-spec.c (dump_ads): Generate pragmas to

Re: [patch] Fix debug info for packed array types in Ada

2021-09-06 Thread Eric Botcazou
> OK, I suppose this should also help some Fortran array descriptor cases? Thanks. This changes something only if array types in the source code are not always represented by ARRAY_TYPEs in the IR. -- Eric Botcazou

[patch] Fix PR debug/101947

2021-09-07 Thread Eric Botcazou
mainline? 2021-09-07 Eric Botcazou PR debug/101947 * dwarf2out.c (mark_base_types): New overloaded function. (dwarf2out_early_finish): Invoke it on the COMDAT type list as well as the compilation unit, and call move_marked_base_types afterward. -- Eric Botcazoudiff

Re: [patch] Fix PR debug/101947

2021-09-07 Thread Eric Botcazou
ble this way though and it's the same idiom as in prune_unused_types and dwarf2out_finish so I'm leaving it as-is. -- Eric Botcazou

[Ada] Give more informative error message for by-reference types

2021-09-14 Thread Eric Botcazou
Recent compilers enforce more strictly the RM C.6(18) clause, which says that volatile record types are by-reference types. This changes the typical error message now given in these cases. Tested on x86-64/Linux, applied on the mainline, 11 and 10 branches. 2021-09-14 Eric Botcazou

[Ada] Implement PR ada/101385

2021-09-14 Thread Eric Botcazou
For the sake of consistency with -Wall & -w, this makes -Werror imply -gnatwe. Tested on x86-64/Linux, applied on the mainline. 2021-09-14 Eric Botcazou PR ada/101385 * doc/gnat_ugn/building_executable_programs_with_gnat.rst (-Wall): Minor fixes.

[Ada] Strengthen compatibility warning for GCC builtins

2021-09-14 Thread Eric Botcazou
This is necessary for vector builtins, which are picky about the signedness of the element type. Tested on x86-64/Linux, applied on the mainline. 2021-09-14 Eric Botcazou * libgnat/s-atopri.ads (bool): Delete. (Atomic_Test_And_Set): Replace bool with Boolean

[Ada] Fix inaccurate bounds in debug info for vector array types

2021-09-14 Thread Eric Botcazou
They should not be 0-based, unless the array type itself is. Tested on x86-64/Linux, applied on the mainline, 11 and 10 branches. 2021-09-14 Eric Botcazou * gcc-interface/decl.c (gnat_to_gnu_entity): For vector types, make the representative array the debug type. -- Eric

[Ada] Fix PR ada/101970

2021-09-14 Thread Eric Botcazou
This is a regression present on the mainline and 11 branch in the form of an ICE for an enumeration type with a full signed representation for its size. Tested on x86-64/Linux, applied on the mainline and 11 branch. 2021-09-14 Eric Botcazou PR ada/101970 * exp_attr.adb

Re: [PATCH] sparc: Add scheduling information for LEON5

2021-09-15 Thread Eric Botcazou
sparc/leon5.md: New file. OK for whatever branches you deem relevant, modulo a couple of nits: > +;; Avoid scheduling load/store, FPU, and multiplication instructions back and multiply instructions > +;; Schedule three instructions between load and dependant instruction. dependent -- Eric Botcazou

Re: [PATCH] sparc: Print out bit names for LEON and LEON3 with -mdebug

2021-09-15 Thread Eric Botcazou
> gcc/ChangeLog: > > * config/sparc/sparc.c (dump_target_flag_bits): Print bit names for > LEON and LEON3. OK everywhere. -- Eric Botcazou

Re: [PATCH 1/4] sparc: Treat more instructions as load or store in errata workarounds

2021-09-15 Thread Eric Botcazou
avoid the multiple calls to get_attr_type? See div_sqrt_insn_p and fpop_insn_p for a model. -- Eric Botcazou

Re: [PATCH 2/4] sparc: Skip all empty assembly statements

2021-09-15 Thread Eric Botcazou
Likewise. > + || (USEFUL_INSN_P (insn) > + && (asm_noperands (PATTERN (insn))>=0) Missing spaces around >= > +{ > + insn = next_active_insn (insn); > +} Superfluous curly braces, even for readability. -- Eric Botcazou

Re: [PATCH 3/4] sparc: Prevent atomic instructions in beginning of functions for UT700

2021-09-15 Thread Eric Botcazou
> gcc/ChangeLog: > > * config/sparc/sparc.c (sparc_do_work_around_errata): Do not begin > functions with atomic instruction in the UT700 errata workaround. OK everywhere. -- Eric Botcazou

Re: [PATCH 4/4] sparc: Add NOP in stack_protect_setsi if sparc_fix_b2bst enabled

2021-09-15 Thread Eric Botcazou
set32 on mainline and stack_protect_setsi before. -- Eric Botcazou

[patch] Fix PR rtl-optimization/102306

2021-09-16 Thread Eric Botcazou
ons, which is of course not the case here. So the fix teaches try_combine to abort the combination when it is about to make a copy of volatile references to preserve them. Bootstrapped/regtested on x86-64/Linux, OK for mainline and release branches? 2021-09-16 Eric Botcazou PR

[ping] Fix PR C++/64697

2021-09-20 Thread Eric Botcazou
This fixes a regression for MinGW with recent binutils: https://gcc.gnu.org/pipermail/gcc-patches/2021-September/578756.html Thanks in advance. -- Eric Botcazou

[testsuite] Fix no_fsanitize_address effective target

2021-09-21 Thread Eric Botcazou
d failures 1011 -# of unsupported tests 2631 +# of unsupported tests 2628 and properly disabling them on SPARC64/Linux. Applied on the mainline, 11 and 10 branches as obvious. 2021-09-21 Eric Botcazou * lib/target-supports.exp (no_fsanitize_address): Add mi

Re: [PATCH] Fix ICE during MEM_REF expansion (PR middle-end/90840)

2019-12-07 Thread Eric Botcazou
innermode || GET_MODE (op) == VOIDmode); so we can equivalently pass GET_MODE (result) as the mode, except when it is VOIDmode in which case we can still use TYPE_MODE (TREE_TYPE (from)). Tested on PowerPC64/VxWorks and x86-64/Linux, applied on mainline as obvious. 2019-12-07 Eric

[patch] Fix ICE on VLA in LTO mode

2019-12-09 Thread Eric Botcazou
ne and 9 branch? 2019-12-09 Eric Botcazou * tree.c (build_array_type_1): Add SET_CANONICAL parameter and compute TYPE_CANONICAL from the element type only if it is set. Remove obsolete lines and adjust recursive call. (fld_process_array_type): Adju

Re: [PATCH] Fix unrecognizable insn of pr92865

2019-12-10 Thread Eric Botcazou
> No gcc/ or gcc/testsuite/ prefixes in ChangeLog. And 2 different ChangeLogs: ChangeLog and testsuite/ChangeLog. -- Eric Botcazou

[patch] Use simple LRA algorithm at -O0

2019-12-17 Thread Eric Botcazou
on is disabled. The effect on code size is tiny (typically 0.2% on x86). Tested on x86_64-suse-linux, OK for the mainline? 2019-12-17 Eric Botcazou * ira.c (ira): Use simple LRA algorithm when not optimizing. -- Eric BotcazouIndex:

[Ada] Small tweak to pragma Warnings (On)

2019-12-18 Thread Eric Botcazou
-suse-linux, applied on the mainline. 2019-12-18 Eric Botcazou * gcc-interface/trans.c (Pragma_to_gnu) : Push a diagnostics state for pragma Warnings (Off) before turning off all the warnings and only pop it for pragma Warnings (On). 2019-12-18 Eric Botcazou

Re: [PATCH 2/2] libada: Respect `--enable-version-specific-runtime-libs'

2019-12-18 Thread Eric Botcazou
* configure: Regenerate. This breaks with --disable-libada because $(toolexeclibdir) is not set. -- Eric Botcazou

Re: [patch] Use simple LRA algorithm at -O0

2019-12-19 Thread Eric Botcazou
es. We have been using it with a GCC 9 compiler for some time, without any problem so far. -- Eric Botcazou

Re: [PATCH 2/2] libada: Respect `--enable-version-specific-runtime-libs'

2019-12-20 Thread Eric Botcazou
anyway, as shared libgnat and libgnarl libraries are not built > in this case, so $(toolexeclibdir) is not supposed to be used. Yes, shared libraries are built with "make -C gcc gnatlib-shared gnattools". -- Eric Botcazou

[patch] Fix small glitch with -fdump-ada-spec

2019-12-20 Thread Eric Botcazou
on the mainline. 2019-12-20 Eric Botcazou c-family/ * c-ada-spec.h (decl_sloc): Delete. * c-ada-spec.c (decl_sloc): Make static. c/ * c-decl.c (collect_source_ref_cb): Delete. (for_each_global_decl): Rename into... (collect_source_refs): ...this. Call

Re: [PATCH] libada: Fix shared library installation with `--disable-libada'

2019-12-21 Thread Eric Botcazou
> Fixed thus, and verified with and without `--disable-libada', ensuring > that shared libgnat and libgnarl libraries arrive at their intended places > upon `make install'. > > OK to apply? Yes (modulo s/overriden/overridden), thanks for the quick turn around. -- Eric Botcazou

Re: [PATCH] Fix endless loop in find_single_def_src (PR rtl-optimization/93088)

2020-01-03 Thread Eric Botcazou
to first uses. > > * gcc.target/i386/pr93088.c: New test. OK with me, thanks. -- Eric Botcazou

Re: [PATCH] Fix spelling of ones' complement.

2021-11-16 Thread Eric Botcazou
nge them all or you change none, any intermediate stage is worse than the current situation, which is probably OK for 99.99% of people. -- Eric Botcazou

[Ada] Use EXACT_DIV_EXPR as much as possible

2021-05-21 Thread Eric Botcazou
...when the division is exact, typically dividing TYPE_SIZE by BITS_PER_UNIT. Tested on x86-64/Linux, applied on the mainline. 2021-05-21 Eric Botcazou * gcc-interface/decl.c (gnat_to_gnu_entity) : Replace CEIL_DIV_EXPR with EXACT_DIV_EXPR. * gcc-interface/misc.c

[Ada] Fix incorrect SLOC on instruction

2021-05-21 Thread Eric Botcazou
This puts the missing SLOC on a statement generated by a return. Tested on x86-64/Linux, applied on the mainline, 11 and 10 branches. 2021-05-21 Eric Botcazou * gcc-interface/trans.c (gnat_to_gnu) : Put a SLOC on the assignment from the return value to the return

[Ada] Fix spurious No_Elaboration violation for Size attribute

2021-05-21 Thread Eric Botcazou
We optimize the associated range check but nevertheless flag a violation. Tested on x86-64/Linux, applied on the mainline. 2021-05-21 Eric Botcazou * gcc-interface/trans.c (Call_to_gnu): Minor tweaks. (gnat_to_gnu_external): Likewise. (Raise_Error_to_gnu): Return an

[Ada] Fix segfault at run time on strict-alignment platforms

2021-05-21 Thread Eric Botcazou
This fixes a regression present on the mainline and 11 branch by restricting the problematic change dealing with bitfields whose nomimal subtype is self- referential to the cases where the size is really lower. Tested on x86-64/Linux, applied on the mainline and 11 branch. 2021-05-21 Eric

[Ada] Always translate Is_Pure flag into pure in C sense

2021-05-21 Thread Eric Botcazou
s. 2021-05-21 Eric Botcazou * gcc-interface/decl.c (gnat_to_gnu_subprog_type): Always translate the Is_Pure flag into the "pure" attribute of GNU C. -- Eric Botcazoudiff --git a/gcc/ada/gcc-interface/decl.c b/gcc/ada/gcc-interface/decl.c index a7595cbf514..19e851f

[Ada] Fix internal error on locally derived bit-packed array type

2021-05-21 Thread Eric Botcazou
This is a regression present on the mainline, 11 and 10 branches, in the form of an ICE on a locally derived bit-packed array type. Tested on x86-64/Linux, applied on the mainline, 11 and 10 branches. 2021-05-21 Eric Botcazou * gcc-interface/decl.c (gnat_to_gnu_entity) : Process

[Ada] Replace ? with ?? in warning messages

2021-05-21 Thread Eric Botcazou
The former has been deprecated in favor of the latter. Tested on x86-64/Linux, applied on the mainline. 2021-05-21 Ghjuvan Lacambre * gcc-interface/decl.c (gnat_to_gnu_entity): Replace ? with ??. (gnat_to_gnu_param): Likewise. (gnat_to_gnu_subprog_type): Likewise.

[Ada] Consistently generate debug info for elaboration variables

2021-05-21 Thread Eric Botcazou
This makes sure that debug info is generated for elaboration variables, even if the variables are not generated exclusively for this purpose. Tested on x86-64/Linux, applied on the mainline. 2021-05-21 Eric Botcazou * gcc-interface/decl.c (gnat_to_gnu_entity) : Do not pass

[Ada] Detect illegal conditions in Raise_xxx_Error nodes

2021-05-21 Thread Eric Botcazou
. -- Eric Botcazou

Re: [Ada] Detect illegal conditions in Raise_xxx_Error nodes

2021-05-21 Thread Eric Botcazou
> 2021-05-21 Piotr Trojanek > > * gcc-interface/trans.c (Raise_Error_to_gnu): Add an assertion. -- Eric Botcazoudiff --git a/gcc/ada/gcc-interface/trans.c b/gcc/ada/gcc-interface/trans.c index 289a2efcaf1..ee014a35cc2 100644 --- a/gcc/ada/gcc-interface/trans.c +++ b/gcc/ada/gcc-interfac

Re: [PATCH 2/11] use xxx_no_warning APIs in Ada

2021-05-25 Thread Eric Botcazou
> [PATCH 2/11] use xxx_no_warning APIs in Ada. Looks good to me, but remove the useless pair of parentheses in the 3rd hunk. -- Eric Botcazou

Re: [PATCH] tree-sra: Avoid refreshing into const base decls (PR 100453)

2021-05-25 Thread Eric Botcazou
> The problem with this patch is that it causes: > > FAIL: gnat.dg/opt94.adb scan-tree-dump-times optimized "worker" 1 > > which is exactly the testcase from the commit which caused the bug I am > trying to address. Sorry about that, a thinko in the original change, I'm testing this fixlet.

[c++tools] Fix typo and weird syntax in configure script

2021-05-25 Thread Eric Botcazou
Tested on x86-64/Linux, applied on mainline and 11 branch as obvious. 2021-05-25 Eric Botcazou c++tools/ * configure.ac (--enable-maintainer-mode): Fix typo and weird syntax. * configure: Regenerate. -- Eric Botcazoudiff --git a/c++tools/configure.ac b/c++tools/configure.ac

Re: [PATCH] tree-sra: Avoid refreshing into const base decls (PR 100453)

2021-05-25 Thread Eric Botcazou
> LGTM. Thanks, but a bit too bold because gimplify_and_add can promote the non-static DECL to static memory and reinstate DECL_INITIAL, so first hunk adjusted. * gimplify.c (gimplify_decl_expr): Clear TREE_READONLY on the DECL when really creating an initialization statement fo

Re: [PATCH] tree-sra: Avoid refreshing into const base decls (PR 100453)

2021-05-26 Thread Eric Botcazou
> * gimplify.c (gimplify_decl_expr): Clear TREE_READONLY on the DECL > when really creating an initialization statement for it. Quite an interesting can of worms I have opened it seems. :-( So the change apparently causes OMP lowering to create dangling references, I have applied t

[C] Warn on type punning that toggles scalar storage order

2021-05-26 Thread Eric Botcazou
Hi, As documented in the manual, we do not support type punning that toggles the scalar storage order, so this adds a warning for the simple case of unions. Tested on x86-64/Linux, OK for the mainline? 2021-05-26 Eric Botcazou PR c/100653 * c-decl.c (finish_struct): Warn

Re: [r12-1053 Regression] FAIL: libgomp.c++/task-reduction-8.C execution test on Linux/x86_64

2021-05-26 Thread Eric Botcazou
rences apparently, hence the random outcome. -- Eric Botcazou

Re: [C] Warn on type punning that toggles scalar storage order

2021-05-26 Thread Eric Botcazou
> OK Thanks. I have also installed the attached tweak to the documentation. PR c/100653 * doc/extend.texi (scalar_storage_order): Rephrase slightly. -- Eric Botcazoudiff --git a/gcc/doc/extend.texi b/gcc/doc/extend.texi index 3ddeb0dee3a..bfe9c21bddf 100644 --- a/gcc/doc/exten

[DWARF] Also generate DW_OP_GNU_variable_value at file scope

2021-05-28 Thread Eric Botcazou
But only for the reference variant (dw_val_class_die_ref). This is needed for variable-sized types declared at library level in Ada. Tested on x86-64/Linux, both GCC and GDB, OK for the mainline? 2021-05-28 Eric Botcazou * dwarf2out.c (loc_list_from_tree_1) : Also generate

[DWARF] Couple of pending patches

2021-06-01 Thread Eric Botcazou
the last step before we can drop the historical GNAT encodings in favor of (GNU) DWARF. Thanks in advance. -- Eric Botcazou

[patch] Tame fix for PR ipa/99122

2021-06-02 Thread Eric Botcazou
Hi, as explained in the audit trail, the return part has a major performance impact in Ada where variable-sized types are first-class citizens, but it turns out that it is not exercized in the testsuite yet. Tested on x86-64/Linux, OK for mainline and 11 branch? 2021-06-02 Eric Botcazou

Re: [patch] Tame fix for PR ipa/99122

2021-06-03 Thread Eric Botcazou
returned bytes on a case-by-case basis; when the size is uniform, this complication is unnecessary. > As for the patch we indeed didn't have a testcase covering the > return case so it should be safe to revert the return part. OK, thanks, patch installed. -- Eric Botcazou

[Ada] Fix miscompilation of predicate on bit-packed array types

2021-06-03 Thread Eric Botcazou
array types. Tested on x86-64/Linux, applied on the mainline. 2021-06-03 Eric Botcazou * gcc-interface/decl.c (gnat_to_gnu_entity) : Add PAT local constant and use it throughout. If it is set, use a ref-all pointer type for the pointer-to-array field of the fat pointer

[c-family] Fix issue for external subtypes with -fdump-ada-spec

2021-06-03 Thread Eric Botcazou
This works around an irregularity of the language whereby subtypes, unlike types, are not visible through a limited_with clause. Tested on x86-64/Linux, applied on the mainline. 2021-06-03 Eric Botcazou c-family/ * c-ada-spec.c (pp_ada_tree_identifier): Tidy up

[c-family] Fix issue for nested record types with -fdump-ada-spec

2021-06-03 Thread Eric Botcazou
Ada does not support anonymous record declarations nested in other record declarations so -fdump-ada-spec needs to unnest them, and this contains a few fixes for this machinery. Tested on x86-64/Linux, applied on the mainline. 2021-06-03 Eric Botcazou c-family/ * c-ada-spec.c

[c-family] Fix duplicate name issues in output of -fdump-ada-spec

2021-06-03 Thread Eric Botcazou
The namespace rules are different in the C family of languages and in Ada, and a few adjustments are further needed in -fdump-ada-spec because of them. Tested on x86-64/Linux, applied on the mainline. 2021-06-03 Eric Botcazou c-family/ * c-ada-spec.c (dump_ada_enum_type): Dump a

Re: [PATCH] libgcc: Fix _Unwind_Backtrace() for SEH

2021-06-04 Thread Eric Botcazou
ack. https://gcc.gnu.org/pipermail/gcc-patches/2020-September/553418.html -- Eric Botcazou

[C] Fix thinko in new warning on type punning for storage order purposes

2021-06-06 Thread Eric Botcazou
. Tested on x86-64/Linux, applied on the mainline as obvious. 2021-06-06 Eric Botcazou PR c/100920 * c-decl.c (finish_struct): Fix thinko in previous change. * c-typeck.c (convert_for_assignment): Do not warn on pointer assignment and initialization for storage

[SPARC] Reimplement LEAF_REG_REMAP macro

2021-06-06 Thread Eric Botcazou
The current implementation as an array of chars is indeed a bit awkward so this reimplements it as a function taking and returning an int. Tested on SPARC/Solaris, applied on the mainline. 2021-06-06 Eric Botcazou * config/sparc/sparc-protos.h (order_regs_for_local_alloc): Rename

Re: [PATCH] ifcvt: Fix -fcompare-debug bug [PR100852]

2021-06-09 Thread Eric Botcazou
g++.dg/opt/pr100852.C: New test. This looks obvious to me, but OK. -- Eric Botcazou

Re: [patch] Reuse non-gimple_reg variable for inlining

2021-06-09 Thread Eric Botcazou
e TREE_READONLY marker in C/C++ if this is a lie. -- Eric Botcazou

Re: [PATCH] PR tree-optimization/38943: Preserve trapping instructions with -fnon-call-exceptions

2021-07-08 Thread Eric Botcazou
y Richard, EH is orthogonal to side effects and pure/const. -- Eric Botcazou

Fix PR target/101377

2021-07-09 Thread Eric Botcazou
_FLAG are defined and HAVE_LD_BROKEN_PE_DWARF5 is not with it. Tested on x86-64/Linux and x86[-64]/Windows, OK for mainline and 11 branch? 2021-07-07 Eric Botcazou PR target/101377 * gcc.c.c (ASM_DEBUG_DWARF_OPTION): Set again to --gdwarf2 if HAVE_AS_WORKING_DWARF_N_FL

Re: [Ada] Always translate Is_Pure flag into pure in C sense

2021-07-09 Thread Eric Botcazou
> Tested on x86-64/Linux, applied on the mainline, 11 and 10 branches. > > > 2021-05-21 Eric Botcazou > > * gcc-interface/decl.c (gnat_to_gnu_subprog_type): Always translate > the Is_Pure flag into the "pure" attribute of GNU C. This is the mis

Re: [PATCH take 2] PR tree-optimization/38943: Preserve trapping instructions with -fpreserve-traps

2021-07-12 Thread Eric Botcazou
ions? Or issue a warning that it requires -fexceptions if the latter is not enabled? -- Eric Botcazou

[DWARF] Fix signedness issue in DWARF functions (2)

2021-04-26 Thread Eric Botcazou
sizetype or bitsizetype quantities so that's unnecessarily cautious. Tested on x86-64/Linux, both GCC and GDB, OK for the mainline? 2021-04-26 Eric Botcazou * dwarf2out.c (loc_list_from_tree_1) : Do not bail out for sizetype and bitsizetype. -- Eric Botcazoudiff --git

[DWARF] Fix signedness issue in DWARF functions (1)

2021-04-26 Thread Eric Botcazou
ed on x86-64/Linux, both GCC and GDB, OK for the mainline? 2021-04-26 Eric Botcazou * dwarf2out.c (scompare_loc_descriptor): Fix head comment. (is_handled_procedure_type): Likewise. (struct loc_descr_context): Add strict_signedness field. (resolve_args_pick

Re: [DWARF] Fix signedness issue in DWARF functions (2)

2021-04-26 Thread Eric Botcazou
e); } break; This also looks incorrect if the size is larger than DWARF2_ADDR_SIZE then, isn't there a typo in the code? if (GET_MODE_SIZE (int_mode) < DWARF2_ADDR_SIZE) { op = DW_OP_div; goto do_binop; } -- Eric Botcazou

Re: [DWARF] Fix signedness issue in DWARF functions (2)

2021-04-27 Thread Eric Botcazou
> Yes, but even bitsizetype is undistinguishable from other (usually 2 * > pointer size) precision integral types. OK, I can propose the attached patch. The typed_binop_from_tree computation works on my Ada testcase in 32-bit mode from within GDB, but not in 64-bit mode because GDB chokes with:

[Ada] Fix loss of optimization of array iteration due to inlining

2021-04-28 Thread Eric Botcazou
This helps loop-invariant motion to hoist complicated offset computations. Tested on x86-64/Linux, applied on the mainline. 2021-04-28 Eric Botcazou * gcc-interface/trans.c (language_function): Add comment. (loop_info_d): Add fndecl and invariants fields

[Ada] Get rid of useless temporary for call to pure function

2021-04-28 Thread Eric Botcazou
This avoids creating a useless temporary for a call to a pure function with good properties by using the RSO. Tested on x86-64/Linux, applied on the mainline. 2021-04-28 Eric Botcazou * gcc-interface/trans.c (is_array_of_scalar_type): New predicate. (find_decls_r): New

[Ada] Avoid creating useless local bounds around calls

2021-04-28 Thread Eric Botcazou
This prevents the compiler from creating useless local bounds around calls that take a parameter of an unconstrained array type when the bounds already exist somewhere else for the actual parameter. Tested on x86-64/Linux, applied on the mainline. 2021-04-28 Eric Botcazou * gcc

[patch] Add parallelism support to gcov for MinGW platforms

2021-04-29 Thread Eric Botcazou
o a profiled bootstrap with -jN, N > 1, on these platforms. Tested on x86-64/Linux, x86-64/Windows and x86/Windows, OK for the mainline? 2021-04-29 Eric Botcazou libgcc/ * libgcc/libgcov.h: For the target, define GCOV_LOCKED_WITH_LOCKING if __MSVCRT__ and, for the host, def

[SPARC] Small housekeeping work

2021-04-29 Thread Eric Botcazou
Tested on SPARC/Solaris and SPARC64/Linux, applied on the mainline. 2021-04-29 Eric Botcazou * config/sparc/sparc.c (gen_load_pcrel_sym): Delete. (load_got_register): Do the PIC dance here. (sparc_legitimize_tls_address): Simplify

[patch] Generate debug info for local dynamic record types

2021-05-01 Thread Eric Botcazou
? 2021-05-01 Eric Botcazou * dwarf2out.c (loc_list_from_tree_1) : During early DWARF, do not expand the VALUE_EXPR of variables put in the non-local frame. * gimplify.c (gimplify_type_sizes) : If the type is not to be ignored for debug info, ensure its variable

[libiberty] Make test for variables more robust

2021-05-03 Thread Eric Botcazou
bcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` AC_DEFINE_UNQUOTED($n) else AC_MSG_RESULT(no) fi done because the assignment to 'p' is optimized away by LTO. This is visible on MinGW platforms in the form of a link failure for sys_siglist. Tested on x86-64/Linux,

[patch] Fix libiberty link failure in LTO mode

2021-05-03 Thread Eric Botcazou
kage to be resolved in LTO mode. Tested on x86-64/Linux, x86-64/Windows and x86/Windows, OK for the mainline? 2021-05-03 Eric Botcazou * builtins.c (builtin_with_linkage_p): Return true for stp[n]cpy. * symtab.c (symtab_node::output_to_lto_symbol_table_p): Tidy up. -- Eric Bo

[patch] Reuse non-gimple_reg variable for inlining

2021-05-03 Thread Eric Botcazou
needs to be prevented from creating a CLOBBER for the cases where it ends uo being reused. Tested on x86-64/Linux, OK for the mainline? 2021-05-03 Eric Botcazou * tree-inline.c (setup_one_parameter): Do not create a variable if the value is either a read-only DECL or a non

Re: [PATCH] Avoid DSE/DCE of pure call that throws

2021-05-03 Thread Eric Botcazou
function. -- Eric Botcazou

Re: [patch] Reuse non-gimple_reg variable for inlining

2021-05-03 Thread Eric Botcazou
> Hmm, instead of (ab-)using debug_map can we instead use sth like setting > TREE_VISITED on the argument decl (not the value - it might be passed > multiple tiimes)? IIRC TREE_VISITED state is undetermined thus we can > clear it at the start of setup_one_parameter and set it when we want to > avo

Re: [PATCH] Avoid DSE/DCE of pure call that throws

2021-05-04 Thread Eric Botcazou
on (like const function, but may read global memory). */ #define DECL_PURE_P(NODE) (FUNCTION_DECL_CHECK (NODE)>function_decl.pure_flag) Maybe: "Note that being pure or const for a function is orthogonal to being no-throw, i.e. it is valid to have DECL_PURE_P set and TREE_NOTHROW cleared". -- Eric Botcazou

Re: [PATCH] Remove CC0

2021-05-04 Thread Eric Botcazou
ow. I don't know if such splitting would directly > lead to the ability to remove the redundant compares - it might need a > new pass to spot them. Do you mean in addition to the existing pass_compare_elim_after_reload? -- Eric Botcazou

Re: [wwwdocs] Remove CC0 from backends.html

2021-05-04 Thread Eric Botcazou
> Pushed. What is next? :-) You can finally remove powerpcspe. :-) -- Eric Botcazou

Re: [patch] Generate debug info for local dynamic record types

2021-05-05 Thread Eric Botcazou
at-encodings=minimal but it's actually easy to check in DWARF 5. * gnat.dg/debug17.adb: New test. -- Eric Botcazou-- { dg-do compile } -- { dg-skip-if "No Dwarf" { { hppa*-*-hpux* } && { ! lp64 } } } -- { dg-options "-cargs -O0 -g -dA -fgnat-encodings=minimal -mar

Re: [PATCH] PR rtl-optimization/100263: Ensure register can change mode

2021-05-05 Thread Eric Botcazou
n > change mode. > > Bootstrapped and regtested releases/gcc-{8,9,10,11} and master on IBM Z. > Ok for those branches? Yes, OK everywhere, thanks. -- Eric Botcazou

[patch] Fix PR rtl-optimization/100411

2021-05-05 Thread Eric Botcazou
); the rest (CFG cleanup, BB reordering) is downhill from there. Tested on x86-64/Linux and x86-64/Windows, OK for mainline and 11 branch? 2021-05-05 Eric Botcazou PR rtl-optimization/100411 * cfgcleanup.c (try_crossjump_to_edge): Also skip end of prologue and beginning of

Re: [patch] Fix PR rtl-optimization/100411

2021-05-05 Thread Eric Botcazou
> I mean, can't we have just one while loop that skips over all debug insns, > NOTE_INSN_BASIC_BLOCK_P, NOTE_INSN_PROLOGUE_END and NOTE_INSN_FUNCTION_BEG > and stops on anything else, or, if we want to skip at most one of some or > all of those note kinds, do some tracking if we've already skipped

<    1   2   3   4   5   6   7   8   9   10   >