Re: [PATCH, rs6000] Support vrotr3 for int vector types

2019-07-17 Thread Kewen.Lin
Hi Segher, on 2019/7/17 下午9:40, Segher Boessenkool wrote: > Hi Kewen, > > On Wed, Jul 17, 2019 at 04:32:15PM +0800, Kewen.Lin wrote: >> Regression testing just launched, is it OK for trunk if it's bootstrapped >> and regresstested on powerpc64le-unknown-linux-gnu? > >> +;; Expanders for

Fix failing tests after PR libstdc++/85965

2019-07-17 Thread François Dumont
Since commit 5d3695d03b7bdade9f4d05d2b those tests are failing.     * testsuite/23_containers/unordered_map/48101_neg.cc: Adapt dg-error     after PR libstdc++/85965 fix.     * testsuite/23_containers/unordered_multimap/48101_neg.cc: Likewise.     *

sized delete in _Temporary_buffer<>

2019-07-17 Thread François Dumont
As we adopted the sized deallocation in the new_allocator why not doing the same in _Temporary_buffer<>.     * include/bits/stl_tempbuf.h (__detail::__return_temporary_buffer): New.     (~_Temporary_buffer()): Use latter.     (_Temporary_buffer(_FIterator, size_type)): Likewise. Tested w/o

Go patch committed: Fix bug in unordered set when exporting

2019-07-17 Thread Ian Lance Taylor
This Go frontend patch by Than McIntosh fixes a bug in the handling of unordered set during exporting. In https://golang.org/cl/183850 (https://gcc.gnu.org/ml/gcc-patches/2019-07/msg00200.html) a change was made to combine tracking/discovery of exported types and imported packages during export

[PATCH,fortran] Handle BOZ in accordance to Fortran 2018 standard

2019-07-17 Thread Steve Kargl
I will be away until Monday. Plenty of time for a review. TL;DR version: The attached patch fixes the handling of a BOZ literal constant in gfortran to conform to the F2018 standard. Long version: Highlights: * No longer need to use -fno-range-check with BOZ * Fixed merge_bits *

Re: -Wmissing-attributes: avoid duplicates and false positives

2019-07-17 Thread Alexandre Oliva
On Jul 17, 2019, Martin Sebor wrote: > Sure, if it's worthwhile to you I think it's an improvement even > if it doesn't fix a bug. (In full disclosure I'm not empowered > to formally approve bigger patches but I think cleanups like this > can safely be committed as obvious.) Thanks, I'm

[PATCH] Put more data in read-only data on hppa

2019-07-17 Thread John David Anglin
When generating non-PIC code on Linux, the linker support allows us to put both local and global relocs in read-only data. On HP-UX, we can put local relocs in read-only data. We can also put constant data in read-only data on the HP-UX SOM target when generating PIC code. This patch

wrap math.h for M_PI et al in target/i386 tests

2019-07-17 Thread Alexandre Oliva
Most but not all of the tests that expect M_PI, M_PI_2 and/or M_PI_4 to be defined in math.h explicitly exclude one target system that does not satisfy this non-standard assumption. This patch introduces a wrapper header that includes math.h and then conditionally supplies the missing

[PATCH,RFC,V4 4/5] CTF generation for a single compilation unit

2019-07-17 Thread Indu Bhagat
For each translation unit, a CTF container (ctf_container_t) is used to keep the CTF debug info. - ctfout.c hosts the compiler facing routines for CTF generation and emission. - ctfcreate.c contains the CTF format specific CTF creation routines. - ctfutils.c contains helper routines for CTF

[PATCH,RFC,V4 5/5] Update CTF testsuite

2019-07-17 Thread Indu Bhagat
[Changes from V3] Added new testcases - gcc.dg/debug/ctf/ctf-array-2.c - gcc.dg/debug/ctf/ctf-complex-1.c - gcc.dg/debug/ctf/ctf-enum-2.c - gcc.dg/debug/ctf/ctf-func-index-1.c - gcc.dg/debug/ctf/ctf-objt-index-1.c - gcc.dg/debug/ctf/ctf-skip-types-1.c gcc/testsuite/ChangeLog: *

[PATCH,RFC,V4 3/5] Setup for CTF generation and emission

