Re: [C++] Fix PR bootstrap/81926

2017-09-03 Thread Eric Botcazou
> A solution would be to put them into a global GCed pointer-map or vector, > freeing that at free-lang-data time. The first part sounds good, but not the second part, as rest_of_handle_final generates debug info too. -- Eric Botcazou

Re: [C++] Fix PR bootstrap/81926

2017-09-03 Thread Richard Biener
On September 3, 2017 10:05:19 AM GMT+02:00, Eric Botcazou wrote: >> A solution would be to put them into a global GCed pointer-map or >vector, >> freeing that at free-lang-data time. > >The first part sounds good, but not the second part, as >rest_of_handle_final >generates debug info too. But

Re: Add support to trace comparison instructions and switch statements

2017-09-03 Thread Dmitry Vyukov via gcc-patches
On Fri, Sep 1, 2017 at 6:23 PM, Jakub Jelinek wrote: > On Fri, Jul 21, 2017 at 01:38:17PM +0800, 吴潍浠(此彼) wrote: >> Hi Jeff >> >> I have signed the copyright assignment, and used the name 'Wish Wu' . >> Should I send you a copy of my assignment ? >> >> The attachment is my new patch with small chan

Re: ARM Patch Ping

2017-09-03 Thread Bernd Edlinger
Ping... it would be nice if this could be reviewed before next stage 3. Thanks Bernd. On 08/01/17 16:32, Bernd Edlinger wrote: > Hi, > > I would like to kindly remind you of the following patches, > which are already waiting for over 6 months: > > [PATCH, ARM] correctly encode the CC reg data

Re: Add support to trace comparison instructions and switch statements

2017-09-03 Thread Jakub Jelinek
On Sun, Sep 03, 2017 at 10:50:16AM +0200, Dmitry Vyukov wrote: > What we instrument in LLVM is _comparisons_ rather than control > structures. So that would be: > _4 = x_8(D) == 98; > For example, result of the comparison can be stored into a bool struct > field, and then used in branching long

Re: Add support to trace comparison instructions and switch statements

2017-09-03 Thread Dmitry Vyukov via gcc-patches
On Sun, Sep 3, 2017 at 12:01 PM, Jakub Jelinek wrote: > On Sun, Sep 03, 2017 at 10:50:16AM +0200, Dmitry Vyukov wrote: >> What we instrument in LLVM is _comparisons_ rather than control >> structures. So that would be: >> _4 = x_8(D) == 98; >> For example, result of the comparison can be store

Re: Add support to trace comparison instructions and switch statements

2017-09-03 Thread Dmitry Vyukov via gcc-patches
On Sun, Sep 3, 2017 at 12:19 PM, Dmitry Vyukov wrote: > On Sun, Sep 3, 2017 at 12:01 PM, Jakub Jelinek wrote: >> On Sun, Sep 03, 2017 at 10:50:16AM +0200, Dmitry Vyukov wrote: >>> What we instrument in LLVM is _comparisons_ rather than control >>> structures. So that would be: >>> _4 = x_8(D)

Re: Add support to trace comparison instructions and switch statements

2017-09-03 Thread 吴潍浠(此彼)
Hi I will update the patch according to your requirements, and with some my suggestions. It will take me one or two days. Wish Wu -- From:Dmitry Vyukov Time:2017 Sep 3 (Sun) 18:21 To:Jakub Jelinek Cc:Wish Wu ; gcc ; gcc-patches ;

Re: Add support to trace comparison instructions and switch statements

2017-09-03 Thread Dmitry Vyukov via gcc-patches
On Sun, Sep 3, 2017 at 12:38 PM, 吴潍浠(此彼) wrote: > Hi > I will update the patch according to your requirements, and with some my > suggestions. > It will take me one or two days. Thanks! No hurry, just wanted to make sure you still want to pursue this. > Wish Wu > > -

Re: [C++] Fix PR bootstrap/81926

2017-09-03 Thread Eric Botcazou
> But not types, less using langhooks. #0 cp_get_debug_type (type=0x707702a0) at /home/eric/svn/gcc-7.2.0/gcc/cp/cp-objcp-common.c:142 #1 0x009f2c86 in gen_type_die_with_usage ( type=type@entry=0x707702a0, context_die=context_die@entry=0x7fffed7e90a0, usage=usag

Re: [RFA] [PATCH][PR tree-optimization/64910] Fix reassociation of binary bitwise operations with 3 operands

