Re: [PATCH] S/390: Fix ICE in s390_check_qrst_address ()

2018-10-24 Thread Andreas Krebbel
On 24.10.18 13:06, Ilya Leoshkevich wrote: > Bootstrapped and regtested on s390x-redhat-linux. > > In r265371 (S/390: Make "b" constraint match literal pool references) > the CONSTANT_POOL_ADDRESS_P () check was moved from > s390_loadrelative_operand_p () to s390_check_qrst_address (). However, >

Re: [PATCH] S/390: Merge movdi_larl into movdi_64

2018-10-25 Thread Andreas Krebbel
On 25.10.18 16:00, Ilya Leoshkevich wrote: > Bootstrapped and regtested on s390x-redhat-linux. > > Consider the following RTL: > > (insn (set (mem/f/c:DI (reg/f:DI 60)) >(const:DI (plus:DI (symbol_ref:DI ("*.LANCHOR0")) > (const_int 8) > > generated

Re: [PATCH] S/390: Allow immediates in loc expander

2018-10-26 Thread Andreas Krebbel
On 10/26/18 5:31 PM, Robin Dapp wrote: > Hi, > > this is v2 of the patch. The Z13 check has been moved from the > predicate to the expander. In addition, it changes a test case to > always run with -march=zEC12 because from z13 on the load immediate on > condition will prevent loop hoisting that

Re: [PATCH] S/390: Add loc patterns for QImode and HImode

2018-10-26 Thread Andreas Krebbel
On 10/26/18 5:33 PM, Robin Dapp wrote: > Hi, > > this is v2 of the patch with less quirky pattern syntax and two tests. > > Regards > Robin > > -- > > gcc/ChangeLog: > > 2018-10-26 Robin Dapp > > * config/s390/s390.md: QImode and HImode for load on condition. > > gcc/testsuite/Chan

Re: [PATCH] S/390: Make tests expect column numbers in RTL output

2018-11-05 Thread Andreas Krebbel
On 05.11.18 17:32, Ilya Leoshkevich wrote: > RTL output now includes column numbers in addition to line numbers, > like this: > > "gcc/testsuite/gcc.target/s390/md/andc-splitter-1.c":16:1 > > This confuses some S/390 tests. > > gcc/testsuite/ChangeLog: > > 2018-11-05 Ilya Leoshkevich > >

Re: [PATCH] S/390: Increase register move costs for CC_REGS

2018-11-05 Thread Andreas Krebbel
On 05.11.18 15:38, Robin Dapp wrote: > Hi, > > the attached patch increases the move costs for moves involving the CC > register. This saves us some instructions in SPEC CPU2006. > > Regards > Robin > > -- > > gcc/ChangeLog: > > 2018-11-05 Robin Dapp > > * config/s390/s390.c (s390_

[Committed] S/390: Fix PR87723

2018-11-06 Thread Andreas Krebbel
Committed to mainline after successful bootstrapping and regression testing. gcc/ChangeLog: 2018-11-06 Andreas Krebbel PR target/87723 * config/s390/s390.md ("*rsbg_di_rotl"): Remove mode attributes for operands 3 and 4. gcc/testsuite/ChangeLog: 2018-11-0

Re: [PATCH] S/390: Accept cdb in load-and-test-fp-1 testcase

2018-11-06 Thread Andreas Krebbel
On 06.11.18 13:12, Ilya Leoshkevich wrote: > The compiler now generates cdb instead of cdbr for comparison with 0.0, > which looks like an improvement to me. > > gcc/testsuite/ChangeLog: > > 2018-11-06 Ilya Leoshkevich > > * gcc.target/s390/load-and-test-fp-1.c: Accept cdb. > --- > gcc

Re: [PATCH] S/390: Introduce relative_long attribute

2018-11-06 Thread Andreas Krebbel
On 05.11.18 15:18, Ilya Leoshkevich wrote: > In order to properly fix PR87762, we need to distinguish between > instructions which support relative addressing and instructions which > don't. We could check whether the existing "type" attribute is equal to > "larl", but there are notable exceptions

Re: [PATCH] S/390: Fix expectation in mrecord-mcount test for 31-bit mode

2018-11-14 Thread Andreas Krebbel
On 14.11.18 13:55, Ilya Leoshkevich wrote: > The emitted address is .long, not .quad, in that case. > > gcc/testsuite/ChangeLog: > > 2018-11-14 Ilya Leoshkevich > > * gcc.target/s390/mrecord-mcount.c (profileme): Expect .long in > 31-bit mode. Ok. Thanks! Andreas

Re: [PATCH] S/390: Disable 3 global-array-* tests for 31-bit mode

2018-11-14 Thread Andreas Krebbel
On 14.11.18 13:50, Ilya Leoshkevich wrote: > These tests rely on larl->movdi merge, which is not implemented for > 31-bit mode. > > gcc/testsuite/ChangeLog: > > 2018-11-14 Ilya Leoshkevich > > * gcc.target/s390/global-array-almost-huge-element.c: Run only > in 64-bit mode. >

Re: [PATCH] S/390: Add a new pattern for r{o,x}sbg

2018-11-16 Thread Andreas Krebbel
On 16.11.18 11:15, Ilya Leoshkevich wrote: > Bootstrapped and regtested on s390x-redhat-linux. > > Fixes rXsbg_mode_sXl test failures. > > Combine used to give us > > (set (reg:SI 65) > (ior:SI (lshiftrt:SI (reg:SI 3 %r3 [ bD.2238 ]) > (const_int 2 [0x2])) > (reg:SI 2 %r2

Re: [PATCH] S/390: Skip LT(G) peephole when literal pool is involved

2018-11-20 Thread Andreas Krebbel
On 19.11.18 17:08, Ilya Leoshkevich wrote: > Bootstrapped and regtested on s390x-redhat-linux. > > By the time peephole optimizations run, we've already made up our mind > whether to use base-register or relative addressing for literal pool > entries. LT(G) supports only base-register addressing,

[Committed] S/390: Fix flogr RTX.

2018-11-20 Thread Andreas Krebbel
n mainline. gcc/ChangeLog: 2018-11-20 Andreas Krebbel * config/s390/s390.md ("clztidi2"): Swap the RTX's written to the DImode parts of the target operand. gcc/testsuite/ChangeLog: 2018-11-20 Andreas Krebbel * gcc.target/s390/flogr-1.c: New test.

[Committed] S/390: Support vector load/store alignment hints

2018-11-20 Thread Andreas Krebbel
performance though. The attached testcase align-1 currently fails due to: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88085 Bootstrapped and regtested on s390x with z13 and z14 defaults. Committed to mainline gcc/ChangeLog: 2018-11-21 Andreas Krebbel * configure.ac: Add check for Binutils

Re: [PATCH] Fix tree-ssa/phi-opt-11.c on s390x (PR testsuite/85368)

2018-11-23 Thread Andreas Krebbel
On 22.11.18 20:56, Jakub Jelinek wrote: > Hi! > > This test apparently FAILs on s390x-linux, which is an effective target of > both logical_op_short_circuit and branch_cost. > The test has > /* { dg-additional-options "-mbranch-cost=2" { target branch_cost } } */ > and that option effectively make

[Committed] S/390: Document z14/arch12 -march option.

2018-11-26 Thread Andreas Krebbel
gcc/ChangeLog: 2018-11-26 Andreas Krebbel * doc/invoke.texi: Document z14/arch12 -march option. --- gcc/doc/invoke.texi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index 38e27a5..e70db55 100644 --- a/gcc/doc

[Committed] S/390: Fix vector shift count operand

2019-07-01 Thread Andreas Krebbel
hift count being applied. This patch needs to be applied to older branches as well. Bootstrapped and regression tested on s390x (IBM z14). Committed to mainline gcc/ChangeLog: 2019-07-01 Andreas Krebbel * config/s390/vector.md: gcc/testsuite/ChangeLog: 2019-07-01 Andre

Re: [Committed] S/390: Fix vector shift count operand

2019-07-01 Thread Andreas Krebbel
On 01.07.19 17:01, Marek Polacek wrote: > On Mon, Jul 01, 2019 at 04:58:09PM +0200, Andreas Krebbel wrote: >> We currently use subst definitions to handle the different variants of shift >> count operands. Unfortunately, in the vector shift pattern the shift count >> ope

Re: [09/11] [s390] Fix ambiguous .md attribute uses

2019-07-05 Thread Andreas Krebbel
On 05.07.19 17:22, Richard Sandiford wrote: > This patch is part of a series that fixes ambiguous attribute > uses in .md files, i.e. cases in which attributes didn't use > to specify an iterator, and in which could > have different values depending on the iterator chosen. > > The vx-builtins.md

Re: [PATCH 0/3] S/390: Shift count improvements.

2019-07-08 Thread Andreas Krebbel
On 06.07.19 22:53, Robin Dapp wrote: > Hi, > > these patches introduce a new predicate that recognizes > shift-count operands instead of the subst patterns we > used before. This allows introducing (no-op) subregs in > the patterns which was not possible via subst before > (see https://gcc.gnu.or

Re: [PATCH v2] S/390: Improve storing asan frame_pc

2019-07-09 Thread Andreas Krebbel
On 02.07.19 17:34, Ilya Leoshkevich wrote: ... > 2019-06-28 Ilya Leoshkevich > > * asan.c (asan_emit_stack_protection): Provide an alignment > hint. > * config/s390/s390.h (CODE_LABEL_BOUNDARY): Specify that s390 > requires code labels to be aligned on a 2-byte boundary.

[Committed] S/390: Add add/sub/mul overflow check patterns

2019-07-24 Thread Andreas Krebbel
This patch implements the addv, subv, and mulv patterns for signed integers. Bootstrapped and regression tested on s390x (IBM z14). Committed to mainline. gcc/ChangeLog: 2019-07-24 Andreas Krebbel * config/s390/predicates.md (addv_const_operand): New predicate. * config

Re: [PATCH] s390.md fixes for 32-bit host

2019-02-18 Thread Andreas Krebbel
On 16.02.19 18:52, Jakub Jelinek wrote: > Hi! > > While looking into PR89369, I've noticed various spots in s390.md > using 1ul or 1UL which might not work properly if the host is e.g. ilp32, > even even instead of using ULL constants it is better to use > HOST_WIDE_INT_* macros for HOST_WIDE_INT

Re: [PATCH] Fix s390 backend with old binutils (PR target/89361)

2019-02-18 Thread Andreas Krebbel
On 16.02.19 18:49, Jakub Jelinek wrote: > Hi! > > If S390_USE_TARGET_ATTRIBUTE is 0 (e.g. because of configuring against old > binutils or even with no binutils at all), then indirect jumps are emitted > unconditionally, no matter what is selected on the command line, including > the default optio

Re: [PATCH] Fix *rsbg_sidi_srl pattern (PR target/89369)

2019-02-18 Thread Andreas Krebbel
On 16.02.19 19:38, Jakub Jelinek wrote: > Hi! > > The following patch fixes wrong-code on the following testcase extracted > from pseudo-RNG with e.g. -march=zEC12 -O2. > The problem is in the instruction emitted by the *rsbg_sidi_srl > patterns. We have in *.final correct: > (insn 67 65 68 (para

[Committed] S/390: Fix immediate vector operands for some builtins.

2019-03-11 Thread Andreas Krebbel
. gcc/ChangeLog: 2019-03-11 Andreas Krebbel * config/s390/s390.c (s390_expand_builtin): Do the copy_to_reg not only on the else branch. gcc/testsuite/ChangeLog: 2019-03-11 Andreas Krebbel * gcc.target/s390/zvector/vec-addc-u128.c: New test. --- gcc/config/s390/s390.c

Re: [PATCH 0/7] S/390: Rework instruction scheduling.

2019-03-11 Thread Andreas Krebbel
On 11.03.19 13:53, Robin Dapp wrote: > Hi, > > this patch set adds new pipeline descriptions for z13 and z14. Based > on that, the scoring and some properties are handled differently in > the scheduler hooks. > > Regards > Robin > > Robin Dapp (7): > S/390: Change z13 pipeline description. >

Re: [PATCH] s390.md and tilepro.c diagnostics bug fix (PR target/52726)

2019-03-12 Thread Andreas Krebbel
On 12.03.19 10:58, Jakub Jelinek wrote: > 2019-03-12 Jakub Jelinek > > PR target/52726 > * config/s390/s390.md (tabort): Use %wd instead of > HOST_WIDE_INT_PRINT_DEC in error message, reword to avoid two capital > letters and periods. > * config/tilepro/tilepro.c (

Re: [PATCH] S/390: Perform more aggressive inlining

2019-03-12 Thread Andreas Krebbel
On 12.03.19 11:22, Robin Dapp wrote: > Hi, > > this patch sets the inlining parameters for z13 and later to rather > aggressive values in response to PR85103 that caused performance > regressions in SPEC2006's sjeng and gobmk benchmarks. > > Regards > Robin > > -- > > gcc/ChangeLog: > > 2019-

Re: [PATCH 0/7] S/390: Rework instruction scheduling.

2019-03-12 Thread Andreas Krebbel
On 12.03.19 11:00, Robin Dapp wrote: >> Please adjust the year and the author in gcc/config/s390/3906.md. Ok with >> that change. > > Changed that and also simplified the longrunning checks. > > gcc/ChangeLog: > > 2019-03-12 Robin Dapp > > * config/s390/s390.c (LONGRUNNING_THRESHOLD

Re: [PATCH 8/8] S/390: Change test case to reflect scheduling changes.

2019-03-12 Thread Andreas Krebbel
On 12.03.19 11:02, Robin Dapp wrote: > This fixes a newly introduced test failure. > > > --- > > 2019-03-12 Robin Dapp > > * gcc.target/s390/memset-1.c: Do not require stcy. > Ok. Thanks! Andreas

Re: [PATCH] S/390: Fix tests that expect unquoted option names

2019-03-15 Thread Andreas Krebbel
On 15.03.19 13:19, Robin Dapp wrote: > Hi, > > r269586 puts single quotes around option names. This patch fixes tests > that expect the old format. > > Regards > Robin > > --- > > gcc/testsuite/ChangeLog: > > 2019-03-15 Robin Dapp > > * gcc.target/s390/target-attribute/tattr-1.c (ht

[Committed] S/390: Fix PR89775. Stackpointer save/restore instructions removed

2019-03-20 Thread Andreas Krebbel
on s390x. gcc/ChangeLog: 2019-03-20 Andreas Krebbel PR target/89775 * config/s390/s390.c (global_not_special_regno_p): Move to make it available to ... (s390_optimize_register_info): Use global_not_special_regno_p to check for global regs. 2019-03-20

[Committed] S/390: Improve debug output for builtin matching

2019-03-25 Thread Andreas Krebbel
gcc/ChangeLog: 2019-03-25 Andreas Krebbel * config/s390/s390-c.c (s390_fn_types_compatible): Print the expected and found types with -mdebug during builtin matching. --- gcc/config/s390/s390-c.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/gcc

[Committed] S/390: Cleanup builtin types file

2019-03-25 Thread Andreas Krebbel
gcc/ChangeLog: 2019-03-25 Andreas Krebbel * config/s390/s390-builtin-types.def: Remove few unused types and fix sort order for others. --- gcc/config/s390/s390-builtin-types.def | 102 +++-- 1 file changed, 45 insertions(+), 57 deletions(-) diff

[PATCH 01/14] S/390: arch13: Add arch13 as architecture option

2019-04-02 Thread Andreas Krebbel
This patch enables the command line options and provides the proper macros for checking. gcc/ChangeLog: 2019-04-02 Andreas Krebbel * common/config/s390/s390-common.c (processor_flags_table): New entry for arch13. * config.gcc: Support arch13 with the --with-arch

[PATCH 14/14] S/390: arch13: vector float-int conversion builtins

2019-04-02 Thread Andreas Krebbel
gcc/ChangeLog: 2019-04-02 Andreas Krebbel * config/s390/s390-builtin-types.def: New builtin function type definitions. Remove unused types. * config/s390/s390-builtins.def (s390_vcdgb, s390_vcdlgb) (s390_vcgdb, s390_vclgdb): Remove low-level builtin definitions

[PATCH 07/14] S/390: arch13: New vector builtins - preparation

2019-04-02 Thread Andreas Krebbel
gcc/ChangeLog: 2019-04-02 Andreas Krebbel * config/s390/s390-builtins.def (B_VXE2): New builtin flag definition. * config/s390/s390-c.c (s390_cpu_cpp_builtins_internal): Increment vector builtin version number in __VEC__. --- gcc/config/s390/s390-builtins.def | 8

[PATCH 12/14] S/390: arch13: vector shift double by bit builtins

2019-04-02 Thread Andreas Krebbel
gcc/ChangeLog: 2019-04-02 Andreas Krebbel * config/s390/s390-builtin-types.def: Add new builtin function types. * config/s390/s390-builtins.def (s390_vec_sldb, s390_vec_srdb): New overloaded builtins. (s390_vec_sldb, s390_vec_srdb): New low-level

[PATCH 03/14] S/390: arch13: Support new popcount instruction variant.

2019-04-02 Thread Andreas Krebbel
The new arch13 popcount instruction counts bits in the entire 64 bit register instead of just in 8 bit portions. gcc/ChangeLog: 2019-04-02 Andreas Krebbel * config/s390/s390.md ("*popcountdi_arch13_cc") ("*popcountdi_arch13_cconly", "*popc

[PATCH 08/14] S/390: arch13: vec_revb vector byte swap builtin

2019-04-02 Thread Andreas Krebbel
gcc/ChangeLog: 2019-04-02 Andreas Krebbel * config/s390/s390-builtin-types.def: Add new builtin function types. * config/s390/s390-builtins.def: Add overloaded builtin s390_vec_revb. Add low-level builtins for vlbr and vstbr instructions. * config/s390

[PATCH 13/14] S/390: arch13: vector string search builtins

2019-04-02 Thread Andreas Krebbel
gcc/ChangeLog: 2019-04-02 Andreas Krebbel * config/s390/s390-builtin-types.def: New builtin function type definitions. * config/s390/s390-builtins.def (s390_vec_search_string_cc) (s390_vec_search_string_until_zero_cc): New overloaded builtins

[PATCH 05/14] S/390: arch13: Support 32 bit fp-int vector converts

2019-04-02 Thread Andreas Krebbel
gcc/ChangeLog: 2019-04-02 Andreas Krebbel * config/s390/s390.md ("xde"): Extend mode attribute to vector types. * config/s390/vector.md (VX_VEC_CONV_BFP, VX_VEC_CONV_INT): New mode iterators. ("floatv2div2df2", "floatunsv2div2

[PATCH 10/14] S/390: arch13: vector load/store byte reversed element for builtins

2019-04-02 Thread Andreas Krebbel
2019-04-02 Andreas Krebbel * config/s390/vecintrin.h: Map vec_vster low-level builtins to vec_vler. * config/s390/vx-builtins.md ("*vec_insert_and_zero_bswap") ("*vec_set_bswap_elem", "*vec_set_bswap_vec") ("*vec_extract_b

[PATCH 06/14] S/390: arch13: Support 32 bit fp-int scalar converts

2019-04-02 Thread Andreas Krebbel
gcc/ChangeLog: 2019-04-02 Andreas Krebbel * config/s390/s390.md (VX_CONV_BFP, VX_CONV_INT): New mode iterators. (SFSI): New mode attribute. ("*fixuns_truncdfdi2_vx", "*fix_truncdfdi2_bfp_z13") ("*floatunsdidf2_z13", ): Add

[Committed 00/14] S/390: Add support for new cpu architecture - arch13.

2019-04-02 Thread Andreas Krebbel
. Committed to mainline. Andreas Krebbel (14): S/390: arch13: Add arch13 as architecture option S/390: arch13: Support new bit operations S/390: arch13: Support new popcount instruction variant. S/390: arch13: Add support for new select instruction S/390: arch13: Support 32 bit fp-int

[PATCH 04/14] S/390: arch13: Add support for new select instruction

2019-04-02 Thread Andreas Krebbel
Compared to the load on condition instructions we already have the new select instruction allows to have a THEN and and ELSE source operand - but only for register to register loads. gcc/ChangeLog: 2019-04-02 Andreas Krebbel * config/s390/s390.c (s390_rtx_costs): Do not add extra

[PATCH 09/14] S/390: arch13: vec_reve element order reversal builtins

2019-04-02 Thread Andreas Krebbel
gcc/ChangeLog: 2019-04-02 Andreas Krebbel * config/s390/s390-builtin-types.def: Add new builtin function type. * config/s390/s390-builtins.def: Add overloaded builtin s390_vec_reve and low-level builtins for s390_vler and s390_vster. * config/s390/s390.md

[PATCH 11/14] S/390: arch13: vector load byte reversed element and replicate

2019-04-02 Thread Andreas Krebbel
gcc/ChangeLog: 2019-04-02 Andreas Krebbel ("*vec_splats_bswap_vec", "*vec_splats_bswap_elem"): New insn definition. * config/s390/vx-builtins.md (V_HW_HSD): Move to ... * config/s390/vector.md (V_HW_HSD): ... here. gcc/testsuite/ChangeLog:

[PATCH 02/14] S/390: arch13: Support new bit operations

2019-04-02 Thread Andreas Krebbel
Make use of the new bit operation instructions when generating code for the arch13 level. gcc/ChangeLog: 2019-04-02 Andreas Krebbel * config/s390/s390.c (s390_canonicalize_comparison): Convert certain compares for arch13 in order to make use of the condition code

[Committed] S/390: Reject long disp for vector load/store early

2019-04-03 Thread Andreas Krebbel
Andreas Krebbel * config/s390/s390.c (s390_legitimate_address_p): Reject long displacement addresses for vector mode operands. --- gcc/config/s390/s390.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/gcc/config/s390/s390.c b/gcc/config/s390/s390.c index

[PATCH] S/390: Fix PR89952 incorrect CFI

2019-04-09 Thread Andreas Krebbel
-09 Andreas Krebbel PR target/89952 * config/s390/s390.c (s390_restore_gprs_from_fprs): Restore GPRs from FPRs in reverse order. Generate REG_CFA_DEF_CFA note also for restored hard frame pointer. gcc/testsuite/ChangeLog: 2019-04-09 Andreas Krebbel

Re: [PATCH] S/390: Add arch13 pipeline description

2019-04-10 Thread Andreas Krebbel
On 10.04.19 17:19, Robin Dapp wrote: > 2019-04-10 Robin Dapp > > * config/s390/8561.md: New file. > * config/s390/driver-native.c (s390_host_detect_local_cpu): Add arch13 > cpu model. > * config/s390/s390-opts.h (enum processor_type): Likewise. > * config/s390/s390.c (s3

[Committed] S/390: Fix a problem with the bswap vector pattern

2019-04-12 Thread Andreas Krebbel
and regression tested on s390x. Committed to mainline gcc/ChangeLog: 2019-04-12 Andreas Krebbel * config/s390/predicates.md (permute_pattern_operand): New predicate. * config/s390/vector.md ("*vec_splats_bswap_vec"): Add USE operand for the permu

[PATCH] S/390: Fix PR89952 incorrect CFI

2019-04-17 Thread Andreas Krebbel
scheduler dependency to prevent the instruction scheduler from swapping the r11 and r15 restore again. gcc/ChangeLog: 2019-04-17 Andreas Krebbel PR target/89952 * config/s390/s390.c (s390_restore_gprs_from_fprs): Restore GPRs from FPRs in reverse order. Generate

Re: [PATCH] S/390: Add -march to test case

2019-05-16 Thread Andreas Krebbel
On 15.05.19 17:45, Robin Dapp wrote: > Hi, > > this patch adds -march=z900 to a test case that expects larl for loading > a value via the GOT. On z10 and later, lgrl is used which is tested in > a new test case. > > Regards > Robin > > -- > > gcc/testsuite/ChangeLog: > > 2019-05-15 Robin Da

[Committed] S/390: Fix vec_sldw builtin

2019-05-17 Thread Andreas Krebbel
The builtin was wired up to the wrong pattern. Fixed with this patch. gcc/ChangeLog: 2019-05-17 Andreas Krebbel * config/s390/s390-builtins.def (s390_vec_sldw_*): Use the vec_sldw insn pattern. gcc/testsuite/ChangeLog: 2019-05-17 Andreas Krebbel * gcc.target

[Committed] S/390: Remove load and test fp splitter

2019-02-05 Thread Andreas Krebbel
nd me to fix that. Committed to mainline, GCC 8, and GCC 7. Andreas gcc/ChangeLog: 2019-02-05 Andreas Krebbel PR target/88856 * config/s390/s390.md: Remove load and test FP splitter. --- gcc/config/s390/s390.md | 21 +++-- 1 file changed, 3 insertions(+

[Committed] S/390: Fix the vec_xl / vec_xst style builtins

2019-02-07 Thread Andreas Krebbel
source operands - vec_xlw4 / vec_xstw4 needs to accept float memory operands Bootstrapped and regression tested on s390x. gcc/ChangeLog: 2019-02-07 Andreas Krebbel * config/s390/s390-builtin-types.def: Add new types. * config/s390/s390-builtins.def: (s390_vec_xl, s390_vec_xld2

Re: [PATCH] S/390: Introduce jdd constraint

2019-02-08 Thread Andreas Krebbel
On 07.02.19 11:09, Ilya Leoshkevich wrote: > Bootstrapped and regtested on s390x-redhat-linux. > > Implementation of section anchors in S/390 back-end added in r266741 > broke jump labels in S/390 Linux kernel [1]. Currently jump labels > pass global variable addresses to .quad directive in inlin

Re: [PATCH] S/390: Implement vectory copysign

2019-02-08 Thread Andreas Krebbel
On 07.02.19 10:28, Robin Dapp wrote: > Hi, > > this patch implements vector copysign using vector select on S/390. > > Regtested and bootstrapped on s390x. > > Regards > Robin > > -- > > gcc/ChangeLog: > > 2019-02-07 Robin Dapp > > * config/s390/vector.md: Implement vector copysign

[PATCH 1/2] S/390: Fix vlvg vlgv low-level builtins.

2016-08-11 Thread Andreas Krebbel
gcc/ChangeLog: 2016-08-11 Andreas Krebbel * config/s390/s390-builtins.def: Mark last operand of s390_vlvg* and s390_vlgv* builtins as element selector. --- gcc/config/s390/s390-builtins.def | 20 ++-- 1 file changed, 10 insertions(+), 10 deletions(-) diff

[PATCH 2/2] S/390: Provide low-level builtins with __int128 ops.

2016-08-11 Thread Andreas Krebbel
gcc/ChangeLog: 2016-08-11 Andreas Krebbel * config/s390/s390-builtin-types.def: Add INT128 types. * config/s390/s390-builtins.def: Add INT128 variants for the add sub low-level builtins dealing with TImode. * config/s390/s390.c (s390_expand_builtin): Allow mode

[Committed 0/2] Vector builtin improvements

2016-08-11 Thread Andreas Krebbel
These two patches implement 2 minor improvements to the vector builtins. Committed after successful regression testing with -march=z13. The patches will be applied to GCC 6 branch as well. Andreas Krebbel (2): S/390: Fix vlvg vlgv low-level builtins. S/390: Provide low-level builtins with

Re: libgo patch committed: Change build procedure to use build tags

2016-08-12 Thread Andreas Krebbel
On 08/06/2016 02:36 AM, Ian Lance Taylor wrote: > Go packages use build tags (see the section on Build Constraints at > https://golang.org/pkg/go/build/) to select which files to build on > specific systems. > > Previously the libgo Makefile explicitly listed the set of files to > compile for each

Re: [PATCH v3] S/390: Add splitter for "and" with complement.

2016-08-23 Thread Andreas Krebbel
> gcc/ChangeLog > > * config/s390/s390.md ("*andc_split"): New splitter for and with > complement. > gcc/testsuite/ChangeLog > > * gcc.target/s390/md/andc-splitter-1.c: New test case. > * gcc.target/s390/md/andc-splitter-2.c: Likewise. Applied. Thanks! -Andreas-

Re: [PATCH] S/390: Improve result verification in test case vec-genmask-1.c.

2016-08-23 Thread Andreas Krebbel
> gcc/testsuite/ChangeLog > > * gcc.target/s390/zvector/vec-genmask-1.c: Improve result verification. Applies. Thanks! -Andreas-

Re: [PATCH] S/390: Fix insv-1.c test with -m31.

2016-08-23 Thread Andreas Krebbel
> gcc/testsuite/ChangeLog > > * gcc.target/s390/insv-1.c: Fix test when running with -m31. Applied. Thanks! -Andreas-

Re: [PATCH 2/2][v4] Drop excess size used for run time allocated stack variables.

2016-08-23 Thread Andreas Krebbel
> gcc/ChangeLog > > * explow.c (get_dynamic_stack_size): Take known alignment of stack > pointer + STACK_DYNAMIC_OFFSET into account when calculating the size > needed. > Correct a typo in a comment. Applied. Thanks! -Andreas-

Re: [PATCH 2/2][v4] Drop excess size used for run time allocated stack variables.

2016-08-24 Thread Andreas Krebbel
On 08/24/2016 04:02 AM, David Edelsohn wrote: > This patch broke bootstrap on AIX. Stage1 GCC is miscompiled. > > Please revert this patch. Done. Sorry for the breakage. -Andreas-

[Committed] S/390: Replace rtx_equal_p with reg_overlap_mentioned_p in splitter check.

2016-05-27 Thread Andreas Krebbel
gcc/ChangeLog: 2016-05-27 Andreas Krebbel * config/s390/s390.md (2x risbg splitters): Use reg_overlap_mentioned_p instead of rtx_equal_p. --- gcc/ChangeLog | 5 + gcc/config/s390/s390.md | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a

PING: [PATCH] PR33661 Fix problem with register asm in templates

2016-06-07 Thread Andreas Krebbel
Hi Jason, could you please have a look? https://gcc.gnu.org/ml/gcc-patches/2015-06/msg00904.html Thanks! -Andreas-

[Committed] S/390: Fix MAX_ARGS value.

2016-06-13 Thread Andreas Krebbel
Committed to GCC 5 and mainline branches. gcc/ChangeLog: 2016-06-13 Andreas Krebbel PR target/71379 * config/s390/s390.c (s390_expand_builtin): Increase MAX_ARGS by one. --- gcc/config/s390/s390.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a

Re: [Committed] S/390: Fix MAX_ARGS value.

2016-06-13 Thread Andreas Krebbel
On 06/13/2016 10:43 AM, Jakub Jelinek wrote: > On Mon, Jun 13, 2016 at 10:38:22AM +0200, Andreas Krebbel wrote: >> Committed to GCC 5 and mainline branches. > > What about gcc-6-branch? It also has MAX_ARGS 5, and case for arity 6. Done. -Andreas-

Re: [Committed] S/390: Fix MAX_ARGS value.

2016-06-13 Thread Andreas Krebbel
On 06/13/2016 11:01 AM, Jakub Jelinek wrote: > Also, it isn't clear to me, are there any s390 builtins right now that > actually have 6 arguments (my reading is that you don't count the return > value into that)? I.e. beyond the bootstrap issues, is the change actually > fixing expansion of any bu

[Committed] S/390: vecintrin.h fix file description in comment

2016-06-13 Thread Andreas Krebbel
gcc/ChangeLog: 2016-06-13 Andreas Krebbel * config/s390/vecintrin.h: Fix file description in comment. --- gcc/ChangeLog | 4 gcc/config/s390/vecintrin.h | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index

[Committed] S/390: Change builtin type naming scheme to match builtin-types.def.

2016-06-13 Thread Andreas Krebbel
gcc/ChangeLog: 2016-06-13 Andreas Krebbel * config/s390/s390-builtin-types.def: Change builtin type naming scheme to match builtin-types.def. --- gcc/ChangeLog | 5 + gcc/config/s390/s390-builtin-types.def | 420 - 2

Re: [Committed] S/390: Fix MAX_ARGS value.

2016-06-13 Thread Andreas Krebbel
On 06/13/2016 12:49 PM, Jakub Jelinek wrote: ... >> Yes. It is inconsistent to builtin-types.def. Not sure if it is worth fixing >> it. > > I think it wouldn't hurt, it would improve code readability. > And it affects just the single source file. Done. https://gcc.gnu.org/ml/gcc-patches/2016-06/

PING^3: [PATCH] PR33661 Fix problem with register asm in templates

2016-06-20 Thread Andreas Krebbel
Hi Jason, could you please have a look? https://gcc.gnu.org/ml/gcc-patches/2015-06/msg00904.html Thanks! -Andreas-

Re: [Patch, lra] PR70751, correct the cost for spilling non-pseudo into memory

2016-06-29 Thread Andreas Krebbel
On 06/28/2016 04:16 PM, Jiong Wang wrote: ... > So my first impression is TARGET_LEGITIMATE_ADDRESS_P on s390 do need a > fix here. The following draft patch fix this, my fix may be in > correct as normally we will allow illegal constant offset if it's > associated with virtual frame register befor

Re: [PATCH 1/2] S/390: Handle long-running instructions

2017-10-16 Thread Andreas Krebbel
On 10/11/2017 01:53 PM, Robin Dapp wrote: ... > @@ -14623,8 +14659,13 @@ s390_sched_variable_issue (FILE *file, int verbose, > rtx_insn *insn, int more) > case 1: > case 2: > case S390_SCHED_STATE_NORMAL: > + if (s390_sched_state == 0) > + starts

Re: [PATCH 2/2] S/390: Do not end groups after fallthru edge

2017-10-16 Thread Andreas Krebbel
On 10/11/2017 01:53 PM, Robin Dapp wrote: > This patch fixes cases where we start a new group although the previous one > has > not ended. > > Regression tested on s390x. > > gcc/ChangeLog: > > 2017-10-11 Robin Dapp > > * config/s390/s390.c (s390_has_ok_fallthru): New function. >

[Committed] S/390: Fix vec-cmp-2 testcase

2017-10-18 Thread Andreas Krebbel
/testsuite/ChangeLog: 2017-10-18 Andreas Krebbel * gcc.target/s390/zvector/vec-cmp-2.c (all_eq_double, all_ne_double, all_gt_double) (all_lt_double, all_ge_double, all_le_double) (any_eq_double, any_ne_double, any_gt_double) (any_lt_double, any_ge_double

[RFC] New pragma exec_charset

2017-10-19 Thread Andreas Krebbel
The TPF operating system uses the GCC S/390 backend. They set an EBCDIC exec charset for compilation using -fexec-charset. However, certain libraries require ASCII strings instead. In order to be able to put calls to that library into the normal code it is required to switch the exec charset wit

Re: [RFC] New pragma exec_charset

2017-10-20 Thread Andreas Krebbel
On 10/20/2017 10:28 AM, Richard Biener wrote: > On Fri, Oct 20, 2017 at 9:53 AM, Jakub Jelinek wrote: >> On Fri, Oct 20, 2017 at 09:48:38AM +0200, Richard Biener wrote: >>> How does it work semantically to have different exec charsets? That is, >>> if "strings" flow from a region with one -fexec-

Re: [RFC] New pragma exec_charset

2017-10-23 Thread Andreas Krebbel
On 10/19/2017 07:13 PM, Martin Sebor wrote: > On 10/19/2017 09:50 AM, Andreas Krebbel wrote: >> The TPF operating system uses the GCC S/390 backend. They set an >> EBCDIC exec charset for compilation using -fexec-charset. However, >> certain libraries require ASCII strings

Re: [RFC] New pragma exec_charset

2017-10-24 Thread Andreas Krebbel
On 10/23/2017 06:14 PM, Martin Sebor wrote: ... > It seems to me that before exposing a new mechanism to control > the exec charset it would be prudent to a) plug at least the > biggest holes to make the feature more reliable (in my mind, > that's at least -Wformat), and b) make sure the pragma int

Re: [RFC] New pragma exec_charset

2017-10-24 Thread Andreas Krebbel
On 10/24/2017 05:33 PM, Martin Sebor wrote: >>> My concern with this pragma/attribute and inlining has to do with >>> strings in one exec charset being propagated into functions that >>> operate on strings in another charset. E.g., like in the test >>> case below that's "miscompiled" with your pat

[PATCH] PR81393: S/390: libgo: Fix ptrace register set accessors.

2017-07-12 Thread Andreas Krebbel
ptrace SETREGS and GETREGS were never supported on S/390. The macros were accidentally defined in the Glibc header though. A recent Glibc change removed them breaking libgo build on S/390. This patch changes the ptrace calls to use PEEKUSR_AREA/POKEUSR_AREA to access the register sets. That's w

[Committed] S/390: Remove loc splitter

2017-07-12 Thread Andreas Krebbel
-12 Andreas Krebbel * config/s390/s390.md: Remove movcc splitter. --- gcc/ChangeLog | 4 gcc/config/s390/s390.md | 30 -- 2 files changed, 12 insertions(+), 22 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 128fc92..31f9832

[Committed] S/390: Calculate costs for load/store on condition

2017-07-12 Thread Andreas Krebbel
This adds code to the backend rtx_costs function in order to model the costs of a load/store on condition. Bootstrapped and regression tested on s390x. gcc/ChangeLog: 2017-07-12 Andreas Krebbel * config/s390/s390.c (s390_rtx_costs): Return proper costs for load/store on

Re: [PATCH][RFA/RFC] Stack clash mitigation patch 08/08

2017-07-14 Thread Andreas Krebbel
On 07/11/2017 11:21 PM, Jeff Law wrote: > This patch adds s390 support for stack-clash mitigation. > > s390's most interesting property is that the caller allocates space for > the callee to save registers into. > > So much like aarch64, we start with a very conservative assumption about > the of

Re: [PATCH] Fix PR81362: Vector peeling

2017-07-18 Thread Andreas Krebbel
On 07/12/2017 05:11 PM, Robin Dapp wrote: > gcc/ChangeLog: > > 2017-07-12 Robin Dapp > > * (vect_enhance_data_refs_alignment): > Remove body_cost_vec from _vect_peel_extended_info. > tree-vect-data-refs.c (vect_peeling_hash_get_lowest_cost): > Do not set body_cost_vec.

Re: [PATCH][RFA/RFC] Stack clash mitigation patch 08/08 V2

2017-07-21 Thread Andreas Krebbel
Hi, I've used your patch as the base and applied my changes on top. The attached patch is the result, so it is supposed to replace your version. It now also supports emitting a runtime loop. It bootstraps fine but unfortunately I see an Ada regression which I haven't tracked down yet. > FAIL:

[Committed] S/390: Fix PR81534

2017-07-27 Thread Andreas Krebbel
d GCC 7 branch. gcc/ChangeLog: 2017-07-27 Andreas Krebbel PR target/81534 * config/s390/s390.md ("*atomic_compare_and_swap_1") ("*atomic_compare_and_swapdi_2", "*atomic_compare_and_swapsi_3"): Change s_operand to memory_operand. g

Re: [PATCH] Switch vec_init and vec_extract optabs to 2 mode optab to allow extraction of vector from vector or initialization of vector from smaller vectors (PR target/80846)

2017-07-27 Thread Andreas Krebbel
On 07/25/2017 11:14 AM, Jakub Jelinek wrote: S/390 parts are ok. -Andreas-

[Committed] S/390: Support z14 as CPU name.

2017-07-31 Thread Andreas Krebbel
-07-31 Andreas Krebbel * config.gcc: Add z14. * config/s390/driver-native.c (s390_host_detect_local_cpu): Add CPU model numbers for z13s and z14. * config/s390/s390-c.c (s390_resolve_overloaded_builtin): Replace arch12 with z14. * config/s390/s390

[Committed] S/390: Fix PR80725.

2017-05-24 Thread Andreas Krebbel
No regressions on s390x. Applied to mainline. Ok for GCC 7 branch as well? Bye, -Andreas- gcc/ChangeLog: 2017-05-24 Andreas Krebbel PR target/80725 * config/s390/s390.c (s390_check_qrst_address): Check incoming address against address_operand predicate

[Committed] S/390: Don't fetch the return address early with ooo

2017-06-01 Thread Andreas Krebbel
: 2017-06-01 Andreas Krebbel * config/s390/s390.c (s390_emit_epilogue): Disable early return address fetch for z10 or later. --- gcc/config/s390/s390.c | 63 +- 1 file changed, 32 insertions(+), 31 deletions(-) diff --git a/gcc/config

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