2019-07-17 Thread Indu Bhagat
Initialize CTF container when -gtLEVEL is specified. Generate CTF debug info for global decls. Import the CTF header from binutils. [Changes from V3] Inform the user instead of warning if -gtLEVEL is used and the frontend is not C. gcc/ChangeLog: * Makefile.in: Add ctfout.* files to

[PATCH,RFC,V4 0/5] Support for CTF in GCC

2019-07-17 Thread Indu Bhagat
Hello, I have made some progress on the patch set that adds support for CTF generation in GCC. I am sharing the current status so that those interested can review and/or try it out. For a brief summary of the individual patches in this set, please see previous posting

[PATCH,RFC,V4 1/5] Add new function lang_GNU_GIMPLE

2019-07-17 Thread Indu Bhagat
gcc/ChangeLog: * langhooks.c (lang_GNU_GIMPLE): New Function. * langhooks.h: New Prototype. --- gcc/ChangeLog | 5 + gcc/langhooks.c | 9 + gcc/langhooks.h | 1 + 3 files changed, 15 insertions(+) diff --git a/gcc/langhooks.c b/gcc/langhooks.c index

[PATCH,RFC,V4 2/5] Add CTF command line options : -gtLEVEL

2019-07-17 Thread Indu Bhagat
-gtLEVEL is used to request CTF debug information and also to specify how much CTF debug information. gcc/ChangeLog: * common.opt: Add CTF debug info options. * doc/invoke.texi: Document the CTF debug info options. * flag-types.h (enum ctf_debug_info_levels): New enum.

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

2019-07-17 Thread Ilya Leoshkevich
Hello, I would like to ping this change. Best regards, Ilya > Am 02.07.2019 um 17:34 schrieb Ilya Leoshkevich : > > Bootstrap and regtest running on x86_64-redhat-linux, s390x-redhat-linux > and ppc64le-redhat-linux. > > Currently s390 emits the following sequence to store a frame_pc: > >

[PATCH 10/10, OpenACC] Make new OpenACC kernels conversion the default; adjust and add tests

2019-07-17 Thread Kwok Cheung Yeung
This patch makes the new kernel conversion scheme the default, and adjusts the tests accordingly. 2019-07-16 Thomas Schwinge Kwok Cheung Yeung gcc/c-family/ * c.opt (fopenacc-kernels): Default to "split". gcc/fortran/ * lang.opt

[PATCH 09/10, OpenACC] Avoid introducing 'create' mapping clauses for loop index variables in kernels regions

2019-07-17 Thread Kwok Cheung Yeung
This patch avoids adding CREATE mapping clauses for loop index variables. It also sets TREE_ADDRESSABLE on newly mapped declarations, which fixes an ICE that sometimes appears due to an assert firing in omp-low.c. 2019-07-16 Julian Brown gcc/ * omp-oacc-kernels.c

[PATCH 08/10, OpenACC] New OpenACC kernels region decompose algorithm

2019-07-17 Thread Kwok Cheung Yeung
Previously, OpenACC kernels region bodies were decomposed into a sequence of alternating gang-single and gang-parallel "parallel" regions. The new algorithm in this patch introduces a third possibility: Loops that look like they might benefit from the parloops pass are converted into old

[PATCH] Fix simd attribute handling on aarch64

2019-07-17 Thread Steve Ellcey
This patch fixes a bug with SIMD functions on Aarch64. I found it while trying to run SPEC with ToT GCC and a glibc that defines vector math functions for aarch64. When a function is declared with the simd attribute GCC creates vector clones of that function with the return and argument types

[PATCH 07/10, OpenACC] Launch kernels asynchronously in OpenACC kernels regions

2019-07-17 Thread Kwok Cheung Yeung
Kernels regions are decomposed into one or more smaller regions that are to be executed in sequence. With this patch, all of these regions are launched asynchronously, and a wait directive is added after them. This means that the host only waits once for the kernels to complete, not once per

[PATCH 06/10, OpenACC] Adjust parallelism of loops in gang-single parts of OpenACC kernels regions