2017-09-03 Thread Jeff Law
On 01/13/2016 05:30 AM, Richard Biener wrote: > On Wed, Jan 13, 2016 at 7:39 AM, Jeff Law wrote: >> On 01/12/2016 08:11 AM, Richard Biener wrote: >>> >>> On Tue, Jan 12, 2016 at 6:10 AM, Jeff Law wrote: On 01/11/2016 03:32 AM, Richard Biener wrote: > > Yeah, reassoc is larg

[PATCH] Add netbsd-stdint.h to several netbsd targets

2017-09-03 Thread Maya Rashish
grouping netbsd.h netbsd-stdint.h netbsd-elf.h as "nbsd_tm_file", similar to freebsd. I've only tested some of the archs, but the change originates in netbsd's copy of GCC, so it should be safe for the untested ones as well. --- gcc/config.gcc | 21 +++-- 1 file changed, 11 inser

[PATCH, alpha] Move linux-specific specfile definitions to linux.h

2017-09-03 Thread Maya Rashish
Hi, in my first attempt to fix a build issue I found that the order of tm files matters, would prefer to move linux-looking parts of elf.h to linux.h. other targets that include alpha/elf.h besides linux: openbsd: provides their own STARTFILE_SPEC and ENDFILE_SPEC in later file: https://github.co

[PATCH, i386]: Allow memory operand for BT with immediate bitcount operand

2017-09-03 Thread Uros Bizjak
Hello! The BT instruction is slow only when memory operand is used with nonimmediate bitcount operand. 2017-09-03 Uros Bizjak * config/i386/i386.md (*bt): Use nonimmediate_operand predicate for operand 1. Add (m,) constraint. (*jcc_bt): Use nonimmediate_operand predicate for oper

Re: [00/77] Add wrapper classes for machine_modes

2017-09-03 Thread Gerald Pfeifer
Hi Richard, I'm afraid your patchset has broken bootstrap on i686-unknown-freebsd10.3, in fact, it appears on FreeBSD in general (amd64-unknown-freebsd11 as well): /scratch/tmp/gerald/GCC-HEAD/gcc/builtins.c:4913:6: error: cannot pass object of non-POD type 'scalar_int_mode' through variadi

[doc] Adjust www.openacc.org references

2017-09-03 Thread Gerald Pfeifer
I found this patch which I've had in my tree since June; openacc.org moved to https (plus we don't need the trailing slash). Applied, and I'll probably push back to the GCC 7 branch at least. Gerald 2017-09-03 Gerald Pfeifer * doc/generic.texi (OpenACC): Adjust URL. * doc/inv

Re: [00/77] Add wrapper classes for machine_modes

2017-09-03 Thread Richard Sandiford
Gerald Pfeifer writes: > Hi Richard, > > I'm afraid your patchset has broken bootstrap on i686-unknown-freebsd10.3, > in fact, it appears on FreeBSD in general (amd64-unknown-freebsd11 as well): This sounds like the same as PR82045. Could you try the patch I posted here: https://gcc.gnu.org/ml/g

[PATCH, i386]: Fix some mpx tests for older systems

2017-09-03 Thread Uros Bizjak
2017-09-03 Uros Bizjak * gcc.target/i386/mpx/mpx-check.h (main): Use __get_cpuid_count and return NORUNRES on failure. * gcc.target/i386/mpx/va-arg-pack-1-lbv.c (foo1): Use __builtin_va_arg_pack instead of __va_arg_pack. * gcc.target/i386/mpx/va-arg-pack-1-nov.c (foo1): Ditt

[PATCH, i386]: Use __get_cpuid_count in testsuite ISA check headers

2017-09-03 Thread Uros Bizjak
Hello! Use __get_cpuid_count and introduce check_osxsave local function. 2017-09-04 Uros Bizjak * gcc.target/i386/adx-check.h (main): Use __get_cpuid_count. * gcc.target/i386/bmi-check.h (main): Ditto. * gcc.target/i386/bmi2-check.h (main): Ditto. * gcc.target/i386/rtm-check.h

Re: PR82045: Avoid passing machine modes through "..."

2017-09-03 Thread Jeff Law
On 09/01/2017 07:55 AM, Richard Sandiford wrote: > PR82045 is about a bootstrap failure on sparc-sun-solaris2.11. > The problem was that we were passing the new machine_mode wrapper > classes through "..." to emit_library_call(_value), which then > read them back as ints instead. > > The simplest

Re: [PING][PATCH 2/3] retire mem_signal_fence pattern

2017-09-03 Thread Jeff Law
On 09/01/2017 12:26 AM, Alexander Monakov wrote: > On Thu, 31 Aug 2017, Jeff Law wrote: >> This is OK. >> >> What's the point of the delete_insns_since calls in patch #3? > > Deleting the first barrier when maybe_expand_insn failed. > Other functions in the file use a similar approach. Thanks for

Re: Add subreg_memory_offset helper functions

2017-09-03 Thread Jeff Law
On 08/28/2017 02:21 AM, Richard Sandiford wrote: > This patch adds routines for converting a SUBREG_BYTE offset into a > memory address offset. The two only differ for paradoxical subregs, > where SUBREG_BYTE is always 0 but the memory address offset can be > negative. > > Tested on aarch64-linux

Re: Turn MODES_TIEABLE_P into a target hook

2017-09-03 Thread Jeff Law
On 08/28/2017 03:36 AM, Richard Sandiford wrote: > The lack of function comments in msp430.c and rl78.c is deliberate; > the local style there is to define the hook macro immediately before > the function as a form of documentation. > > Tested on aarch64-linux-gnu, x86_64-linux-gnu and powerpc64le

Re: Turn HARD_REGNO_MODE_OK into a target hook

2017-09-03 Thread Jeff Law
On 08/28/2017 03:20 AM, Richard Sandiford wrote: > This is a bit of a workhorse macro, so it might make sense to add > some caching around the calls. If possible I'd like to do that > during stage 3 (under the usual "compile time is always a bug" thing); > we would still want this patch for that,

Re: Turn HARD_REGNO_CALL_PART_CLOBBERED into a target hook

2017-09-03 Thread Jeff Law
On 08/28/2017 02:39 AM, Richard Sandiford wrote: > The SVE patches change the size of a machine_mode from a compile-time > constant to a runtime invariant. However, target-specific code can > continue to treat the modes as constant-sized if the target only has > constant-sized modes. > > The main

Re: Make more use of GET_MODE_UNIT_SIZE

2017-09-03 Thread Jeff Law
On 08/23/2017 04:55 AM, Richard Sandiford wrote: > This patch uses GET_MODE_UNIT_SIZE instead of GET_MODE_SIZE in > cases where, for compound modes, the mode of the scalar elements > is what matters. E.g. the choice between truncation and extension > is really based on the modes of the consistuent

Re: Make more use of GET_MODE_UNIT_BITSIZE

2017-09-03 Thread Jeff Law
On 08/23/2017 04:56 AM, Richard Sandiford wrote: > This patch is like the previous GET_MODE_UNIT_SIZE one, > but for bit rather than byte sizes. > > Tested on aarch64-linux-gnu and x86_64-linux-gnu, and by making sure > that there were no differences in testsuite assembly output for one > target p

Re: Make more use of GET_MODE_UNIT_PRECISION

2017-09-03 Thread Jeff Law
On 08/23/2017 04:57 AM, Richard Sandiford wrote: > This patch is like the earlier GET_MODE_UNIT_SIZE one, > but for precisions rather than sizes. There is one behavioural > change in expand_debug_expr: we shouldn't use lowpart subregs > for non-scalar truncations, since that would just reinterpret

Re: Add a partial_integral_type_p helper function

2017-09-03 Thread Jeff Law
On 08/18/2017 02:13 AM, Richard Sandiford wrote: > This patch adds a partial_integral_type_p function, to go along > with the full_integral_type_p added by the previous patch. > > Of the changes that didn't previously have an INTEGRAL_TYPE_P check: > > - the convert_to_integer_1 hunks are dominat

Re: Add a partial_integral_type_p helper function

2017-09-03 Thread Jeff Law
On 08/25/2017 10:48 AM, Martin Sebor wrote: > On 08/18/2017 02:13 AM, Richard Sandiford wrote: >> This patch adds a partial_integral_type_p function, to go along >> with the full_integral_type_p added by the previous patch. >> >> Of the changes that didn't previously have an INTEGRAL_TYPE_P check:

Re: [PATCH] Disable type demotion for sanitizer (PR sanitizer/82072)

2017-09-03 Thread Jeff Law
On 09/01/2017 11:47 AM, Marek Polacek wrote: > Here, do_narrow and convert_to_integer_1 is demoting signed types to unsigned, > e.g. for > i = i - lmin > where i is int and lmin is long int, so what we should produce is > i = (int) ((long int) i - lmin) > but instead it produces > i = (int) (

Re: [PATCH]: PR target/80204 (Darwin macosx-version-min problem)

2017-09-03 Thread Jeff Law
On 09/01/2017 04:05 PM, Simon Wright wrote: > In gcc/config/darwin-driver.c, darwin_find_version_from_kernel() assumes > that the minor version in the Darwin kernel version (16.7.0, => minor > version 7) is equal to the bugfix component of the macOS version, so that > the compiler receives -mmacosx