2019-07-17 Thread Kwok Cheung Yeung
Loops in gang-single parts of kernels regions cannot be executed in gang-redundant mode. If the user specified gang clauses on such loops, emit an error and remove these clauses. Adjust automatic partitioning to exclude gang partitioning in gang-single regions. 2019-07-16 Gergö Barany

[PATCH 05/10, OpenACC] Handle conditional execution of loops in OpenACC, kernels regions

2019-07-17 Thread Kwok Cheung Yeung
Any OpenACC loop controlled by an if statement or a non-OpenACC loop must be executed in a gang-single region. Detecting such loops is not trivial as OpenACC kernels expansion is done on GIMPLE but before computation of the control flow graph. This patch adds an auxiliary analysis for

[PATCH 04/10, OpenACC] Turn OpenACC kernels regions into a sequence of, parallel regions

2019-07-17 Thread Kwok Cheung Yeung
This patch decomposes each OpenACC kernels region into a sequence of parallel regions. Each OpenACC loop nest turns into its own region; any code between such loop nests is gathered up into a region as well. The loop regions can be distributed across gangs if the original kernels region had a

[PATCH 03/10, OpenACC] Separate OpenACC kernels regions in data and parallel parts

2019-07-17 Thread Kwok Cheung Yeung
In the future, kernels regions will be transformed into data regions containing a sequence of serial and parallel offloaded regions. This first patch sets up a new pass that is responsible for this transformation, and in a first step constructs the new data region containing a parallel region

[PATCH 02/10, OpenACC] Add OpenACC target kinds for decomposed kernels regions

2019-07-17 Thread Kwok Cheung Yeung
This patch is in preparation for changes that will cut up OpenACC kernels regions into individual parts. For the new sub-regions that will be generated, this adds the following new kinds of OpenACC regions for internal use: - GF_OMP_TARGET_KIND_OACC_PARALLEL_KERNELS_PARALLELIZED for parts of

[PATCH 01/10, OpenACC] Use "-fopenacc-kernels=parloops" to document "parloops" test cases

2019-07-17 Thread Kwok Cheung Yeung
This patch introduces a new option "-fopenacc-kernels" to control how OpenACC kernels are processed. The current behaviour will be equivalent to '-fopenacc-kernels=parloops'. 2019-07-16 Thomas Schwinge gcc/ * flag-types.h (enum openacc_kernels): New type.

[PATCH 00/10, OpenACC] Rework handling of OpenACC kernels regions

2019-07-17 Thread Kwok Cheung Yeung
This series of patches reworks the way that OpenACC kernels regions are processed by GCC. Instead of relying on the parloops pass for auto-parallelisation of the kernel region, the contents of the region are transformed into a sequence of offloaded regions, which are then processed

[committed] Fix indentation goof in tree-ssa-dse.c

2019-07-17 Thread Jeff Law
I've been poking at a bit at some missed cases in tree-ssa-dse.c and noticed the formatting for a couple of case statements was wrong. There was also a missing return/break would led to a fallthru warning in some of the work I did. There's no functional changes here. Bootstrapped and

Re: Rewrite some jump.c routines to use flags

2019-07-17 Thread Eric Botcazou
> I'm not sure using flags_to_condition really buys anything then, > since you have to think about each individual case to see whether > it belongs in the switch or not. I also don't have any proof > that the no-op cases are the common ones (since adding this > fast path of course slows down the

Re: [PATCH 2/5, OpenACC] Support Fortran optional arguments in the firstprivate clause

2019-07-17 Thread Tobias Burnus
Am 17.07.19 um 19:53 schrieb Kwok Cheung Yeung: > On 12/07/2019 12:41 pm, Jakub Jelinek wrote: >> This should be done through a langhook. >> Are really all PARM_DECLs wtih DECL_BY_REFERENCE and pointer type >> optional >> arguments?  I mean, POINTER_TYPE is used for a lot of cases. > > Hmmm... I

Re: C++ PATCH to detect narrowing in case values (PR c++/90805)

2019-07-17 Thread Marek Polacek
On Wed, Jul 03, 2019 at 01:57:06PM -0400, Jason Merrill wrote: > On 7/3/19 10:13 AM, Marek Polacek wrote: > > On Sat, Jun 22, 2019 at 11:28:36PM -0400, Jason Merrill wrote: > > > On 6/13/19 5:03 PM, Marek Polacek wrote: > > > > Case values are converted constant expressions, so narrowing

Re: -Wmissing-attributes: avoid duplicates and false positives

2019-07-17 Thread Martin Sebor
On 7/17/19 1:14 PM, Alexandre Oliva wrote: On Jul 17, 2019, Martin Sebor wrote: Isn't this test sufficient to avoid the problems? if (!k && kmax > 1) continue; It is, unless someone (i) doesn't realize attributes that are present in the type can't be present

Re: -Wmissing-attributes: avoid duplicates and false positives

2019-07-17 Thread Alexandre Oliva
On Jul 17, 2019, Martin Sebor wrote: > Isn't this test sufficient to avoid the problems? > if (!k && kmax > 1) > continue; It is, unless someone (i) doesn't realize attributes that are present in the type can't be present in the decl, (ii) misreads the '!k' as just

Re: Rewrite some jump.c routines to use flags

2019-07-17 Thread Richard Sandiford
Eric Botcazou writes: >> No, no trivial paths unfortunately. I'd hoped that inlining and >> jump threading would give us very similar code, but no such luck. >> condition_to_flags is a table lookup, but then flags_to_condition >> is a branch tree. > > Too bad. Perhaps this would be an

[PATCH, i386]: Remove redundant constraints from ALU insn patterns

2019-07-17 Thread Uros Bizjak
No functional changes. 2019-07-17 Uroš Bizjak * config/i386/i386.md (*add3_doubleword): Remove redundant constraints. (*add_1): Ditto. (*addhi_1): Ditto. (*addqi_1): Ditto. (*addqi_1_slp): Ditto. (*add_2): Ditto. (*addv4): Ditto. (*sub3_doubleword): Ditto.

Re: [C++] DEFERRED_PARSE

2019-07-17 Thread Marek Polacek
On Mon, Jul 08, 2019 at 08:25:25AM -0400, Nathan Sidwell wrote: > Jason, Marek, > can DEFERRED_PARSE trees survive past the in-class-context late parsing > stage? My assumption was not, but in reducing a module testcase I > encountered a situation when one survived to end of compilation (with no

C++ PATCH to add test for c++/90455

2019-07-17 Thread Marek Polacek
Fixed by r272287. Tested x86_64-linux, applying to trunk. 2019-07-17 Marek Polacek PR c++/90455 * g++.dg/cpp0x/nsdmi-list6.C: New test. --- /dev/null +++ gcc/testsuite/g++.dg/cpp0x/nsdmi-list6.C @@ -0,0 +1,28 @@ +// PR c++/90455 +// { dg-do compile { target c++11 } } +

Re: [PATCH 2/5, OpenACC] Support Fortran optional arguments in the firstprivate clause

2019-07-17 Thread Kwok Cheung Yeung
On 12/07/2019 12:41 pm, Jakub Jelinek wrote: This should be done through a langhook. Are really all PARM_DECLs wtih DECL_BY_REFERENCE and pointer type optional arguments? I mean, POINTER_TYPE is used for a lot of cases. Hmmm... I thought it was the case that if you pass an argument in by

C++ PATCH to add test for c++/91104

2019-07-17 Thread Marek Polacek
This was a wrong code issue where we printed 2 3 1 1 2 3 instead of 1 2 3 1 2 3 but it was fixed by r271705. I don't know of a good way to check the auto... expansion here so I used dg-output. Tested on x86_64-linux, ok for trunk? 2019-07-17 Marek Polacek PR c++/91104 *

Re: [RFC] Consider lrotate const rotation in vectorizer

2019-07-17 Thread Segher Boessenkool
On Wed, Jul 17, 2019 at 12:54:32PM +0200, Jakub Jelinek wrote: > On Wed, Jul 17, 2019 at 12:37:59PM +0200, Richard Biener wrote: > > I'm not sure if it makes sense to have both LROTATE_EXPR and > > RROTATE_EXPR on the GIMPLE level then (that CPUs only > > support one direction is natural though).

Re: Rewrite some jump.c routines to use flags

2019-07-17 Thread Eric Botcazou
> No, no trivial paths unfortunately. I'd hoped that inlining and > jump threading would give us very similar code, but no such luck. > condition_to_flags is a table lookup, but then flags_to_condition > is a branch tree. Too bad. Perhaps this would be an interesting optimization exercise. >

Re: -Wmissing-attributes: avoid duplicates and false positives

2019-07-17 Thread Martin Sebor
On 7/17/19 12:02 AM, Alexandre Oliva wrote: Hello, Martin, The initial patch for PR 81824 fixed one of the possibilities of -Wmissing-attributes reporting duplicates, namely, if TMPL had an attribute in ATTRLIST that was missing from DECL's decl and type attribute lists, both being non-empty.

[PATCH, i386]: Handle potential partial reg stall in *andqi_2_maybe_si

2019-07-17 Thread Uros Bizjak
2019-07-17 Uroš Bizjak * config/i386/i386.md (*andqi_2_maybe_si): Handle potential partial reg stall on alternative 2. Bootstrapped and regression tested on x86_64-linux-gnu {,-m32}. Committed to mainline SVN. Uros. Index: config/i386/i386.md

[PATCH] Re-indent recently added vn_walk_cb_data::push_partial_def

2019-07-17 Thread Richard Biener
I need to add stuff and indent level is soo high. But there's rescue. No functional change. Bootstrapped on x86_64-unknown-linux-gnu, testing in progress. Richard. 2019-07-17 Richard Biener * tree-ssa-sccvn.c (vn_walk_cb_data::push_partial_def): Refactor branches to make

Re: [RFC] Consider lrotate const rotation in vectorizer

2019-07-17 Thread Segher Boessenkool
On Wed, Jul 17, 2019 at 01:32:50PM +0200, Richard Biener wrote: > On Wed, Jul 17, 2019 at 12:54 PM Jakub Jelinek wrote: > Ick. I wouldn't even touch SHIFT_COUNT_TRUNCATED with a 10-foot pole > here. And for rotates we can simply always truncate constant amounts to > the rotated operands width,

Re: [PATCH, rs6000] Support vrotr3 for int vector types

2019-07-17 Thread Segher Boessenkool
Hi Kewen, On Wed, Jul 17, 2019 at 04:32:15PM +0800, Kewen.Lin wrote: > Regression testing just launched, is it OK for trunk if it's bootstrapped > and regresstested on powerpc64le-unknown-linux-gnu? > +;; Expanders for rotatert to make use of vrotl > +(define_expand "vrotr3" > + [(set

Re: PR90724 - ICE with __sync_bool_compare_and_swap with -march=armv8.2-a

2019-07-17 Thread Prathamesh Kulkarni
On Wed, 17 Jul 2019 at 13:45, Kyrill Tkachov wrote: > > Hi Prathamesh > > On 7/10/19 12:24 PM, Prathamesh Kulkarni wrote: > > Hi, > > For following test-case, > > static long long AL[24]; > > > > int > > check_ok (void) > > { > > return (__sync_bool_compare_and_swap (AL+1, 0x20003ll, > >

PR91166 - Unfolded ZIPs of constants

2019-07-17 Thread Prathamesh Kulkarni
Hi, The attached patch tries to fix PR91166. Does it look OK ? Bootstrap+test in progress on aarch64-linux-gnu and x86_64-unknown-linux-gnu. Thanks, Prathamesh 2019-07-17 Prathamesh Kulkarni PR middle-end/91166 * match.pd (vec_perm_expr(v, v, mask) -> v): New pattern.

Re: [RFC] Consider lrotate const rotation in vectorizer

2019-07-17 Thread Richard Biener
On Wed, Jul 17, 2019 at 1:32 PM Richard Biener wrote: > > On Wed, Jul 17, 2019 at 12:54 PM Jakub Jelinek wrote: > > > > On Wed, Jul 17, 2019 at 12:37:59PM +0200, Richard Biener wrote: > > > On Tue, Jul 16, 2019 at 10:45 AM Kewen.Lin wrote: > > > > Based on the previous comments (thank you!), I

Re: [RFC] Consider lrotate const rotation in vectorizer

2019-07-17 Thread Richard Biener
On Wed, Jul 17, 2019 at 12:54 PM Jakub Jelinek wrote: > > On Wed, Jul 17, 2019 at 12:37:59PM +0200, Richard Biener wrote: > > On Tue, Jul 16, 2019 at 10:45 AM Kewen.Lin wrote: > > > Based on the previous comments (thank you!), I tried to update the > > > handling in expander and vectorizer.

[Arm][CMSE]Add warn_unused_return attribute to cmse functions

2019-07-17 Thread Joel Hutton
At present it is possible to call the CMSE functions for checking addresses (such as cmse_check_address_range) and  forget to check/use the return value. This patch makes the interfaces more robust against programmer error by marking these functions with the warn_unused_result attribute. With

Re: [PATCH PR91137]Find base object for ivopts via walk_tree

2019-07-17 Thread Richard Biener
On Wed, Jul 17, 2019 at 8:52 AM bin.cheng wrote: > > Hi, > This patch fixes PR91137 by finding base objects with walk_tree utility. > Note we specially return > integer_zero_node when a tree expression contains multiple base objects. > This works since the > special node is compared unequal

Re: [RFC] Consider lrotate const rotation in vectorizer

2019-07-17 Thread Jakub Jelinek
On Wed, Jul 17, 2019 at 12:37:59PM +0200, Richard Biener wrote: > On Tue, Jul 16, 2019 at 10:45 AM Kewen.Lin wrote: > > Based on the previous comments (thank you!), I tried to update the > > handling in expander and vectorizer. Middle-end optimizes lrotate > > with const rotation count to

Re: Make alias sets of ODR types more precise

2019-07-17 Thread Richard Biener
On Tue, 16 Jul 2019, Jan Hubicka wrote: > Hi, > this is the hunk we omitted from the original patch enabling TBAA for > ODR types. Currently record_component_aliases record all pointers as > void *. This is because canonical type merging handles them this way > and thus it may merge for example

Re: [RFC] Consider lrotate const rotation in vectorizer

2019-07-17 Thread Richard Biener
On Tue, Jul 16, 2019 at 10:45 AM Kewen.Lin wrote: > > Hi all, > > Based on the previous comments (thank you!), I tried to update the > handling in expander and vectorizer. Middle-end optimizes lrotate > with const rotation count to rrotate all the time, it makes vectorizer > fail to vectorize if

[PATCH] Simplify LTO section format.

2019-07-17 Thread Martin Liška
Hi. The patch is about simplified LTO ELF section header where want to make public fields major_version, minor_version and slim_object. The rest is implementation defined by GCC. Patch can bootstrap on x86_64-linux-gnu and survives regression tests. Ready to be installed? Thanks, Martin

[PATCH] Fix PR91178

2019-07-17 Thread Richard Biener
This is the vectorizer part of the fix - currently when we need to permute a load in contiguous accesses we load the "gap" between two instances of a group as well. That can cause quite excessive code generation (fixed up by DCE / forwprop later but confusing intermediate passes compile-time

[PATCH] Fix quadraticnesses in release_defs_bitset and split_constant_offset

2019-07-17 Thread Richard Biener
The testcase in PR91178 runs into these because of vectorizer code-gen stupidities (I'm going to fix that as well). For split_constant_offset we should simply limit walking the SSA def chain, now there's a convenient --param we can use for that. For release_defs_bitset it's current

Re: [PATCH, rs6000] Support vrotr3 for int vector types

2019-07-17 Thread Jakub Jelinek
On Wed, Jul 17, 2019 at 05:22:38PM +0800, Kewen.Lin wrote: > Good question, the vector rotation for byte looks like (others are similar): > > vrlb VRT,VRA,VRB > do i=0 to 127 by 8 >sh = (VRB)[i+5:i+7] >VRT[i:i+7] = (VRA)[i:i+7] <<< sh > end > > It only takes care of the counts from 0

Re: [PATCH, rs6000] Support vrotr3 for int vector types

2019-07-17 Thread Kewen.Lin
on 2019/7/17 下午4:42, Jakub Jelinek wrote: > On Wed, Jul 17, 2019 at 04:32:15PM +0800, Kewen.Lin wrote: >> --- a/gcc/config/rs6000/vector.md >> +++ b/gcc/config/rs6000/vector.md >> @@ -1260,6 +1260,32 @@ >>"VECTOR_UNIT_ALTIVEC_OR_VSX_P (mode)" >>"") >> >> +;; Expanders for rotatert to

Re: [PATCH v4] Generalize get_most_common_single_value to return k_th value & count

2019-07-17 Thread Martin Liška
On 7/17/19 10:44 AM, luoxhu wrote: > Hi Martin, > > On 2019/7/17 15:55, Martin Liška wrote: >> On 7/17/19 7:44 AM, luoxhu wrote: >>> Hi Martin, >>> Thanks for your review, v4 Changes as below: >>>   1. Use decrease bubble sort. >>> BTW, I have a question about hist->hvalue.counters[2], when will

Re: [PATCH v4] Generalize get_most_common_single_value to return k_th value & count

2019-07-17 Thread luoxhu
Hi Martin, On 2019/7/17 15:55, Martin Liška wrote: On 7/17/19 7:44 AM, luoxhu wrote: Hi Martin, Thanks for your review, v4 Changes as below: 1. Use decrease bubble sort. BTW, I have a question about hist->hvalue.counters[2], when will it become -1, please? Thanks. Currently, if it is -1,

Re: [PATCH, rs6000] Support vrotr3 for int vector types

2019-07-17 Thread Jakub Jelinek
On Wed, Jul 17, 2019 at 04:32:15PM +0800, Kewen.Lin wrote: > --- a/gcc/config/rs6000/vector.md > +++ b/gcc/config/rs6000/vector.md > @@ -1260,6 +1260,32 @@ >"VECTOR_UNIT_ALTIVEC_OR_VSX_P (mode)" >"") > > +;; Expanders for rotatert to make use of vrotl > +(define_expand "vrotr3" > +

[PATCH, rs6000] Support vrotr3 for int vector types

2019-07-17 Thread Kewen.Lin
Hi all, This patch follows the idea to improve rs6000 backend instead of generic expander. I think this is a better solution? I was thinking generic expander change may benefit other targets suffering similar issues but the previous RFC seems too restricted on const rotation count, although

Re: [RFC/PATCH v2][PR89245] Check REG_CALL_DECL note during the tail-merging

2019-07-17 Thread Dragan Mladjenovic
On 09.07.2019. 23:21, Jeff Law wrote: > On 7/9/19 2:06 PM, Dragan Mladjenovic wrote: >> This patch prevents merging of CALL instructions that that have different >> REG_CALL_DECL notes attached to them. >> >> On most architectures this is not an important distinction. Usually >> instruction

Update ia64 baseline symbols

2019-07-17 Thread Andreas Schwab
Installed as obvious. Andreas. * config/abi/post/ia64-linux-gnu/baseline_symbols.txt: Update. Index: config/abi/post/ia64-linux-gnu/baseline_symbols.txt === --- config/abi/post/ia64-linux-gnu/baseline_symbols.txt (revision

Re: PR90724 - ICE with __sync_bool_compare_and_swap with -march=armv8.2-a

2019-07-17 Thread Kyrill Tkachov
Hi Prathamesh On 7/10/19 12:24 PM, Prathamesh Kulkarni wrote: Hi, For following test-case, static long long AL[24]; int check_ok (void) {   return (__sync_bool_compare_and_swap (AL+1, 0x20003ll, 0x1234567890ll)); } Compiling with -O2 -march=armv8.2-a results in: pr90724.c: In function

Re: [range-ops] patch 02/04: enforce canonicalization in value_range

2019-07-17 Thread Aldy Hernandez
I've rebased this patch to be independent of the others, to perhaps parallelize the review process. As mentioned before, this patch enforces canonicalization of ranges upon creation. This makes it easier to compare results of range implementations and avoids multiple representations for the

Re: [PATCH v4] Generalize get_most_common_single_value to return k_th value & count

2019-07-17 Thread Martin Liška
On 7/17/19 7:44 AM, luoxhu wrote: > Hi Martin, > Thanks for your review, v4 Changes as below: > 1. Use decrease bubble sort. > BTW, I have a question about hist->hvalue.counters[2], when will it become > -1, please? Thanks. Currently, if it is -1, the function will return false. Hi. Thanks

Re: [PATCH] Make a warning for -Werror=wrong-language (PR driver/91172).

2019-07-17 Thread Martin Liška
On 7/16/19 6:40 PM, Martin Sebor wrote: > On 7/16/19 5:16 AM, Martin Liška wrote: >> Hi. >> >> I noticed in the PR that -Werror=argument argument is not verified >> that the option is supported by a language we compile for. >> That's changed in the patch. However, it's not ideal as I need to mark

[PATCH] Fix PR91180

2019-07-17 Thread Richard Biener
The following fixes PR91180. Bootstrap / regtest running on x86_64-unknown-linux-gnu. Richard. 2019-07-17 Richard Biener PR tree-optimization/91180 * tree-ssa-sccvn.c (vn_reference_lookup_3): Fix offset computation for memset partial defs. *

[committed] Small cleanup now that Cilk+ simd is not supported anymore

2019-07-17 Thread Jakub Jelinek
Hi! We needed the & GF_OMP_FOR_SIMD stuff when we had GF_OMP_FOR_SIMD = 1 << 3, GF_OMP_FOR_KIND_SIMD= GF_OMP_FOR_SIMD | 0, GF_OMP_FOR_KIND_CILKSIMD= GF_OMP_FOR_SIMD | 1, and kind & GF_OMP_FOR_SIMD stood for kind == GF_OMP_FOR_KIND_SIMD || kind ==

Re: PR90724 - ICE with __sync_bool_compare_and_swap with -march=armv8.2-a

2019-07-17 Thread Prathamesh Kulkarni
On Wed, 10 Jul 2019 at 16:54, Prathamesh Kulkarni wrote: > > Hi, > For following test-case, > static long long AL[24]; > > int > check_ok (void) > { > return (__sync_bool_compare_and_swap (AL+1, 0x20003ll, 0x1234567890ll)); > } > > Compiling with -O2 -march=armv8.2-a results in: >

Re: [PATCH] Fix 3 generic vector lowering issues with VECTOR_BOOLEAN_TYPE_P SSA_NAMEs with scalar modes (PR tree-optimization/91157)

2019-07-17 Thread Richard Biener
On Wed, 17 Jul 2019, Jakub Jelinek wrote: > Hi! > > On the following testcase we end up with a comparison (EQ_EXPR in this case) > with unsupported vector operands, but supported result (vector boolean > type with scalar mode, i.e. the AVX512F-ish integer bitmask) and later > a VEC_COND_EXPR

[PATCH] Fix PR91181

2019-07-17 Thread Richard Biener
Bootstrapped / tested on x86_64-unknown-linux-gnu, applied. Richard. 2019-07-17 Richard Biener PR tree-optimization/91181 * tree-vect-slp.c (vect_build_slp_tree_1): Do not compare IFN_LOADs as calls. * gcc.dg/pr91181.c: New testcase. Index:

[PATCH] Fix 3 generic vector lowering issues with VECTOR_BOOLEAN_TYPE_P SSA_NAMEs with scalar modes (PR tree-optimization/91157)

2019-07-17 Thread Jakub Jelinek
Hi! On the following testcase we end up with a comparison (EQ_EXPR in this case) with unsupported vector operands, but supported result (vector boolean type with scalar mode, i.e. the AVX512F-ish integer bitmask) and later a VEC_COND_EXPR which is also not supported by the optab and has the

[PATCH PR91137]Find base object for ivopts via walk_tree

2019-07-17 Thread bin.cheng
Hi, This patch fixes PR91137 by finding base objects with walk_tree utility. Note we specially return integer_zero_node when a tree expression contains multiple base objects. This works since the special node is compared unequal to any real base object, thus skipped in candidate selection.

-Wmissing-attributes: avoid duplicates and false positives

2019-07-17 Thread Alexandre Oliva
Hello, Martin, The initial patch for PR 81824 fixed one of the possibilities of -Wmissing-attributes reporting duplicates, namely, if TMPL had an attribute in ATTRLIST that was missing from DECL's decl and type attribute lists, both being non-empty. Another possibility of duplicate reporting