public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug middle-end/66960] New: Add a builtin to get the address of the current stack frame
@ 2015-07-21 17:07 hjl.tools at gmail dot com
  2015-07-21 21:46 ` [Bug target/66960] " hjl.tools at gmail dot com
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: hjl.tools at gmail dot com @ 2015-07-21 17:07 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66960

            Bug ID: 66960
           Summary: Add a builtin to get the address of the current stack
                    frame
           Product: gcc
           Version: 6.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: middle-end
          Assignee: unassigned at gcc dot gnu.org
          Reporter: hjl.tools at gmail dot com
  Target Milestone: ---

The initial i386 stack layout is:

    environ     4*argc + 4 + %esp
    0                               4 bytes
    envp        8 + 4*argc + %esp   N * 4 bytes
    0           4 + 4*argc + %esp   4 bytes
    argv        %esp + 4            4*argc bytes
    argc        %esp                4 bytes

To get argc, argv and environ in C, we can use

---
extern char **environ;
extern void exit (int status);
extern int main (int argc, char **argv, char **envp);

void
_start (void)
{
  void *argc_p = __builtin_frame_address (0) + 4;
  char **argv = (char **) (argc_p + 4);
  int argc = *(int *) argc_p;
  int status;

  environ = argv + argc + 1;

  status = main (argc, argv, environ);

  exit (status);
}
---

With -O2 -m32 -miamcu, we generate

_start:
        pushl   %ebp
        movl    %esp, %ebp
        movl    4(%ebp), %eax
        leal    8(%ebp), %edx
        leal    4(%edx,%eax,4), %ecx
        movl    %ecx, environ
        call    main
        call    exit
        .size   _start, .-_start

%ebp is used since __builtin_frame_address always keeps the frame
pointer.  With a new builtin, __builtin_current_frame, which returns
the top of the stack frame, we can use

---

extern char **environ;
extern void exit (int status);
extern int main (int argc, char **argv, char **envp);

void
_start (void)
{
  void *argc_p = __builtin_current_frame ();
  char **argv = (char **) (argc_p + 4);
  int argc = *(int *) argc_p;
  int status;

  environ = argv + argc + 1;

  status = main (argc, argv, environ);

  exit (status);
}
---

and generate

_start:
        movl    (%esp), %eax
        leal    4(%esp), %edx
        leal    8(%esp,%eax,4), %ecx
        movl    %ecx, environ
        call    main
        call    exit
        .size   _start, .-_start

We can avoid using %ebp.

__builtin_current_frame may not be the best name.  We can use
__builtin_stack_top, __builtin_top_of_stack, which gives us the
stack address when the function is called.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug target/66960] Add a builtin to get the address of the current stack frame
  2015-07-21 17:07 [Bug middle-end/66960] New: Add a builtin to get the address of the current stack frame hjl.tools at gmail dot com
@ 2015-07-21 21:46 ` hjl.tools at gmail dot com
  2015-09-04 15:48 ` [Bug target/66960] Need a builtin function to access interrupt or exception data hjl.tools at gmail dot com
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: hjl.tools at gmail dot com @ 2015-07-21 21:46 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66960

H.J. Lu <hjl.tools at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2015-07-21
                 CC|                            |ubizjak at gmail dot com
          Component|middle-end                  |target
   Target Milestone|---                         |6.0
     Ever confirmed|0                           |1
           Severity|normal                      |enhancement

--- Comment #1 from H.J. Lu <hjl.tools at gmail dot com> ---
A patch is posted at

https://gcc.gnu.org/ml/gcc-patches/2015-07/msg01798.html


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug target/66960] Need a builtin function to access interrupt or exception data
  2015-07-21 17:07 [Bug middle-end/66960] New: Add a builtin to get the address of the current stack frame hjl.tools at gmail dot com
  2015-07-21 21:46 ` [Bug target/66960] " hjl.tools at gmail dot com
@ 2015-09-04 15:48 ` hjl.tools at gmail dot com
  2015-09-29 22:17 ` [Bug target/66960] Add interrupt/exception attribute to x86 backend hjl.tools at gmail dot com
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: hjl.tools at gmail dot com @ 2015-09-04 15:48 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66960

H.J. Lu <hjl.tools at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Target|                            |x86
            Summary|Add a builtin to get the    |Need a builtin function to
                   |address of the current      |access interrupt or
                   |stack frame                 |exception data

--- Comment #2 from H.J. Lu <hjl.tools at gmail dot com> ---
The interrupt and exception handlers are called by x86 processors.  X86
hardware pushes information onto stack and calls the handler.  We need
a builtin function to access interrupt or exception data from the
interrupt and exception handlers which are void function without
arguments.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug target/66960] Add interrupt/exception attribute to x86 backend
  2015-07-21 17:07 [Bug middle-end/66960] New: Add a builtin to get the address of the current stack frame hjl.tools at gmail dot com
  2015-07-21 21:46 ` [Bug target/66960] " hjl.tools at gmail dot com
  2015-09-04 15:48 ` [Bug target/66960] Need a builtin function to access interrupt or exception data hjl.tools at gmail dot com
@ 2015-09-29 22:17 ` hjl.tools at gmail dot com
  2016-07-04 10:39 ` [Bug target/66960] Add interrupt " goswin-v-b at web dot de
  2021-08-10 21:37 ` pinskia at gcc dot gnu.org
  4 siblings, 0 replies; 6+ messages in thread
From: hjl.tools at gmail dot com @ 2015-09-29 22:17 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66960

--- Comment #3 from H.J. Lu <hjl.tools at gmail dot com> ---
From

https://gcc.gnu.org/ml/gcc-patches/2015-09/msg02246.html

To be feature complete, it would be nice to have two styles of interrupt
functions, one that returns with iret, and one that returns with ret.
The point is that the user might want to call functions from a interrupt
handler and not save and restore all call clobbered registers.  By
allowing a ret style interrupt handler, calls to a ret style interrupt
routine can avoid saving and restoring all call clobbered registers.

[hjl@gnu-6 interrupt-7]$ cat call-1.i
extern void bar (void);

void
 __attribute__ ((interrupt))
fn1 (void *frame)
{
  bar ();
}

void
 __attribute__ ((interrupt))
fn2 (void *frame)
{
  bar ();
}
[hjl@gnu-6 interrupt-7]$ make
/export/build/gnu/gcc/build-x86_64-linux/gcc/xgcc
-B/export/build/gnu/gcc/build-x86_64-linux/gcc/ -O2 -Wall -Wunused-parameter
-mno-push-args -mno-sse -m32 -S -o call-1.s call-1.i
[hjl@gnu-6 interrupt-7]$ cat call-1.s
        .file   "call-1.i"
        .text
        .p2align 4,,15
        .globl  fn1
        .type   fn1, @function
fn1:
.LFB3:
        .cfi_startproc
        pushl   %ecx
        .cfi_def_cfa_offset 8
        .cfi_offset 1, -8
        pushl   %edx
        .cfi_def_cfa_offset 12
        .cfi_offset 2, -12
        pushl   %eax
        .cfi_def_cfa_offset 16
        .cfi_offset 0, -16
        call    bar
        popl    %eax
        .cfi_restore 0
        .cfi_def_cfa_offset 12
        popl    %edx
        .cfi_restore 2
        .cfi_def_cfa_offset 8
        popl    %ecx
        .cfi_restore 1
        .cfi_def_cfa_offset 4
        iret
        .cfi_endproc
.LFE3:
        .size   fn1, .-fn1
        .p2align 4,,15
        .globl  fn2
        .type   fn2, @function
fn2:
.LFB1:
        .cfi_startproc
        pushl   %ecx
        .cfi_def_cfa_offset 8
        .cfi_offset 1, -8
        pushl   %edx
        .cfi_def_cfa_offset 12
        .cfi_offset 2, -12
        pushl   %eax
        .cfi_def_cfa_offset 16
        .cfi_offset 0, -16
        call    bar
        popl    %eax
        .cfi_restore 0
        .cfi_def_cfa_offset 12
        popl    %edx
        .cfi_restore 2
        .cfi_def_cfa_offset 8
        popl    %ecx
        .cfi_restore 1
        .cfi_def_cfa_offset 4
        iret
        .cfi_endproc
.LFE1:
        .size   fn2, .-fn2
        .ident  "GCC: (GNU) 6.0.0 20150929 (experimental)"
        .section        .note.GNU-stack,"",@progbits
[hjl@gnu-6 interrupt-7]$  

Both fn1 and fn2 have to save and restore caller-saved registers.
If all registers in bar are callee-saved, fn1 and fn2 can be
much smaller.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug target/66960] Add interrupt attribute to x86 backend
  2015-07-21 17:07 [Bug middle-end/66960] New: Add a builtin to get the address of the current stack frame hjl.tools at gmail dot com
                   ` (2 preceding siblings ...)
  2015-09-29 22:17 ` [Bug target/66960] Add interrupt/exception attribute to x86 backend hjl.tools at gmail dot com
@ 2016-07-04 10:39 ` goswin-v-b at web dot de
  2021-08-10 21:37 ` pinskia at gcc dot gnu.org
  4 siblings, 0 replies; 6+ messages in thread
From: goswin-v-b at web dot de @ 2016-07-04 10:39 UTC (permalink / raw)
  To: gcc-bugs

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="UTF-8", Size: 304079 bytes --]

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66960

--- Comment #13 from Goswin von Brederlow <goswin-v-b at web dot de> ---
(In reply to H.J. Lu from comment #12)
> (In reply to Goswin von Brederlow from comment #11)
> > I think the design is fundamentally lacking in the following points:
> > 
> >     1. interrupt handler must be declared with a mandatory pointer argument:
> > 
> >     struct interrupt_frame;
> > 
> >     __attribute__ ((interrupt))
> >     void
> >     f (struct interrupt_frame *frame)
> >     {
> >     ...
> >     }
> > 
> >     and user must properly define the structure the pointer pointing to.
> > 
> > First how does one define the struct interrupt_frame properly? What is in
> > there? Is that just the data the CPU pushes to the stack? If so then gcc
> > should define the structure somewhere so code can be written cpu independent.
> 
> interrupt data is pushed onto stack by CPU:
> 
> struct interrupt_frame
> {
>   uword_t ip;
>   uword_t cs;
>   uword_t flags;
>   uword_t sp;
>   uword_t ss;
> };
> 
> However, void * works if you need to access interrupt data.  Interrupt
> handler should provide its working definition.
> 
> > Since the frame pointer is passed as argument I assume the function prolog
> > will save the first argument register (on amd64) to stack. Is that to be
> > included in the struct interrupt_frame?
> 
> No.  The interrupt frame pointer points to interrupt data on stack
> pushed by CPU.
> 
> > Secondly how does one access the original register contents? Some kernel
> > designs use a single kernel stack and switch tasks when returning to user
> > space. That means that one has to copy all the user registers into the
> > thread structure and reload a new set of user registers from the new thread
> > on exit from the interrupt handler. The above interface would not allow this.
> 
> The interrupt attribute provides a way to access interrupt data on stack
> pushed by CPU, nothing more and nothing less.

That design seriously limits the usability of this feature.

> > 
> >     2. exception handler:
> > 
> >     The exception handler is very similar to the interrupt handler with a
> > different mandatory function signature:
> > 
> >     typedef unsigned int uword_t __attribute__ ((mode (__word__)));
> > 
> >     struct interrupt_frame;
> > 
> >     __attribute__ ((interrupt))
> >     void
> >     f (struct interrupt_frame *frame, uword_t error_code)
> >     {
> >     ...
> >     }
> > 
> >     and compiler pops the error code off stack before the 'IRET' instruction.
> > 
> > In a kernel there will always be some exception that simply prints a
> > register dump and stack backtrace. So again how do you access the original
> > register contents?
> 
> You need to do that yourself.

Which means __attribute__ ((interrupt)) can't be used for exceptions half the
time.

> > Secondly why pass error_code as argument if is already on the stack and
> > could be accessed through the frame pointer? The argument register (amd64)
> > would have to be saved on the stack too causing an extra push/pop. But if it
> > is passed as argument then why not pop it before the call to keep the stack
> > frame the same as for interrupts (assuming the saved registers are not
> > included in the frame)?
> 
> error_code is a pseudo parameter, which is mapped to error code on stack
> pushed by CPU.  You can write a simple code to see it yourself.

Couldn't the same trick be used for registers? Pass them as pseudo parameters
and they either resolve to the location on the stack where gcc did save them or
become the original register unchanged.

> > If it is not poped or saved registers are included in the frame then the
> > exception stack frame differs from the interrupt frame (extra error_code and
> > extra register). They should not use the same structure, that's just
> > confusing.
> > 
> >     'no_caller_saved_registers' attribute
> > 
> >     Use this attribute to indicate that the specified function has no
> >     caller-saved registers.  That is, all registers are callee-saved.
> > 
> > Does that include the argument registers (if the function takes arguments)?
> 
> Yes.
> 
> > Wouldn't it be more flexible to define a list of registers that the function
> > will clobber?
> 
> How do programmer know which registers will be clobbered?

The programmer writes the function. He declares what registers will be
clobbered and gcc will add the necessary code to preserve any other registers
it uses inside the function.
>From gcc-bugs-return-529629-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 10:51:20 2016
Return-Path: <gcc-bugs-return-529629-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 9406 invoked by alias); 4 Jul 2016 10:51:20 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 8740 invoked by uid 48); 4 Jul 2016 10:51:07 -0000
From: "rguenth at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/71752] [7 Regression] ICE in compute_live_loop_exits, at tree-ssa-loop-manip.c:229 w/ -O1 -ftree-vectorize
Date: Mon, 04 Jul 2016 10:51:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: ice-on-valid-code
X-Bugzilla-Severity: normal
X-Bugzilla-Who: rguenth at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 7.0
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_status cf_reconfirmed_on target_milestone everconfirmed
Message-ID: <bug-71752-4-ag2rJfRER8@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71752-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71752-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00212.txt.bz2
Content-length: 537

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71752

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2016-07-04
   Target Milestone|---                         |7.0
     Ever confirmed|0                           |1

--- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> ---
Confirmed.
>From gcc-bugs-return-529630-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 11:03:22 2016
Return-Path: <gcc-bugs-return-529630-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 31570 invoked by alias); 4 Jul 2016 11:03:22 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 31357 invoked by uid 55); 4 Jul 2016 11:03:09 -0000
From: "rguenther at suse dot de" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug middle-end/70159] missed CSE optimization
Date: Mon, 04 Jul 2016 11:03:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: middle-end
X-Bugzilla-Version: 6.0
X-Bugzilla-Keywords: missed-optimization
X-Bugzilla-Severity: normal
X-Bugzilla-Who: rguenther at suse dot de
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-70159-4-2gfqE3RtPV@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-70159-4@http.gcc.gnu.org/bugzilla/>
References: <bug-70159-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00213.txt.bz2
Content-length: 3775

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70159

--- Comment #12 from rguenther at suse dot de <rguenther at suse dot de> ---
On Sat, 2 Jul 2016, hiraditya at msn dot com wrote:

> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70159
> 
> AK <hiraditya at msn dot com> changed:
> 
>            What    |Removed                     |Added
> ----------------------------------------------------------------------------
>                  CC|                            |hiraditya at msn dot com
> 
> --- Comment #11 from AK <hiraditya at msn dot com> ---
> Just as an update, the new gvn-hoist pass in llvm hoists the common
> computations:
> 
> @cat test.c
> float foo_p(float d, float min, float max, float a)
> {
>   float tmin;
>   float tmax;
> 
>   float inv = 1.0f / d;
>   if (inv >= 0) {
>     tmin = (min - a) * inv;
>     tmax = (max - a) * inv;
>   } else {
>     tmin = (max - a) * inv;
>     tmax = (min - a) * inv;
>   }
> 
>   return tmax + tmin;
> }
> 
> 
> clang -c -Ofast test.c -mllvm -print-after-all
> 
> 
> *** IR Dump Before Early GVN Hoisting of Expressions ***
> ; Function Attrs: nounwind uwtable
> define float @_Z5foo_pffff(float %d, float %min, float %max, float %a) #0 {
> entry:
>   %div = fdiv fast float 1.000000e+00, %d
>   %cmp = fcmp fast oge float %div, 0.000000e+00
>   br i1 %cmp, label %if.then, label %if.else
> 
> if.then:                                          ; preds = %entry
>   %sub = fsub fast float %min, %a
>   %mul = fmul fast float %sub, %div
>   %sub1 = fsub fast float %max, %a
>   %mul2 = fmul fast float %sub1, %div
>   br label %if.end
> 
> if.else:                                          ; preds = %entry
>   %sub3 = fsub fast float %max, %a
>   %mul4 = fmul fast float %sub3, %div
>   %sub5 = fsub fast float %min, %a
>   %mul6 = fmul fast float %sub5, %div
>   br label %if.end
> 
> if.end:                                           ; preds = %if.else, %if.then
>   %tmax.0 = phi float [ %mul2, %if.then ], [ %mul6, %if.else ]
>   %tmin.0 = phi float [ %mul, %if.then ], [ %mul4, %if.else ]
>   %add = fadd fast float %tmax.0, %tmin.0
>   ret float %add
> }
> 
> 
> *** IR Dump After Early GVN Hoisting of Expressions ***
> ; Function Attrs: nounwind uwtable
> define float @_Z5foo_pffff(float %d, float %min, float %max, float %a) #0 {
> entry:
>   %div = fdiv fast float 1.000000e+00, %d
>   %cmp = fcmp fast oge float %div, 0.000000e+00
>   %sub = fsub fast float %min, %a
>   %mul = fmul fast float %sub, %div
>   %sub1 = fsub fast float %max, %a
>   %mul2 = fmul fast float %sub1, %div
>   br i1 %cmp, label %if.then, label %if.else
> 
> if.then:                                          ; preds = %entry
>   br label %if.end
> 
> if.else:                                          ; preds = %entry
>   br label %if.end
> 
> if.end:                                           ; preds = %if.else, %if.then
>   %tmax.0 = phi float [ %mul2, %if.then ], [ %mul, %if.else ]
>   %tmin.0 = phi float [ %mul, %if.then ], [ %mul2, %if.else ]
>   %add = fadd fast float %tmax.0, %tmin.0
>   ret float %add
> }

Same if you forward-port the patch from PR23286 (just did that).

> cat t.c.126t.pre
...
foo_p (float d, float min, float max, float a)
{
  float inv;
  float tmax;
  float tmin;
  float _16;
  float _18;
  float _19;
  float _20;
  float _21;

  <bb 2>:
  inv_8 = 1.0e+0 / d_7(D);
  _18 = min_9(D) - a_10(D);
  _19 = inv_8 * _18;
  _20 = max_12(D) - a_10(D);
  _21 = inv_8 * _20;
  if (inv_8 >= 0.0)
    goto <bb 4>;
  else
    goto <bb 3>;

  <bb 3>:

  <bb 4>:
  # tmin_5 = PHI <_19(2), _21(3)>
  # tmax_6 = PHI <_21(2), _19(3)>
  _16 = tmin_5 + tmax_6;
  return _16;
>From gcc-bugs-return-529631-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 11:51:51 2016
Return-Path: <gcc-bugs-return-529631-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 19971 invoked by alias); 4 Jul 2016 11:51:51 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 19796 invoked by uid 48); 4 Jul 2016 11:51:39 -0000
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/71691] [6/7 Regression] wrong code at -O3 in both 32-bit and 64-bit modes on x86_64-linux-gnu (Floating point exception)
Date: Mon, 04 Jul 2016 11:51:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: wrong-code
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jakub at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 6.2
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71691-4-fiaT45UrHL@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71691-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71691-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00214.txt.bz2
Content-length: 1407

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71691

--- Comment #5 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
I bet this is related to the uninitialized i.
We have in bb3:

  # RANGE [0, 1] NONZERO 1
  # i_57 = PHI <prephitmp_78(36), i_27(D)(2)>

and in bb5:

  # RANGE [0, 1] NONZERO 1
  # i_48 = PHI <i_57(4), prephitmp_78(34)>

and in bb6:

  if (i_48 != 0)

and in basic blocks dominated by the succ edges of bb6 uncprop replaces some 0s
or 1s in phi with i_48.  The value ranges ignore the uninitialized values, with
the rationale that if the SSA_NAME is used somewhere, then in valid program it
should be initialized.  The problem here is that the if (i_48 != 0) comparison
has been added artificially in the ch2 pass, hoisted before the condition that
guarded its use.  But at the point where the artificial i_48 != 0 is present
even valid program can reach the point with uninitialized i and thus with the
value range assumption violated.  And then uncprop adds further uses of i_48,
in places that are dominated by this artificial i_48 != 0, but aren't dominated
by the original uses of i in the program.

Not sure what can be done here though.
Penalizing VRP by using always VARING for undefined values would probably slow
down lots of code, not hoisting uses of partially undefined values is
problematic, reverting the uncprop patch would be unfortunate.
>From gcc-bugs-return-529632-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 11:58:48 2016
Return-Path: <gcc-bugs-return-529632-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 86516 invoked by alias); 4 Jul 2016 11:58:48 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 86449 invoked by uid 48); 4 Jul 2016 11:58:35 -0000
From: "marxin at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/71751] [7 Regression] Segmentation fault in ssa_default_def
Date: Mon, 04 Jul 2016 11:58:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: ice-on-valid-code
X-Bugzilla-Severity: normal
X-Bugzilla-Who: marxin at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 7.0
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_status cf_reconfirmed_on cc everconfirmed
Message-ID: <bug-71751-4-KoJcC9WweJ@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71751-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71751-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00215.txt.bz2
Content-length: 621

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71751

Martin Liška <marxin at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2016-07-04
                 CC|                            |marxin at gcc dot gnu.org
     Ever confirmed|0                           |1

--- Comment #1 from Martin Liška <marxin at gcc dot gnu.org> ---
Confirmed on x86_64-linux on current trunk, GCC 6 branch looks good.
>From gcc-bugs-return-529633-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 12:02:10 2016
Return-Path: <gcc-bugs-return-529633-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 99064 invoked by alias); 4 Jul 2016 12:02:09 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 98782 invoked by uid 48); 4 Jul 2016 12:01:57 -0000
From: "redi at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/71010] error: 'begin' was not declared in this scope
Date: Mon, 04 Jul 2016 12:02:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: redi at gcc dot gnu.org
X-Bugzilla-Status: RESOLVED
X-Bugzilla-Resolution: INVALID
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71010-4-tIfPZ1pQR3@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71010-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71010-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00216.txt.bz2
Content-length: 695

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71010

--- Comment #5 from Jonathan Wakely <redi at gcc dot gnu.org> ---
(In reply to Ubikovich from comment #3)
> But since C++14 cbegin invoke std::begin:
> 
> // http://en.cppreference.com/w/cpp/iterator/begin
> template< class C >
> constexpr auto cbegin( const C& c ) -> decltype(std::begin(c));
> (3) 	 	(since C++14)
> 
> Then in what namespace should be user-defined begin/end?

I already explained how to do it correctly, please read comment 1 again.



(In reply to Andrew Pinski from comment #4)
> In the same as the class so ADR (argument dependent resolution) can find it.

N.B. that should be ADL (argument dependent *lookup*).
>From gcc-bugs-return-529634-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 12:15:50 2016
Return-Path: <gcc-bugs-return-529634-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 130192 invoked by alias); 4 Jul 2016 12:15:50 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 130047 invoked by uid 48); 4 Jul 2016 12:15:35 -0000
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c/71719] [7 Regression] invalid set-but-not-used warning with vectors
Date: Mon, 04 Jul 2016 12:15:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: diagnostic
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jakub at gcc dot gnu.org
X-Bugzilla-Status: RESOLVED
X-Bugzilla-Resolution: FIXED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: jakub at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 7.0
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_status resolution
Message-ID: <bug-71719-4-0eIJboaAcP@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71719-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71719-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00217.txt.bz2
Content-length: 423

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71719

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|---                         |FIXED

--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Fixed.
>From gcc-bugs-return-529635-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 12:48:32 2016
Return-Path: <gcc-bugs-return-529635-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 20501 invoked by alias); 4 Jul 2016 12:48:31 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 20403 invoked by uid 48); 4 Jul 2016 12:48:19 -0000
From: "alahay01 at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug debug/71667] [7 Regression] ICE in as_a, at is-a.h:192 w/ -g -O2 -ftree-vectorize
Date: Mon, 04 Jul 2016 12:48:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: debug
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: ice-on-valid-code
X-Bugzilla-Severity: normal
X-Bugzilla-Who: alahay01 at gcc dot gnu.org
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: alahay01 at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 7.0
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71667-4-mFcQEzjRV0@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71667-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71667-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00218.txt.bz2
Content-length: 296

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71667

--- Comment #5 from alahay01 at gcc dot gnu.org ---
Qirun:

That looks like a separate issue.
My fix for 71667 (under review) is specific to debug statements.

Could you please raise your test case as a new bug and assign it to me. Thanks!
>From gcc-bugs-return-529636-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 12:53:34 2016
Return-Path: <gcc-bugs-return-529636-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 24391 invoked by alias); 4 Jul 2016 12:53:34 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 24287 invoked by uid 55); 4 Jul 2016 12:53:21 -0000
From: "ville at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libstdc++/71313] [Filesystem TS] remove_all fails to remove directory contents recursively
Date: Mon, 04 Jul 2016 12:53:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: libstdc++
X-Bugzilla-Version: 6.1.1
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: ville at gcc dot gnu.org
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: ville.voutilainen at gmail dot com
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71313-4-bEIJktgsEp@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71313-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71313-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00219.txt.bz2
Content-length: 678

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71313

--- Comment #2 from ville at gcc dot gnu.org ---
Author: ville
Date: Mon Jul  4 12:52:49 2016
New Revision: 237978

URL: https://gcc.gnu.org/viewcvs?rev=237978&root=gcc&view=rev
Log:
        PR libstdc++/71313
        * src/filesystem/ops.cc (remove_all(const path&, error_code&)):
        Call remove_all for children of a directory.
        * testsuite/experimental/filesystem/operations/create_directories.cc:
        Adjust.

Modified:
    trunk/libstdc++-v3/ChangeLog
    trunk/libstdc++-v3/src/filesystem/ops.cc
   
trunk/libstdc++-v3/testsuite/experimental/filesystem/operations/create_directories.cc
>From gcc-bugs-return-529637-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 12:54:46 2016
Return-Path: <gcc-bugs-return-529637-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 28715 invoked by alias); 4 Jul 2016 12:54:45 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 27586 invoked by uid 48); 4 Jul 2016 12:54:33 -0000
From: "ville.voutilainen at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libstdc++/71313] [Filesystem TS] remove_all fails to remove directory contents recursively
Date: Mon, 04 Jul 2016 12:54:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: libstdc++
X-Bugzilla-Version: 6.1.1
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: ville.voutilainen at gmail dot com
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: ville.voutilainen at gmail dot com
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71313-4-WCloXkpXta@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71313-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71313-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00220.txt.bz2
Content-length: 198

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71313

--- Comment #3 from Ville Voutilainen <ville.voutilainen at gmail dot com> ---
Fixed on trunk so far, backporting to gcc-6 and gcc-5 shortly.
>From gcc-bugs-return-529638-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 13:15:55 2016
Return-Path: <gcc-bugs-return-529638-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 111775 invoked by alias); 4 Jul 2016 13:15:55 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 111680 invoked by uid 55); 4 Jul 2016 13:15:42 -0000
From: "ville at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libstdc++/71313] [Filesystem TS] remove_all fails to remove directory contents recursively
Date: Mon, 04 Jul 2016 13:15:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: libstdc++
X-Bugzilla-Version: 6.1.1
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: ville at gcc dot gnu.org
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: ville.voutilainen at gmail dot com
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71313-4-ZxPrh5ILnG@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71313-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71313-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00221.txt.bz2
Content-length: 726

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71313

--- Comment #4 from ville at gcc dot gnu.org ---
Author: ville
Date: Mon Jul  4 13:15:10 2016
New Revision: 237980

URL: https://gcc.gnu.org/viewcvs?rev=237980&root=gcc&view=rev
Log:
        PR libstdc++/71313
        * src/filesystem/ops.cc (remove_all(const path&, error_code&)):
        Call remove_all for children of a directory.
        * testsuite/experimental/filesystem/operations/create_directories.cc:
        Adjust.

Modified:
    branches/gcc-6-branch/libstdc++-v3/ChangeLog
    branches/gcc-6-branch/libstdc++-v3/src/filesystem/ops.cc
   
branches/gcc-6-branch/libstdc++-v3/testsuite/experimental/filesystem/operations/create_directories.cc
>From gcc-bugs-return-529639-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 13:26:09 2016
Return-Path: <gcc-bugs-return-529639-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 59702 invoked by alias); 4 Jul 2016 13:26:09 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 59474 invoked by uid 48); 4 Jul 2016 13:25:55 -0000
From: "olme8 at mail dot ru" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c/71754] New: gcc prints internal error on ARM NEON code with buffer overflow
Date: Mon, 04 Jul 2016 13:26:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: minor
X-Bugzilla-Who: olme8 at mail dot ru
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone
Message-ID: <bug-71754-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00222.txt.bz2
Content-length: 2025

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71754

            Bug ID: 71754
           Summary: gcc prints internal error on ARM NEON code with buffer
                    overflow
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Severity: minor
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: olme8 at mail dot ru
  Target Milestone: ---

$ cat test.c
#if 0
#include <arm_neon.h>
#else
typedef int int32_t;
typedef __builtin_neon_si int32x2_t     __attribute__ ((__vector_size__ (8)));

__extension__ static __inline void __attribute__ ((__always_inline__))
vst1_s32 (int32_t * __a, int32x2_t __b) {
  __builtin_neon_vst1v2si ((__builtin_neon_si *) __a, __b);
}
#endif

void test(int32x2_t a) {
        int temp[1];
        vst1_s32(temp+1, a);
}

$ NDK=$HOME/android-ndk-r11c
$
$NDK/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-gcc
--version
arm-linux-androideabi-gcc (GCC) 4.9 20150123 (prerelease)
Copyright (C) 2014 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

$
$NDK/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-gcc
--sysroot=$NDK/platforms/android-21/arch-arm -Wall -Wextra -O2 -march=armv7-a
-mfloat-abi=softfp -mfpu=neon -c test.c -o test.o
test.c: In function 'test':
test.c:17:1: error: unrecognizable insn:
 }
 ^
(insn 6 3 0 2 (set (mem:V2SI (reg/f:SI 105 virtual-stack-vars) [0
MEM[(__builtin_neon_si[2] *)&temp + 4B]+0 S8 A32])
        (unspec:V2SI [
                (reg/v:V2SI 110 [ a ])
            ] UNSPEC_VST1)) test.c:10 -1
     (nil))
test.c:17:1: internal compiler error: in extract_insn, at recog.c:2202
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://source.android.com/source/report-bugs.html> for instructions.
>From gcc-bugs-return-529640-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 13:31:35 2016
Return-Path: <gcc-bugs-return-529640-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 80029 invoked by alias); 4 Jul 2016 13:31:35 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 79944 invoked by uid 48); 4 Jul 2016 13:31:30 -0000
From: "dcb314 at hotmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug middle-end/49905] Better sanity checking on sprintf src & dest to produce warning for dodgy code ?
Date: Mon, 04 Jul 2016 13:31:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: middle-end
X-Bugzilla-Version: 4.7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: enhancement
X-Bugzilla-Who: dcb314 at hotmail dot com
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: msebor at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-49905-4-GD1K9nUrYm@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-49905-4@http.gcc.gnu.org/bugzilla/>
References: <bug-49905-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00223.txt.bz2
Content-length: 256

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=49905

--- Comment #12 from David Binderman <dcb314 at hotmail dot com> ---
(In reply to David Binderman from comment #11)
> So it looks to me like format %Lx isn't handled.

Also, %lf seems to cause a crash.
>From gcc-bugs-return-529641-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 13:33:58 2016
Return-Path: <gcc-bugs-return-529641-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 81852 invoked by alias); 4 Jul 2016 13:33:58 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 81743 invoked by uid 48); 4 Jul 2016 13:33:45 -0000
From: "ktkachov at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/71754] [4.9 Regression] gcc prints internal error on ARM NEON code with buffer overflow
Date: Mon, 04 Jul 2016 13:33:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: target
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: minor
X-Bugzilla-Who: ktkachov at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 4.9.5
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: cf_gcctarget bug_status cf_known_to_work cf_reconfirmed_on component cc everconfirmed short_desc target_milestone cf_known_to_fail
Message-ID: <bug-71754-4-bqfC0EK6dO@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71754-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71754-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00224.txt.bz2
Content-length: 1082

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71754

ktkachov at gcc dot gnu.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Target|                            |arm*
             Status|UNCONFIRMED                 |NEW
      Known to work|                            |5.4.1, 6.1.0, 7.0
   Last reconfirmed|                            |2016-07-04
          Component|c                           |target
                 CC|                            |ktkachov at gcc dot gnu.org
     Ever confirmed|0                           |1
            Summary|gcc prints internal error   |[4.9 Regression] gcc prints
                   |on ARM NEON code with       |internal error on ARM NEON
                   |buffer overflow             |code with buffer overflow
   Target Milestone|---                         |4.9.5
      Known to fail|                            |4.9.4

--- Comment #1 from ktkachov at gcc dot gnu.org ---
Confirmed on 4.9.4.
Doesn't ICE on GCC 5 onwards
>From gcc-bugs-return-529642-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 13:51:42 2016
Return-Path: <gcc-bugs-return-529642-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 6050 invoked by alias); 4 Jul 2016 13:51:42 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 5923 invoked by uid 48); 4 Jul 2016 13:51:29 -0000
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/70729] Loop marked with omp simd pragma is not vectorized
Date: Mon, 04 Jul 2016 13:51:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: openmp
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jakub at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-70729-4-aL2Vxz0LX9@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
References: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00225.txt.bz2
Content-length: 2392

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70729

--- Comment #29 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
The #c27 r237844 change looks bogus to me.
First of all, IMNSHO you can argue this way only if ref is a reference seen in
loop LOOP, which is the case of e.g. *.omp_data_i_23(D).a ref in simd3.f90 -O2
-fopenmp -msse2, but not the D.3815[0] case tested during can_sm_ref_p - the
D.3815[0] = 0; as well as something = D.3815[0]; stmt found in the outer loop
obviously can be dependent on many of the loads and/or stores in the loop, be
it "omp simd array" or not.
Say for
void
foo (int *p, int *q)
{
  #pragma omp simd
  for (int i = 0; i < 1024; i++)
    p[i] += q[0];
}
sure, q[0] can't alias p[0] ... p[1022], the earlier iterations could write
something that changes its value, and then it would behave differently from
using VF = 1024, where everything is performed in parallel.
Though, actually, it can alias, just it would have to write the same value as
was there.  So, if this is used to determine if it is safe to hoist the load
before the loop, it is fine, if it is used to determine if &q[0] >= &p[0] &&
&q[0] <= &p[1023], then it is not fine.

For aliasing of q[0] and p[1023], I don't see why they couldn't alias in a
valid program.  #pragma omp simd I think guarantees that the last iteration is
executed last, it isn't necessarily executed last alone, it could be, or
together with one before last iteration, or (for simdlen INT_MAX) even all
iterations can be done concurrently, in hw or sw, so it is fine if it is
transformed into:
  int temp[1024], temp2[1024], temp3[1024];
  for (int i = 0; i < 1024; i++)
    temp[i] = p[i];
  for (int i = 0; i < 1024; i++)
    temp2[i] = q[0];
  /* The above two loops can be also swapped, or intermixed.  */
  for (int i = 0; i < 1024; i++)
    temp3[i] = temp[i] + temp2[i];
  for (int i = 0; i < 1024; i++)
    p[i] = temp3[i];
  /* Or the above loop reversed etc. */

If you have:
int
bar (int *p, int *q)
{
  q[0] = 0;
  #pragma omp simd
  for (int i = 0; i < 1024; i++)
    p[i]++;
  return q[0];
}
i.e. something similar to what misbehaves in simd3.f90 with the change, then
the answer is that q[0] isn't guaranteed to be independent of any references in
the simd loop.

BTW, the r237844 change is badly formatted, missing spaces before (, too long
lines...
>From gcc-bugs-return-529643-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 13:52:39 2016
Return-Path: <gcc-bugs-return-529643-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 7594 invoked by alias); 4 Jul 2016 13:52:39 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 7448 invoked by uid 48); 4 Jul 2016 13:52:26 -0000
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug middle-end/71734] [7 Regression] FAIL: libgomp.fortran/simd4.f90   -O3 -g  execution test
Date: Mon, 04 Jul 2016 13:52:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: middle-end
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jakub at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 7.0
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: cc
Message-ID: <bug-71734-4-Dd3W9RzNr1@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71734-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71734-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00226.txt.bz2
Content-length: 404

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71734

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jakub at gcc dot gnu.org

--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
See my comment in PR70729.
>From gcc-bugs-return-529644-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 13:53:07 2016
Return-Path: <gcc-bugs-return-529644-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 8474 invoked by alias); 4 Jul 2016 13:53:06 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 8338 invoked by uid 55); 4 Jul 2016 13:52:53 -0000
From: "ville at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libstdc++/71313] [Filesystem TS] remove_all fails to remove directory contents recursively
Date: Mon, 04 Jul 2016 13:53:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: libstdc++
X-Bugzilla-Version: 6.1.1
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: ville at gcc dot gnu.org
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: ville.voutilainen at gmail dot com
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71313-4-IbIBcDxHTv@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71313-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71313-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00227.txt.bz2
Content-length: 827

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71313

--- Comment #5 from ville at gcc dot gnu.org ---
Author: ville
Date: Mon Jul  4 13:52:21 2016
New Revision: 237981

URL: https://gcc.gnu.org/viewcvs?rev=237981&root=gcc&view=rev
Log:
        Backport from mainline
        2016-07-04  Ville Voutilainen  <ville.voutilainen@gmail.com>

        PR libstdc++/71313
        * src/filesystem/ops.cc (remove_all(const path&, error_code&)):
        Call remove_all for children of a directory.
        * testsuite/experimental/filesystem/operations/create_directories.cc:
        Adjust.

Modified:
    branches/gcc-5-branch/libstdc++-v3/ChangeLog
    branches/gcc-5-branch/libstdc++-v3/src/filesystem/ops.cc
   
branches/gcc-5-branch/libstdc++-v3/testsuite/experimental/filesystem/operations/create_directories.cc
>From gcc-bugs-return-529645-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 13:53:34 2016
Return-Path: <gcc-bugs-return-529645-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 10223 invoked by alias); 4 Jul 2016 13:53:33 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 9185 invoked by uid 48); 4 Jul 2016 13:53:20 -0000
From: "ville.voutilainen at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libstdc++/71313] [Filesystem TS] remove_all fails to remove directory contents recursively
Date: Mon, 04 Jul 2016 13:53:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: libstdc++
X-Bugzilla-Version: 6.1.1
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: ville.voutilainen at gmail dot com
X-Bugzilla-Status: RESOLVED
X-Bugzilla-Resolution: FIXED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: ville.voutilainen at gmail dot com
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_status resolution
Message-ID: <bug-71313-4-ErDooT9pBE@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71313-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71313-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00228.txt.bz2
Content-length: 469

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71313

Ville Voutilainen <ville.voutilainen at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|---                         |FIXED

--- Comment #6 from Ville Voutilainen <ville.voutilainen at gmail dot com> ---
Fixed on all branches.
>From gcc-bugs-return-529646-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 14:21:11 2016
Return-Path: <gcc-bugs-return-529646-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 89476 invoked by alias); 4 Jul 2016 14:21:11 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 88953 invoked by uid 48); 4 Jul 2016 14:20:58 -0000
From: "trippels at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug ipa/71190] [7 Regression] ICE in assemble_variable_contents, at varasm.c:2054
Date: Mon, 04 Jul 2016 14:21:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: ipa
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: ice-on-valid-code, lto
X-Bugzilla-Severity: normal
X-Bugzilla-Who: trippels at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 7.0
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71190-4-wKPls1g9E0@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71190-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71190-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00229.txt.bz2
Content-length: 209

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71190

--- Comment #5 from Markus Trippelsdorf <trippels at gcc dot gnu.org> ---
I'm down to 16 *.ii files. It will probably take a few days to creduce them
all.
>From gcc-bugs-return-529647-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 14:33:48 2016
Return-Path: <gcc-bugs-return-529647-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 87381 invoked by alias); 4 Jul 2016 14:33:48 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 87053 invoked by uid 48); 4 Jul 2016 14:33:35 -0000
From: "thopre01 at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/71715] FAIL: 23_containers/deque/modifiers/swap/2.cc (test for excess errors)
Date: Mon, 04 Jul 2016 14:33:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: thopre01 at gcc dot gnu.org
X-Bugzilla-Status: RESOLVED
X-Bugzilla-Resolution: DUPLICATE
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_status resolution
Message-ID: <bug-71715-4-zfD0U8UJ5j@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71715-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71715-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00230.txt.bz2
Content-length: 529

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71715

Thomas Preud'homme <thopre01 at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |DUPLICATE

--- Comment #1 from Thomas Preud'homme <thopre01 at gcc dot gnu.org> ---
This is a duplicate of PR71707

*** This bug has been marked as a duplicate of bug 71707 ***
>From gcc-bugs-return-529648-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 14:33:48 2016
Return-Path: <gcc-bugs-return-529648-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 87393 invoked by alias); 4 Jul 2016 14:33:48 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 87183 invoked by uid 48); 4 Jul 2016 14:33:36 -0000
From: "thopre01 at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/71707] [7 Regression] ICE in get_stridx_plus_constant
Date: Mon, 04 Jul 2016 14:33:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: thopre01 at gcc dot gnu.org
X-Bugzilla-Status: RESOLVED
X-Bugzilla-Resolution: FIXED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: jakub at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 7.0
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: cc
Message-ID: <bug-71707-4-2cgrajTu6U@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71707-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71707-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00231.txt.bz2
Content-length: 458

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71707

Thomas Preud'homme <thopre01 at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |thopre01 at gcc dot gnu.org

--- Comment #7 from Thomas Preud'homme <thopre01 at gcc dot gnu.org> ---
*** Bug 71715 has been marked as a duplicate of this bug. ***
>From gcc-bugs-return-529649-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 14:54:08 2016
Return-Path: <gcc-bugs-return-529649-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 118883 invoked by alias); 4 Jul 2016 14:54:08 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 118777 invoked by uid 48); 4 Jul 2016 14:53:54 -0000
From: "lukasz.spintzyk at displaylink dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/71753] Clamp function does not work with O3 optimization
Date: Mon, 04 Jul 2016 14:54:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: lukasz.spintzyk at displaylink dot com
X-Bugzilla-Status: RESOLVED
X-Bugzilla-Resolution: INVALID
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71753-4-cy7VcWLMSh@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71753-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71753-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00232.txt.bz2
Content-length: 269

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71753

--- Comment #6 from Łukasz Spintzyk <lukasz.spintzyk at displaylink dot com> ---
I confirm changing the code to use unsigned int fixed the problem.

Also there is no signed overflow errors. 

Thanks a lot.
>From gcc-bugs-return-529650-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 14:54:46 2016
Return-Path: <gcc-bugs-return-529650-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 123292 invoked by alias); 4 Jul 2016 14:54:45 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 122938 invoked by uid 48); 4 Jul 2016 14:54:33 -0000
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/70729] Loop marked with omp simd pragma is not vectorized
Date: Mon, 04 Jul 2016 14:54:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: openmp
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jakub at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-70729-4-GKQpufcbKQ@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
References: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00233.txt.bz2
Content-length: 608

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70729

--- Comment #30 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Another thing to think of, e.g.
void
baz (int *p, int *q)
{
  #pragma omp simd safelen(2)
  for (int i = 0; i < 1024; i++)
    p[4 * i] += q[0];
}
for aliasing p[4 * 1022] I think still applies that if (&q[0] == &p[4 * 1022])
then p[4 * 1022] == 0 upon entry to the loop, because while the penultimate
iteration could be executed in the SIMD chunk, it could as well be executed
before the last iteration and thus if it changes its value, it would mean
undefined behavior.
>From gcc-bugs-return-529651-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 14:58:05 2016
Return-Path: <gcc-bugs-return-529651-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 9010 invoked by alias); 4 Jul 2016 14:58:05 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 8199 invoked by uid 48); 4 Jul 2016 14:57:52 -0000
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/70729] Loop marked with omp simd pragma is not vectorized
Date: Mon, 04 Jul 2016 14:58:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: openmp
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jakub at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-70729-4-iuESBwAoK4@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
References: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00234.txt.bz2
Content-length: 404

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70729

--- Comment #31 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
A question is if #pragma GCC ivdep has similar guarantees/restrictions; the
documentation only disallows certain loop-carried dependencies, in particular
those that would prevent vectorization, so I think it is the same as
unspecified (== infinite) safelen on #pragma omp simd.
>From gcc-bugs-return-529652-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 15:03:28 2016
Return-Path: <gcc-bugs-return-529652-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 44396 invoked by alias); 4 Jul 2016 15:03:28 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 44232 invoked by uid 48); 4 Jul 2016 15:03:16 -0000
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/70729] Loop marked with omp simd pragma is not vectorized
Date: Mon, 04 Jul 2016 15:03:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: openmp
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jakub at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-70729-4-UWWnKEPuRU@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
References: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00235.txt.bz2
Content-length: 635

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70729

--- Comment #32 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Also, the testcase has weird dg- directives:
// { dg-do compile }
// { dg-require-effective-target vect_simd_clones }
// { dg-additional-options "-Ofast" }
// { dg-additional-options "-mavx2 -fopenmp-simd" { target x86_64-*-* i?86-*-*
} }

It doesn't use declare simd, so the dg-require-effective-target makes no sense.
-fopenmp-simd can be applied on all targets, -mavx2 of course not, but then the
dg-final should be probably guarded with x86_64* / i?86* or whatever other
arches are known to vectorize it.
>From gcc-bugs-return-529653-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 15:17:36 2016
Return-Path: <gcc-bugs-return-529653-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 91289 invoked by alias); 4 Jul 2016 15:17:35 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 91172 invoked by uid 48); 4 Jul 2016 15:17:23 -0000
From: "vz-gcc at zeitlins dot org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug preprocessor/28810] gcc -MD -MP doesn't add phony rule for source file
Date: Mon, 04 Jul 2016 15:17:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: preprocessor
X-Bugzilla-Version: unknown
X-Bugzilla-Keywords:
X-Bugzilla-Severity: enhancement
X-Bugzilla-Who: vz-gcc at zeitlins dot org
X-Bugzilla-Status: RESOLVED
X-Bugzilla-Resolution: INVALID
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: cc
Message-ID: <bug-28810-4-ZPJRgD7lUp@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-28810-4@http.gcc.gnu.org/bugzilla/>
References: <bug-28810-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00236.txt.bz2
Content-length: 1041

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=28810

Vadim Zeitlin <vz-gcc at zeitlins dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |vz-gcc at zeitlins dot org

--- Comment #4 from Vadim Zeitlin <vz-gcc at zeitlins dot org> ---
I don't understand the rationale of comment:1. When a source file is renamed
(and not removed), it makes perfect sense to still have the object file in a
makefile.

E.g. I'm using a build system which generates GNUmakefiles with rules of the
form

libname_file.o: subdir/file.cpp
        $(CXX) -MD -MP ... -o $@ $<

and if file.cpp is moved to subdir2/file.cpp, the build gets broken because the
existing libname_file.d has a dependency on subdir/file.cpp but no dummy rule
for this file.

It's obviously not going to solve my problem now, but I think it would be great
to remove the existing exception from -MP or, perhaps, add some new -MPP
switch.
>From gcc-bugs-return-529654-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 15:30:48 2016
Return-Path: <gcc-bugs-return-529654-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 44959 invoked by alias); 4 Jul 2016 15:30:48 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 33210 invoked by uid 48); 4 Jul 2016 15:30:40 -0000
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/70729] Loop marked with omp simd pragma is not vectorized
Date: Mon, 04 Jul 2016 15:30:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: openmp
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jakub at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-70729-4-VgmIBvx8Hx@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
References: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00237.txt.bz2
Content-length: 782

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70729

--- Comment #33 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
In any case, loop->safelen > 0 test looks also wrong, if there are guarantees
about single iteration only (safelen(1)), then there is nothing useful at all.
So it must be loop->safelen >= 2.

For foo in #c29, the q[0] load in foo can be hoisted before the loop.
More complicated is e.g.:
void baz (int *p, int *q, int *r, int *s)
{
  #pragma omp simd
  for (int i = 0; i < 1024; i++)
    {
      p[i] += q[0] * 6;
      r[i] += s[0] * 9;
    }
}
Here IMNSHO only q[0] * 6 can be hoisted before the loop, while it can alias
p[1023] (or for x < 1023 p[x] if p[x] is initially 0), p[1023] could validly
alias s[0] and thus s[0] * 9 must not be hoisted.
>From gcc-bugs-return-529655-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 16:12:55 2016
Return-Path: <gcc-bugs-return-529655-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 43192 invoked by alias); 4 Jul 2016 16:12:54 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 42452 invoked by uid 48); 4 Jul 2016 16:12:42 -0000
From: "ww2www2w at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/71755] New: friend function may not be defined inside a class using a qualified name but GCC allows that
Date: Mon, 04 Jul 2016 16:12:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 6.1.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: minor
X-Bugzilla-Who: ww2www2w at gmail dot com
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone
Message-ID: <bug-71755-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00238.txt.bz2
Content-length: 1199

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71755

            Bug ID: 71755
           Summary: friend function may not be defined inside a class
                    using a qualified name but GCC allows that
           Product: gcc
           Version: 6.1.0
            Status: UNCONFIRMED
          Severity: minor
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: ww2www2w at gmail dot com
  Target Milestone: ---

This code should not be compiled, but GCC compiles it successfully (btw vc++
and clang report an error).

#include <iostream>
using namespace std;

int ticket();

class Manager {

 friend int ::ticket() {  // qualified function name
     return ++Manager::counter;     
 }
 static int counter;
};

int Manager::counter;

int main() {

    cout << ticket();
    return 0;
}

g++ -std=c++14 -O2 -Wall -pedantic -pthread main.cpp && ./a.out

GCC should report an error because a friend function may not be defined inside
a class using a qualified name (it may only be declared). See 11.3.6 in 
http://open-std.org/JTC1/SC22/WG21/docs/papers/2016/n4594.pdf (or any c++
standard edition since 2003)
>From gcc-bugs-return-529656-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 16:17:22 2016
Return-Path: <gcc-bugs-return-529656-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 93427 invoked by alias); 4 Jul 2016 16:17:21 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 91371 invoked by uid 48); 4 Jul 2016 16:17:09 -0000
From: "vegard.nossum at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/71756] New: internal compiler error: in ~saved_token_sentinel, at cp/parser.c:1228
Date: Mon, 04 Jul 2016 16:17:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: vegard.nossum at gmail dot com
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone
Message-ID: <bug-71756-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00239.txt.bz2
Content-length: 2879

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71756

            Bug ID: 71756
           Summary: internal compiler error: in ~saved_token_sentinel, at
                    cp/parser.c:1228
           Product: gcc
           Version: 7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: vegard.nossum at gmail dot com
  Target Milestone: ---

Using this:

struct t {
        template<class F>
        t(F &&f)
        {
        }
};

void foo()
{
        (t([const &x]() { int y; }));
}

I get:

$ g++ internal-compiler-error.cc -lpthread
internal-compiler-error.cc: In lambda function:
internal-compiler-error.cc:10:25: internal compiler error: in
~saved_token_sentinel, at cp/parser.c:1228
  (t([const &x]() { int y; }));
                         ^
0x76d1e7 saved_token_sentinel::~saved_token_sentinel()
        /home/vegard/git/gcc/gcc/cp/parser.c:1228
0x76d1e7 cp_parser_statement
        /home/vegard/git/gcc/gcc/cp/parser.c:10350
0x76d524 cp_parser_statement_seq_opt
        /home/vegard/git/gcc/gcc/cp/parser.c:10804
0x772f5e cp_parser_lambda_body
        /home/vegard/git/gcc/gcc/cp/parser.c:10270
0x772f5e cp_parser_lambda_expression
        /home/vegard/git/gcc/gcc/cp/parser.c:9754
0x746284 cp_parser_primary_expression
        /home/vegard/git/gcc/gcc/cp/parser.c:4934
0x7512c6 cp_parser_postfix_expression
        /home/vegard/git/gcc/gcc/cp/parser.c:6688
0x74f794 cp_parser_unary_expression
        /home/vegard/git/gcc/gcc/cp/parser.c:7986
0x759867 cp_parser_cast_expression
        /home/vegard/git/gcc/gcc/cp/parser.c:8663
0x759e16 cp_parser_binary_expression
        /home/vegard/git/gcc/gcc/cp/parser.c:8764
0x75a6d0 cp_parser_assignment_expression
        /home/vegard/git/gcc/gcc/cp/parser.c:9051
0x75c2b6 cp_parser_parenthesized_expression_list
        /home/vegard/git/gcc/gcc/cp/parser.c:7457
0x75cd41 cp_parser_functional_cast
        /home/vegard/git/gcc/gcc/cp/parser.c:25943
0x7511d3 cp_parser_postfix_expression
        /home/vegard/git/gcc/gcc/cp/parser.c:6616
0x74f794 cp_parser_unary_expression
        /home/vegard/git/gcc/gcc/cp/parser.c:7986
0x759867 cp_parser_cast_expression
        /home/vegard/git/gcc/gcc/cp/parser.c:8663
0x759e16 cp_parser_binary_expression
        /home/vegard/git/gcc/gcc/cp/parser.c:8764
0x75a6d0 cp_parser_assignment_expression
        /home/vegard/git/gcc/gcc/cp/parser.c:9051
0x75d06a cp_parser_expression
        /home/vegard/git/gcc/gcc/cp/parser.c:9220
0x74613e cp_parser_primary_expression
        /home/vegard/git/gcc/gcc/cp/parser.c:4879
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <http://gcc.gnu.org/bugs.html> for instructions.

$ gcc --version
gcc (GCC) 7.0.0 20160520 (experimental)
>From gcc-bugs-return-529657-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 16:17:42 2016
Return-Path: <gcc-bugs-return-529657-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 95305 invoked by alias); 4 Jul 2016 16:17:42 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 95257 invoked by uid 48); 4 Jul 2016 16:17:35 -0000
From: "hjl.tools at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/66960] Add interrupt attribute to x86 backend
Date: Mon, 04 Jul 2016 16:17:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: target
X-Bugzilla-Version: 6.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: enhancement
X-Bugzilla-Who: hjl.tools at gmail dot com
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 6.2
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-66960-4-34MH47ut9N@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-66960-4@http.gcc.gnu.org/bugzilla/>
References: <bug-66960-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00240.txt.bz2
Content-length: 2559

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66960

--- Comment #14 from H.J. Lu <hjl.tools at gmail dot com> ---
(In reply to Goswin von Brederlow from comment #13)

> > > 
> > > In a kernel there will always be some exception that simply prints a
> > > register dump and stack backtrace. So again how do you access the original
> > > register contents?
> > 
> > You need to do that yourself.
> 
> Which means __attribute__ ((interrupt)) can't be used for exceptions half
> the time.

That is true if the interrupt handler must be written in such way.

> > > Secondly why pass error_code as argument if is already on the stack and
> > > could be accessed through the frame pointer? The argument register (amd64)
> > > would have to be saved on the stack too causing an extra push/pop. But if it
> > > is passed as argument then why not pop it before the call to keep the stack
> > > frame the same as for interrupts (assuming the saved registers are not
> > > included in the frame)?
> > 
> > error_code is a pseudo parameter, which is mapped to error code on stack
> > pushed by CPU.  You can write a simple code to see it yourself.
> 
> Couldn't the same trick be used for registers? Pass them as pseudo
> parameters and they either resolve to the location on the stack where gcc
> did save them or become the original register unchanged.

No.  We only do it for data pushed onto stack by CPU.

> > > If it is not poped or saved registers are included in the frame then the
> > > exception stack frame differs from the interrupt frame (extra error_code and
> > > extra register). They should not use the same structure, that's just
> > > confusing.
> > > 
> > >     'no_caller_saved_registers' attribute
> > > 
> > >     Use this attribute to indicate that the specified function has no
> > >     caller-saved registers.  That is, all registers are callee-saved.
> > > 
> > > Does that include the argument registers (if the function takes arguments)?
> > 
> > Yes.
> > 
> > > Wouldn't it be more flexible to define a list of registers that the function
> > > will clobber?
> > 
> > How do programmer know which registers will be clobbered?
> 
> The programmer writes the function. He declares what registers will be
> clobbered and gcc will add the necessary code to preserve any other
> registers it uses inside the function.

When you write in C, you don't deal with registers directly, which are
taken care of by compiler.  If you want to control exactly how registers
are handled, you need to write in ASM.
>From gcc-bugs-return-529659-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 16:29:36 2016
Return-Path: <gcc-bugs-return-529659-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 27747 invoked by alias); 4 Jul 2016 16:29:35 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 27007 invoked by uid 55); 4 Jul 2016 16:29:23 -0000
From: "ysrumyan at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/70729] Loop marked with omp simd pragma is not vectorized
Date: Mon, 04 Jul 2016 16:29:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: openmp
X-Bugzilla-Severity: normal
X-Bugzilla-Who: ysrumyan at gmail dot com
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-70729-4-yTZoBPfFgl@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
References: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00242.txt.bz2
Content-length: 1840

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70729

--- Comment #34 from Yuri Rumyantsev <ysrumyan at gmail dot com> ---
Thanks a lot Jakub for your detail comments.
I have simple fix which cures failures from 71734. The fix is simple
enough and simply check that the ref in problem belongs to simd loop:

diff --git a/gcc/tree-ssa-loop-im.c b/gcc/tree-ssa-loop-im.c
index ee04826..c710bbe 100644
--- a/gcc/tree-ssa-loop-im.c
+++ b/gcc/tree-ssa-loop-im.c
@@ -2128,7 +2128,7 @@ ref_indep_loop_p_1 (struct loop *loop, im_mem_ref *ref,
   if (bitmap_bit_p (refs_to_check, UNANALYZABLE_MEM_ID))
     return false;

-  if (loop->safelen > 0)
+  if (loop->safelen > 1 && bitmap_bit_p (refs_to_check, ref->id))
     {
       if (dump_file && (dump_flags & TDF_DETAILS))
        {

and I checked that simd3.f90 and simd4.f90 from libgomp.fortran passed with it.


2016-07-04 18:30 GMT+03:00 jakub at gcc dot gnu.org <gcc-bugzilla@gcc.gnu.org>:
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70729
>
> --- Comment #33 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
> In any case, loop->safelen > 0 test looks also wrong, if there are guarantees
> about single iteration only (safelen(1)), then there is nothing useful at all.
> So it must be loop->safelen >= 2.
>
> For foo in #c29, the q[0] load in foo can be hoisted before the loop.
> More complicated is e.g.:
> void baz (int *p, int *q, int *r, int *s)
> {
>   #pragma omp simd
>   for (int i = 0; i < 1024; i++)
>     {
>       p[i] += q[0] * 6;
>       r[i] += s[0] * 9;
>     }
> }
> Here IMNSHO only q[0] * 6 can be hoisted before the loop, while it can alias
> p[1023] (or for x < 1023 p[x] if p[x] is initially 0), p[1023] could validly
> alias s[0] and thus s[0] * 9 must not be hoisted.
>
> --
> You are receiving this mail because:
> You reported the bug.
>From gcc-bugs-return-529658-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 16:29:25 2016
Return-Path: <gcc-bugs-return-529658-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 27053 invoked by alias); 4 Jul 2016 16:29:25 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 26714 invoked by uid 48); 4 Jul 2016 16:29:12 -0000
From: "timo.teras at iki dot fi" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libgcj/71757] New: libgcj: unknown symbol __cxa_throw_bad_array_new_length
Date: Mon, 04 Jul 2016 16:29:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: libgcj
X-Bugzilla-Version: 6.1.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: timo.teras at iki dot fi
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone
Message-ID: <bug-71757-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00241.txt.bz2
Content-length: 1290

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71757

            Bug ID: 71757
           Summary: libgcj: unknown symbol
                    __cxa_throw_bad_array_new_length
           Product: gcc
           Version: 6.1.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libgcj
          Assignee: unassigned at gcc dot gnu.org
          Reporter: timo.teras at iki dot fi
  Target Milestone: ---

The root of the problem is that libjava (libgcj) is built with raw_cxx=true.
Basically the C++ library is built and linked with xgcc (not xg++).

Earlier this was not a problem as it uses limited set of c++ things.

However, gcc 6.1.0 changed the default to -std=gnu++14. This changed certain
allocation methods to raise exceptions by default. Internally the compiler uses
__cxa_throw_bad_array_new_length from libstdc++ to do this. Thus changing the
language default added a new dependency against this symbol. This together with
not using xg++ makes the link stage not pick up libstdc++ as dependency.

The result is:
libgcj.so: undefined reference to `__cxa_throw_bad_array_new_length'

As a quick workaround the adding back -std=gnu++98 to libjava/configure.host's
libgcj_cxxflags made things build again for me.
>From gcc-bugs-return-529660-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 16:40:20 2016
Return-Path: <gcc-bugs-return-529660-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 53131 invoked by alias); 4 Jul 2016 16:40:19 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 52997 invoked by uid 48); 4 Jul 2016 16:40:07 -0000
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/70729] Loop marked with omp simd pragma is not vectorized
Date: Mon, 04 Jul 2016 16:40:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: openmp
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jakub at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-70729-4-p3gXYe4dju@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
References: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00243.txt.bz2
Content-length: 477

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70729

--- Comment #35 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Doesn't it still miscompile the #c33 testcase?
Say with __attribute__((noinline, noclone)) on baz and
int v[2048];

int
main ()
{
  v[1023] = 5;
  baz (v, v + 1023, v + 1024, v + 1023);
  int i;
  for (i = 0; i < 1024; i++)
    if (v[i] != 5 * 6 || v[1024 + i] != (i == 1023 ? 5 * 6 : 5) * 9)
      __builtin_abort ();
  return 0;
}
(untested)?
>From gcc-bugs-return-529661-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 16:48:30 2016
Return-Path: <gcc-bugs-return-529661-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 78478 invoked by alias); 4 Jul 2016 16:48:29 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 78278 invoked by uid 55); 4 Jul 2016 16:48:15 -0000
From: "ysrumyan at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/70729] Loop marked with omp simd pragma is not vectorized
Date: Mon, 04 Jul 2016 16:48:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: openmp
X-Bugzilla-Severity: normal
X-Bugzilla-Who: ysrumyan at gmail dot com
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-70729-4-SJfTGKQ69e@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
References: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00244.txt.bz2
Content-length: 1090

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70729

--- Comment #36 from Yuri Rumyantsev <ysrumyan at gmail dot com> ---
#c33 testcase was not tested since I have some doubts about it. Note
that original problem was
#pragma omp simd
  for (int i=0; i<S_n; i++)
    {
      float w1 = C2[S_n + i] * w;
      v1.v_i[i] += (int)w1;
      C1[S_n + i] += w1;
    }

and we must hoist S_n out of loop to vectorize it.

2016-07-04 19:40 GMT+03:00 jakub at gcc dot gnu.org <gcc-bugzilla@gcc.gnu.org>:
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70729
>
> --- Comment #35 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
> Doesn't it still miscompile the #c33 testcase?
> Say with __attribute__((noinline, noclone)) on baz and
> int v[2048];
>
> int
> main ()
> {
>   v[1023] = 5;
>   baz (v, v + 1023, v + 1024, v + 1023);
>   int i;
>   for (i = 0; i < 1024; i++)
>     if (v[i] != 5 * 6 || v[1024 + i] != (i == 1023 ? 5 * 6 : 5) * 9)
>       __builtin_abort ();
>   return 0;
> }
> (untested)?
>
> --
> You are receiving this mail because:
> You reported the bug.
>From gcc-bugs-return-529662-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 16:51:34 2016
Return-Path: <gcc-bugs-return-529662-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 85991 invoked by alias); 4 Jul 2016 16:51:34 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 82406 invoked by uid 48); 4 Jul 2016 16:51:21 -0000
From: "pinskia at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libgcj/71757] libgcj: unknown symbol __cxa_throw_bad_array_new_length
Date: Mon, 04 Jul 2016 16:51:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: libgcj
X-Bugzilla-Version: 6.1.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: pinskia at gcc dot gnu.org
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71757-4-jE9xRZoHk5@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71757-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71757-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00245.txt.bz2
Content-length: 220

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71757

--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
What target is this on?  I get all passes in the java testsuite with GCC 6.1 on
aarch-linux-gnu.
>From gcc-bugs-return-529663-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 16:55:16 2016
Return-Path: <gcc-bugs-return-529663-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 5766 invoked by alias); 4 Jul 2016 16:55:15 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 5528 invoked by uid 48); 4 Jul 2016 16:55:02 -0000
From: "timo.teras at iki dot fi" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libgcj/71757] libgcj: unknown symbol __cxa_throw_bad_array_new_length
Date: Mon, 04 Jul 2016 16:55:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: libgcj
X-Bugzilla-Version: 6.1.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: timo.teras at iki dot fi
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71757-4-Yqrv0507Gx@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71757-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71757-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00246.txt.bz2
Content-length: 337

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71757

--- Comment #2 from Timo Teräs <timo.teras at iki dot fi> ---
(In reply to Andrew Pinski from comment #1)
> What target is this on?  I get all passes in the java testsuite with GCC 6.1
> on aarch-linux-gnu.

Happens on x86_64-alpine-linux-musl for me. PIE enabled by default.
>From gcc-bugs-return-529664-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 16:57:18 2016
Return-Path: <gcc-bugs-return-529664-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 7746 invoked by alias); 4 Jul 2016 16:57:17 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 7509 invoked by uid 48); 4 Jul 2016 16:57:05 -0000
From: "timo.teras at iki dot fi" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libgcj/71757] libgcj: unknown symbol __cxa_throw_bad_array_new_length
Date: Mon, 04 Jul 2016 16:57:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: libgcj
X-Bugzilla-Version: 6.1.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: timo.teras at iki dot fi
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71757-4-HNUMatWRk4@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71757-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71757-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00247.txt.bz2
Content-length: 560

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71757

--- Comment #3 from Timo Teräs <timo.teras at iki dot fi> ---
(In reply to Timo Teräs from comment #2)
> (In reply to Andrew Pinski from comment #1)
> > What target is this on?  I get all passes in the java testsuite with GCC 6.1
> > on aarch-linux-gnu.
> 
> Happens on x86_64-alpine-linux-musl for me. PIE enabled by default.

Also it happens only during bootstrap. If you have --disable-bootstrap it won't
probably happen. It's related to the fact xgcc is used as CXX during bootstrap.
>From gcc-bugs-return-529665-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 16:59:01 2016
Return-Path: <gcc-bugs-return-529665-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 9517 invoked by alias); 4 Jul 2016 16:59:01 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 9448 invoked by uid 55); 4 Jul 2016 16:58:56 -0000
From: "ysrumyan at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/70729] Loop marked with omp simd pragma is not vectorized
Date: Mon, 04 Jul 2016 16:59:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: openmp
X-Bugzilla-Severity: normal
X-Bugzilla-Who: ysrumyan at gmail dot com
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-70729-4-cSRVCdYZHQ@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
References: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00248.txt.bz2
Content-length: 1496

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70729

--- Comment #37 from Yuri Rumyantsev <ysrumyan at gmail dot com> ---
Jakub,

I assume that yoour #C33 test-case is not correct, i.e. it can not be
marked with pragma omp simd. For example, even if we turn off lim
phase it will be aborted:
my_g++ -O3  -m64 t33.cpp -o t33.exe.1 -fopenmp -fno-tree-loop-im
/users/ysrumyan/70729$ ./t33.exe.1
Aborted (core dumped)


2016-07-04 19:47 GMT+03:00 Yuri Rumyantsev <ysrumyan@gmail.com>:
> #c33 testcase was not tested since I have some doubts about it. Note
> that original problem was
> #pragma omp simd
>   for (int i=0; i<S_n; i++)
>     {
>       float w1 = C2[S_n + i] * w;
>       v1.v_i[i] += (int)w1;
>       C1[S_n + i] += w1;
>     }
>
> and we must hoist S_n out of loop to vectorize it.
>
> 2016-07-04 19:40 GMT+03:00 jakub at gcc dot gnu.org <gcc-bugzilla@gcc.gnu.org>:
>> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70729
>>
>> --- Comment #35 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
>> Doesn't it still miscompile the #c33 testcase?
>> Say with __attribute__((noinline, noclone)) on baz and
>> int v[2048];
>>
>> int
>> main ()
>> {
>>   v[1023] = 5;
>>   baz (v, v + 1023, v + 1024, v + 1023);
>>   int i;
>>   for (i = 0; i < 1024; i++)
>>     if (v[i] != 5 * 6 || v[1024 + i] != (i == 1023 ? 5 * 6 : 5) * 9)
>>       __builtin_abort ();
>>   return 0;
>> }
>> (untested)?
>>
>> --
>> You are receiving this mail because:
>> You reported the bug.
>From gcc-bugs-return-529666-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:01:16 2016
Return-Path: <gcc-bugs-return-529666-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 11466 invoked by alias); 4 Jul 2016 17:01:16 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 11218 invoked by uid 48); 4 Jul 2016 17:01:03 -0000
From: "pinskia at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libgcj/71757] libgcj: unknown symbol __cxa_throw_bad_array_new_length
Date: Mon, 04 Jul 2016 17:01:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: libgcj
X-Bugzilla-Version: 6.1.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: pinskia at gcc dot gnu.org
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71757-4-2gbfAnV2LR@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71757-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71757-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00249.txt.bz2
Content-length: 769

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71757

--- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
(In reply to Timo Teräs from comment #3)
> (In reply to Timo Teräs from comment #2)
> > (In reply to Andrew Pinski from comment #1)
> > > What target is this on?  I get all passes in the java testsuite with GCC 6.1
> > > on aarch-linux-gnu.
> > 
> > Happens on x86_64-alpine-linux-musl for me. PIE enabled by default.
> 
> Also it happens only during bootstrap. If you have --disable-bootstrap it
> won't probably happen. It's related to the fact xgcc is used as CXX during
> bootstrap.

Actually xgcc/xg++ will be used to compile the target libraries even with
--disable-bootstrap.  And you are the first one to report this issue.
>From gcc-bugs-return-529667-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:08:49 2016
Return-Path: <gcc-bugs-return-529667-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 19676 invoked by alias); 4 Jul 2016 17:08:48 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 19463 invoked by uid 48); 4 Jul 2016 17:08:37 -0000
From: "pinskia at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libgcj/71757] libgcj: unknown symbol __cxa_throw_bad_array_new_length
Date: Mon, 04 Jul 2016 17:08:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: libgcj
X-Bugzilla-Version: 6.1.0
X-Bugzilla-Keywords: build
X-Bugzilla-Severity: normal
X-Bugzilla-Who: pinskia at gcc dot gnu.org
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: keywords
Message-ID: <bug-71757-4-TwTOXQ3X91@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71757-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71757-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00250.txt.bz2
Content-length: 678

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71757

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |build

--- Comment #5 from Andrew Pinski <pinskia at gcc dot gnu.org> ---

  LIBSTDCXX_RAW_CXX_CXXFLAGS="\
    -I\$(top_builddir)/../libstdc++-v3/include \
    -I\$(top_builddir)/../libstdc++-v3/include/\$(target_noncanonical) \
    -I\$(top_srcdir)/../libstdc++-v3/libsupc++"
  LIBSTDCXX_RAW_CXX_LDFLAGS="\
    \$(top_builddir)/../libstdc++-v3/src/libstdc++.la"


That should be used.
>From gcc-bugs-return-529668-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:09:44 2016
Return-Path: <gcc-bugs-return-529668-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 22504 invoked by alias); 4 Jul 2016 17:09:44 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 22281 invoked by uid 48); 4 Jul 2016 17:09:32 -0000
From: "pinskia at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libgcj/71757] libgcj: unknown symbol __cxa_throw_bad_array_new_length
Date: Mon, 04 Jul 2016 17:09:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: libgcj
X-Bugzilla-Version: 6.1.0
X-Bugzilla-Keywords: build
X-Bugzilla-Severity: normal
X-Bugzilla-Who: pinskia at gcc dot gnu.org
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71757-4-tncg0LbVXv@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71757-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71757-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00251.txt.bz2
Content-length: 204

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71757

--- Comment #6 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Are you sure __cxa_throw_bad_array_new_length  is being exported from
libstdc++v3?
>From gcc-bugs-return-529669-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:10:48 2016
Return-Path: <gcc-bugs-return-529669-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 23582 invoked by alias); 4 Jul 2016 17:10:47 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 23473 invoked by uid 48); 4 Jul 2016 17:10:32 -0000
From: "msebor at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug middle-end/49905] Better sanity checking on sprintf src & dest to produce warning for dodgy code ?
Date: Mon, 04 Jul 2016 17:10:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: middle-end
X-Bugzilla-Version: 4.7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: enhancement
X-Bugzilla-Who: msebor at gcc dot gnu.org
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: msebor at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-49905-4-OIm0juGPy6@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-49905-4@http.gcc.gnu.org/bugzilla/>
References: <bug-49905-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00252.txt.bz2
Content-length: 3264

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=49905

--- Comment #13 from Martin Sebor <msebor at gcc dot gnu.org> ---
(In reply to David Binderman from comment #9)
> I tried a build of the gcc fortran compiler and I found this warning:
> 
> ../../../src/trunk/libgfortran/intrinsics/date_and_time.c:173:33: warning:
> ‘%+03d’ directive output truncated while writing ‘9’ bytes into a region of
> size ‘6’ [-Wformat-length=]
> 
> Source code is
> 
>     snprintf (zone, ZONE_LEN + 1, "%+03d%02d",
>           values[3] / 60, abs (values[3] % 60));
> 
> and
> 
> #define ZONE_LEN 5
> 
>   char zone[ZONE_LEN + 1];
> 
> While it is clear that the region size of 6 is fine, I can't see where the
> value 
> of 9 bytes is coming from.

Thanks for the testing!  I reproduced the warning the above with -O2 in a small
test case:

  extern int values [4];
  inline int abs(int x) { return x < 0 ? -x : x; }

  #define ZONE_LEN 5

  char zone[ZONE_LEN + 1];

  void f (void)
  {
    __builtin_snprintf (zone, ZONE_LEN + 1, "%+03d%02d",
                        values[3] / 60, abs (values[3] % 60));
  }

GCC doesn't know what values[3] evaluates to but since its type is int, the
Value Range Propagation (VRP) determines that the range of (values[3] / 60) is
[-35791394, 35791394], and the checker sees that as many as 9 bytes of space
for the output of any value in that range are required.

The checker prints two general kinds of diagnostics for individual directives:

1) When it knows the space in the destination is insufficient to format either
an exact value or a range of values bounded by some limit imposed by the
program is uses the words "writing" or "truncating."

2) When it doesn't know the exact value and there is no known range of values
beyond the limits of the type of the argument it uses the term "may write" or
"may truncate."

The case above falls into (1) but it could be changed to fall into (2) instead,
or to use a different phrase.  In either case, the diagnostic could also
mention the range of values it thinks the argument can take on.

(In reply to David Binderman from comment #9)
> I'd be happy for the code to compute minimum only and have maximum
> postponed for the future. One step at a time.

The checker has two levels:

1) At level one, it considers the least amount of space needed for the argument
of each directive (is assumes unknown integers have the value 1 and strings are
empty).  This corresponds to the minimum.  I would expect this to be
immediately useful in all existing code since it should have no (or few) false
positives.

2) At level two, it uses the maximum.  Unknown singed integers or type T have
the value T_MIN, unknown integers of unsigned type T_MAX.  That corresponds to
the maximum.  I envision this to be useful mainly in new code and for sanity
checking in existing code.

At both levels, the checker treats known values as exact (because it knows
exactly how many bytes of output each produces).  For ranges of values obtained
from VRP it uses the upper bound of the range.  Due to weaknesses in the range
information exposed by VRP we might want to tweak it this strategy or clarify
the diagnostic.
>From gcc-bugs-return-529670-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:11:38 2016
Return-Path: <gcc-bugs-return-529670-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 24826 invoked by alias); 4 Jul 2016 17:11:37 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 24566 invoked by uid 48); 4 Jul 2016 17:11:24 -0000
From: "timo.teras at iki dot fi" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libgcj/71757] libgcj: unknown symbol __cxa_throw_bad_array_new_length
Date: Mon, 04 Jul 2016 17:11:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: libgcj
X-Bugzilla-Version: 6.1.0
X-Bugzilla-Keywords: build
X-Bugzilla-Severity: normal
X-Bugzilla-Who: timo.teras at iki dot fi
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71757-4-ki7k2ZyIQd@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71757-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71757-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00253.txt.bz2
Content-length: 506

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71757

--- Comment #7 from Timo Teräs <timo.teras at iki dot fi> ---
(In reply to Andrew Pinski from comment #6)
> Are you sure __cxa_throw_bad_array_new_length  is being exported from
> libstdc++v3?

$ nm -D
./stage1-x86_64-alpine-linux-musl/libstdc++-v3/src/.libs/libstdc++.so|gr
ep __cxa_throw_bad_array_new_length
000000000009f841 T __cxa_throw_bad_array_new_length

It might be versioned by default. I'm using --disable-symvers in my build,
though.
>From gcc-bugs-return-529671-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:13:51 2016
Return-Path: <gcc-bugs-return-529671-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 33767 invoked by alias); 4 Jul 2016 17:13:51 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 33673 invoked by uid 48); 4 Jul 2016 17:13:38 -0000
From: "pinskia at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/71227] [6/7 Regression] template friend function cannot be resolved
Date: Mon, 04 Jul 2016 17:13:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 6.1.1
X-Bugzilla-Keywords: rejects-valid
X-Bugzilla-Severity: normal
X-Bugzilla-Who: pinskia at gcc dot gnu.org
X-Bugzilla-Status: RESOLVED
X-Bugzilla-Resolution: FIXED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: jason at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 6.2
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_status resolution
Message-ID: <bug-71227-4-pcC6RuP7R1@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71227-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71227-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00254.txt.bz2
Content-length: 427

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71227

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|---                         |FIXED

--- Comment #5 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Fixed.
>From gcc-bugs-return-529672-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:16:43 2016
Return-Path: <gcc-bugs-return-529672-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 37209 invoked by alias); 4 Jul 2016 17:16:42 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 37084 invoked by uid 48); 4 Jul 2016 17:16:30 -0000
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug middle-end/49905] Better sanity checking on sprintf src & dest to produce warning for dodgy code ?
Date: Mon, 04 Jul 2016 17:16:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: middle-end
X-Bugzilla-Version: 4.7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: enhancement
X-Bugzilla-Who: jakub at gcc dot gnu.org
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: msebor at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-49905-4-zXblC4GPab@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-49905-4@http.gcc.gnu.org/bugzilla/>
References: <bug-49905-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00255.txt.bz2
Content-length: 1783

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=49905

--- Comment #14 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
(In reply to Martin Sebor from comment #13)
> (In reply to David Binderman from comment #9)
> > I tried a build of the gcc fortran compiler and I found this warning:
> > 
> > ../../../src/trunk/libgfortran/intrinsics/date_and_time.c:173:33: warning:
> > ‘%+03d’ directive output truncated while writing ‘9’ bytes into a region of
> > size ‘6’ [-Wformat-length=]
> > 
> > Source code is
> > 
> >     snprintf (zone, ZONE_LEN + 1, "%+03d%02d",
> >           values[3] / 60, abs (values[3] % 60));
> > 
> > and
> > 
> > #define ZONE_LEN 5
> > 
> >   char zone[ZONE_LEN + 1];
> > 
> > While it is clear that the region size of 6 is fine, I can't see where the
> > value 
> > of 9 bytes is coming from.
> 
> Thanks for the testing!  I reproduced the warning the above with -O2 in a
> small test case:
> 
>   extern int values [4];
>   inline int abs(int x) { return x < 0 ? -x : x; }
> 
>   #define ZONE_LEN 5
> 
>   char zone[ZONE_LEN + 1];
> 
>   void f (void)
>   {
>     __builtin_snprintf (zone, ZONE_LEN + 1, "%+03d%02d",
>                         values[3] / 60, abs (values[3] % 60));
>   }
> 
> GCC doesn't know what values[3] evaluates to but since its type is int, the
> Value Range Propagation (VRP) determines that the range of (values[3] / 60)
> is [-35791394, 35791394], and the checker sees that as many as 9 bytes of
> space for the output of any value in that range are required.

But 9 is maximum length just for the %+03d part, %02d with the limited VRP
range is exactly 2 and then the '\0', so that is 12 maximum, 6 minimum.
So printing 9 is just misleading.
>From gcc-bugs-return-529673-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:17:43 2016
Return-Path: <gcc-bugs-return-529673-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 38270 invoked by alias); 4 Jul 2016 17:17:43 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 38161 invoked by uid 48); 4 Jul 2016 17:17:31 -0000
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/70729] Loop marked with omp simd pragma is not vectorized
Date: Mon, 04 Jul 2016 17:17:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: openmp
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jakub at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-70729-4-ZelgtEQvT6@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
References: <bug-70729-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00256.txt.bz2
Content-length: 717

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70729

--- Comment #38 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Sorry, make that
__attribute__((noinline, noclone)) void
baz (int *p, int *q, int *r, int *s)
{
#pragma omp simd
  for (int i = 0; i < 1024; i++)
    {
      p[i] += q[0] * 6;
      r[i] += s[0] * 9;
    }
}

int v[2048];

int
main ()
{
  v[1023] = 5;
  baz (v, v + 1023, v + 1024, v + 1023);
  int i;
  for (i = 0; i < 1023; i++)
    if (v[i] != 5 * 6 || v[1024 + i] != 5 * 9)
      __builtin_abort ();
  if (v[i] != 5 * 6 + 5 || v[2047] != (5 * 6 + 5) * 9)
    __builtin_abort ();
  return 0;
}

This passes without -fopenmp/-fopenmp-simd.  Anyway, I've raised it on
omp-lang.
>From gcc-bugs-return-529674-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:19:02 2016
Return-Path: <gcc-bugs-return-529674-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 56132 invoked by alias); 4 Jul 2016 17:19:02 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 56058 invoked by uid 48); 4 Jul 2016 17:18:49 -0000
From: "gerhard.steinmetz.fortran@t-online.de" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/66244] [4.9/5/6/7 Regression] ICE on assigning a value to a pointer variable
Date: Mon, 04 Jul 2016 17:19:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 5.1.1
X-Bugzilla-Keywords: ice-on-invalid-code
X-Bugzilla-Severity: normal
X-Bugzilla-Who: gerhard.steinmetz.fortran@t-online.de
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P4
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 4.9.4
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-66244-4-5wwoNmsC4M@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-66244-4@http.gcc.gnu.org/bugzilla/>
References: <bug-66244-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00257.txt.bz2
Content-length: 2592

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66244

--- Comment #4 from Gerhard Steinmetz <gerhard.steinmetz.fortran@t-online.de> ---
Compiling slightly modified example from comment 0 :


$ cat z4.f90
program p
   integer, target :: a(3)[*]
   integer, pointer :: z => a(3)
   z = 0
   print *, z
end


$ gfortran-7-20160703 -fcoarray=single z4.f90
f951: internal compiler error: in get, at cgraph.h:395
0xefcbd7 symtab_node::get(tree_node const*)
        ../../gcc/cgraph.h:392
0xefcbd7 varpool_node::get(tree_node const*)
        ../../gcc/cgraph.h:2480
0xefcbd7 varpool_node::get_create(tree_node*)
        ../../gcc/varpool.c:144
0x830ca7 record_reference
        ../../gcc/cgraphbuild.c:82
0xebe152 walk_tree_1(tree_node**, tree_node* (*)(tree_node**, int*, void*),
void*, hash_set<tree_node*, default_hash_traits<tree_node*> >*, tree_node*
(*)(tree_node**, int*, tree_node* (*)(tree_node**, int*, void*), void*,
hash_set<tree_node*, default_hash
        ../../gcc/tree.c:11655
0x831f34 record_references_in_initializer(tree_node*, bool)
        ../../gcc/cgraphbuild.c:404
0xefdbe7 varpool_node::analyze()
        ../../gcc/varpool.c:533
0x8381aa analyze_functions
        ../../gcc/cgraphunit.c:1133
0x839128 symbol_table::finalize_compilation_unit()
        ../../gcc/cgraphunit.c:2543



$ gfortran-7-20160703 -fcoarray=lib z4.f90
z4.f90:6:0:

 end

internal compiler error: output_operand: invalid expression as operand
0x917a83 output_operand_lossage(char const*, ...)
        ../../gcc/final.c:3413
0x918365 output_addr_const(_IO_FILE*, rtx_def*)
        ../../gcc/final.c:4002
0x918305 output_addr_const(_IO_FILE*, rtx_def*)
        ../../gcc/final.c:3962
0xee864e assemble_integer_with_op(char const*, rtx_def*)
        ../../gcc/varasm.c:2679
0xee86ad default_assemble_integer(rtx_def*, unsigned int, int)
        ../../gcc/varasm.c:2695
0xee871e assemble_integer(rtx_def*, unsigned int, unsigned int, int)
        ../../gcc/varasm.c:2711
0xeee59a output_constant
        ../../gcc/varasm.c:4760
0xef0e64 output_constant
        ../../gcc/varasm.c:4664
0xef0e64 assemble_variable_contents
        ../../gcc/varasm.c:2073
0xef8619 assemble_variable(tree_node*, int, int, int)
        ../../gcc/varasm.c:2249
0xefde08 varpool_node::assemble_decl()
        ../../gcc/varpool.c:589
0x8363c3 output_in_order
        ../../gcc/cgraphunit.c:2232
0x83674d symbol_table::compile()
        ../../gcc/cgraphunit.c:2469
0x8391a2 symbol_table::compile()
        ../../gcc/cgraphunit.c:2539
0x8391a2 symbol_table::finalize_compilation_unit()
        ../../gcc/cgraphunit.c:2565
>From gcc-bugs-return-529675-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:24:02 2016
Return-Path: <gcc-bugs-return-529675-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 59614 invoked by alias); 4 Jul 2016 17:24:02 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 59521 invoked by uid 48); 4 Jul 2016 17:23:57 -0000
From: "pinskia at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/71069] -Waddress didn't catch all cases
Date: Mon, 04 Jul 2016 17:24:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 6.1.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: pinskia at gcc dot gnu.org
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71069-4-POke2m1aN2@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71069-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71069-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00258.txt.bz2
Content-length: 222

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71069

--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
-fsantize=undefined will catch this at runtime.  What is undefined is passing a
NULL to setData.
>From gcc-bugs-return-529676-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:24:36 2016
Return-Path: <gcc-bugs-return-529676-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 60536 invoked by alias); 4 Jul 2016 17:24:36 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 60398 invoked by uid 48); 4 Jul 2016 17:24:23 -0000
From: "msebor at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug middle-end/49905] Better sanity checking on sprintf src & dest to produce warning for dodgy code ?
Date: Mon, 04 Jul 2016 17:24:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: middle-end
X-Bugzilla-Version: 4.7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: enhancement
X-Bugzilla-Who: msebor at gcc dot gnu.org
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: msebor at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-49905-4-4omLzKFqXw@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-49905-4@http.gcc.gnu.org/bugzilla/>
References: <bug-49905-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00259.txt.bz2
Content-length: 1013

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=49905

--- Comment #15 from Martin Sebor <msebor at gcc dot gnu.org> ---
(In reply to David Binderman from comment #11)
> BTW, I tried a Linux kernel build and got this
> 
> drivers/char/ipmi/ipmi_msghandler.c: In function ‘guid_show’:
> drivers/char/ipmi/ipmi_msghandler.c:2365:9: internal compiler error: in
> format_integer, at c-family/c-format.c:506
>   return snprintf(buf, 100, "%Lx%Lx\n",
>          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>     (long long) bmc->guid[0],
>     ~~~~~~~~~~~~~~~~~~~~~~~~~
>     (long long) bmc->guid[8]);
>     ~~~~~~~~~~~~~~~~~~~~~~~~~
> 
> So it looks to me like format %Lx isn't handled.
...
> Also, %lf seems to cause a crash.

Not all directives or length modifiers are recognized yet but they should be
handled gracefully, not by aborting.  (In most cases the checker gives up on
the rest of the format strings).  Thanks for pointing out these cases, I'll
update the code in the next revision of the patch.
>From gcc-bugs-return-529678-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:26:32 2016
Return-Path: <gcc-bugs-return-529678-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 63111 invoked by alias); 4 Jul 2016 17:26:32 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 62982 invoked by uid 48); 4 Jul 2016 17:26:19 -0000
From: "gerhard.steinmetz.fortran@t-online.de" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/67883] ICE on empty array constructor of character function
Date: Mon, 04 Jul 2016 17:26:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 5.2.1
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: gerhard.steinmetz.fortran@t-online.de
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-67883-4-Lh5pQsYh7t@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-67883-4@http.gcc.gnu.org/bugzilla/>
References: <bug-67883-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00261.txt.bz2
Content-length: 2465

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67883

--- Comment #2 from Gerhard Steinmetz <gerhard.steinmetz.fortran@t-online.de> ---

Another group of examples.
First case is working in a sufficient manner.
Concatenating two empty hulls (zero len and size, respectivly)
gives an empty hull as result again.


$ cat zz1.f90
program p
   character(*), parameter :: c1(*) = [character(*) :: 'a'] // [character(*) ::
'z']
   character(*), parameter :: c2(*) = [character(0) ::] // [character(0) ::]
   character(*), parameter :: c3(*) = [character(0) ::] // [character(*) ::]
   character(*), parameter :: c4(*) = [character(0) ::]
   print *, 'c1: ', len(c1), size(c1), c1
   print *, 'c2: ', len(c2), size(c2), c2
   print *, 'c3: ', len(c3), size(c3), c3
   print *, 'c4: ', len(c4), size(c4), c4
end


$ gfortran-6 -g -O0 -Wall -fcheck=all zz1.f90
$ a.out
 c1:            2           1 az
 c2:            0           0
 c3:            0           0
 c4:            0           0

---


Next case is questionable : no error, unexpected results.


$ cat zz2.f90
program p
   character(*), parameter :: c5(*) = [character(*) :: 'a'] // [character(0)
::]
   character(*), parameter :: c6(*) = [character(0) ::] // [character(*) ::
'z']
   print *, 'c5: ', len(c5), size(c5), c5
   print *, 'c6: ', len(c6), size(c6), c6
end


$ gfortran-6 -g -O0 -Wall -fcheck=all zz2.f90
$ a.out
 c5:            0           0
 c6:            0           0



Errors detected with alternative code :

$ cat zz3.f90
program p
   character(*), parameter :: b1(*) = [character(*) :: 'a']
   character(*), parameter :: b2(*) = [character(0) ::]
   character(*), parameter :: b3(*) = b1 // b2
!  character(*), parameter :: b4(*) = b2 // b1
   print *, 'b1: ', len(b1), size(b1), b2
   print *, 'b2: ', len(b2), size(b2), b2
   print *, 'b3: ', len(b3), size(b3), b3
!  print *, 'b4: ', len(b4), size(b4), b4
end


$ gfortran-6 -g -O0 -Wall -fcheck=all zz3.f90
zz3.f90:4:37-43:

    character(*), parameter :: b3(*) = b1 // b2
                                     1     2
Error: Shapes for operands at (1) and (2) are not conformable
zz3.f90:8:24:

    print *, 'b3: ', len(b3), size(b3), b3
                        1
Error: 'string' argument of 'len' intrinsic at (1) must be CHARACTER
zz3.f90:8:34:

    print *, 'b3: ', len(b3), size(b3), b3
                                  1
Error: 'array' argument of 'size' intrinsic at (1) must be an array
>From gcc-bugs-return-529677-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:26:03 2016
Return-Path: <gcc-bugs-return-529677-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 62251 invoked by alias); 4 Jul 2016 17:26:03 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 62117 invoked by uid 48); 4 Jul 2016 17:25:50 -0000
From: "pinskia at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug debug/71058] ICE when building heavy templating and -std=c++17 -gstabs
Date: Mon, 04 Jul 2016 17:26:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: debug
X-Bugzilla-Version: 5.3.0
X-Bugzilla-Keywords: ice-on-valid-code
X-Bugzilla-Severity: normal
X-Bugzilla-Who: pinskia at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71058-4-chIAWLsR6P@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71058-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71058-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00260.txt.bz2
Content-length: 229

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71058

--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Why would someone even try to use stabs debugging info.  It provides almost no
debug information anyways.
>From gcc-bugs-return-529679-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:28:08 2016
Return-Path: <gcc-bugs-return-529679-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 65018 invoked by alias); 4 Jul 2016 17:28:08 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 64277 invoked by uid 48); 4 Jul 2016 17:27:55 -0000
From: "gerhard.steinmetz.fortran@t-online.de" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/67883] ICE on empty array constructor of character function
Date: Mon, 04 Jul 2016 17:28:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 5.2.1
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: gerhard.steinmetz.fortran@t-online.de
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-67883-4-pVj0kcEecL@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-67883-4@http.gcc.gnu.org/bugzilla/>
References: <bug-67883-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00262.txt.bz2
Content-length: 2411

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67883

--- Comment #3 from Gerhard Steinmetz <gerhard.steinmetz.fortran@t-online.de> ---

For the following cases, every line produces an ICE :


$ cat zz5.f90
program p
   character(*), parameter :: x1(*) = [character(*) ::] // [character(0) ::]
   character(*), parameter :: x2(*) = [character(*) ::] // [character(*) ::]
   character(*), parameter :: x3(*) = [character(*) ::]
   character(*), parameter :: x4(0) = [character(*) ::]
   character(1), parameter :: x5(*) = [character(*) ::]
   character(1), parameter :: x6(0) = [character(*) ::]
   character(0), parameter :: x7(0) = [character(*) ::]
   character(0), parameter :: x8(1) = [character(*) ::]
   character(1), parameter :: x9(1) = [character(*) ::]
end


$ gfortran-7-20160703 zz5.f90
f951: internal compiler error: in gfc_resolve_character_array_constructor, at
fortran/array.c:2020
0x65b719 gfc_resolve_character_array_constructor(gfc_expr*)
        ../../gcc/fortran/array.c:2020
0x6e16d6 gfc_resolve_expr(gfc_expr*)
        ../../gcc/fortran/resolve.c:6402
0x6875bf gfc_reduce_init_expr(gfc_expr*)
        ../../gcc/fortran/expr.c:2668
0x688549 gfc_match_init_expr(gfc_expr**)
        ../../gcc/fortran/expr.c:2709
0x679d53 variable_decl
        ../../gcc/fortran/decl.c:2400
0x679d53 gfc_match_data_decl()
        ../../gcc/fortran/decl.c:4841
0x6cc069 match_word_omp_simd
        ../../gcc/fortran/parse.c:93
0x6cf40e match_word
        ../../gcc/fortran/parse.c:373
0x6cf40e decode_statement
        ../../gcc/fortran/parse.c:373
0x6d1114 next_free
        ../../gcc/fortran/parse.c:1120
0x6d1114 next_statement
        ../../gcc/fortran/parse.c:1354
0x6d259c parse_spec
        ../../gcc/fortran/parse.c:3498
0x6d4543 parse_progunit
        ../../gcc/fortran/parse.c:5463
0x6d5ae4 gfc_parse_file()
        ../../gcc/fortran/parse.c:5972
0x718022 gfc_be_parse_file
        ../../gcc/fortran/f95-lang.c:198

---


$ cat zz6.f90
program p
   character(0) :: z1(0)
   character(0), allocatable :: z2(:)
   character(:), allocatable :: z3(:)
   z1 = [character(*) ::]
   z2 = [character(*) ::]
   z3 = [character(*) ::]
   call sub ([character(*) ::])
contains
   subroutine sub (z)
      character(*) :: z(:)
      print *, z
   end
end


$ gfortran-6 zz6.f90
f951: internal compiler error: in gfc_resolve_character_array_constructor, at
fortran/array.c:2020
>From gcc-bugs-return-529680-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:31:10 2016
Return-Path: <gcc-bugs-return-529680-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 66882 invoked by alias); 4 Jul 2016 17:31:09 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 66773 invoked by uid 48); 4 Jul 2016 17:30:56 -0000
From: "gerhard.steinmetz.fortran@t-online.de" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/65173] ICE while compiling wrong code
Date: Mon, 04 Jul 2016 17:31:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 4.9.2
X-Bugzilla-Keywords:
X-Bugzilla-Severity: minor
X-Bugzilla-Who: gerhard.steinmetz.fortran@t-online.de
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: cc
Message-ID: <bug-65173-4-Ssd7gP3BCw@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-65173-4@http.gcc.gnu.org/bugzilla/>
References: <bug-65173-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00263.txt.bz2
Content-length: 1915

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65173

Gerhard Steinmetz <gerhard.steinmetz.fortran@t-online.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |gerhard.steinmetz.fortran@t
                   |                            |-online.de

--- Comment #3 from Gerhard Steinmetz <gerhard.steinmetz.fortran@t-online.de> ---
Several more examples.
The dimension attribute may be placed this way or that way.


gfortran-6 (release) aborts with ...
(null):0: confused by earlier errors, bailing out


gfortran-7 (experimental) aborts in one of ...
gfc_is_constant_expr
gfc_get_default_type
gfc_resolve_expr


... with one of these messages :
Error: Allocatable component of structure at (1) must have a deferred shape
Error: Array component of structure at (1) must have an explicit shape
Error: Expression at (1) must be of INTEGER type, found PROCEDURE
Error: Syntax error in data declaration at (1)



$ cat z0.f90
program p
   type t
      character(1), allocatable :: names(256)
   end type
end


$ cat z1.f90
program p
   type t
      character(:), allocatable :: x(n)
   end type
end


$ cat z2.f90
program p
   type t
      character(*), allocatable :: x(*)
   end type
end


$ cat z3.f90
program p
   type t
      character(*) :: x y
   end type
end


$ cat z4.f90
program p
   type t
      character(*) :: x+1
   end type
end


$ cat z5.f90
program p
   type t
   end type
   type, extends(t) :: t2
      character x =
   end type
end


$ cat z6.f90
program p
   type t
   end type
   type, extends(t) :: t2
      character x 'x'
   end type
end


$ cat z7.f90
program p
   type t
   end type
   type, extends(t) :: t2
      character x(:)
   end type
end


$ cat z8.f90
program p
   type t
      character(:), allocatable :: x(y)1
   end type
end


...
>From gcc-bugs-return-529681-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:32:23 2016
Return-Path: <gcc-bugs-return-529681-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 68781 invoked by alias); 4 Jul 2016 17:32:23 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 68630 invoked by uid 55); 4 Jul 2016 17:32:10 -0000
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/71739] [6/7 Regression] ICE on valid C++11 code: tree check: expected identifier_node, have tree_list in private_is_attribute_p, at tree.c:6080
Date: Mon, 04 Jul 2016 17:32:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jakub at gcc dot gnu.org
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: jakub at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 6.2
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71739-4-wnssRqbrsT@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71739-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71739-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00264.txt.bz2
Content-length: 582

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71739

--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Author: jakub
Date: Mon Jul  4 17:31:38 2016
New Revision: 237991

URL: https://gcc.gnu.org/viewcvs?rev=237991&root=gcc&view=rev
Log:
        PR c++/71739
        * tree.c (attribute_value_equal): Use get_attribute_name instead of
        directly using TREE_PURPOSE.

        * g++.dg/cpp0x/pr71739.C: New test.

Added:
    trunk/gcc/testsuite/g++.dg/cpp0x/pr71739.C
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/tree.c
>From gcc-bugs-return-529682-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:33:49 2016
Return-Path: <gcc-bugs-return-529682-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 70409 invoked by alias); 4 Jul 2016 17:33:49 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 70109 invoked by uid 48); 4 Jul 2016 17:33:36 -0000
From: "gerhard.steinmetz.fortran@t-online.de" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/47425] Array constructor with type-spec: Fails with more complicated length type expr
Date: Mon, 04 Jul 2016 17:33:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 4.6.0
X-Bugzilla-Keywords: ice-on-valid-code, rejects-valid
X-Bugzilla-Severity: normal
X-Bugzilla-Who: gerhard.steinmetz.fortran@t-online.de
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: cc
Message-ID: <bug-47425-4-K861jwQE2b@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-47425-4@http.gcc.gnu.org/bugzilla/>
References: <bug-47425-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00265.txt.bz2
Content-length: 1576

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=47425

Gerhard Steinmetz <gerhard.steinmetz.fortran@t-online.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |gerhard.steinmetz.fortran@t
                   |                            |-online.de

--- Comment #3 from Gerhard Steinmetz <gerhard.steinmetz.fortran@t-online.de> ---
Together with -flto :

$ gfortran-7-20160703 -flto -c pr47425.f90
pr47425.f90:7:0: internal compiler error: tree code 'ssa_name' is not supported
in LTO streams
 end

0xada461 DFS::DFS(output_block*, tree_node*, bool, bool, bool)
        ../../gcc/lto-streamer-out.c:676
0xadba6d lto_output_tree(output_block*, tree_node*, bool, bool)
        ../../gcc/lto-streamer-out.c:1616
0xacfd7f write_global_stream
        ../../gcc/lto-streamer-out.c:2418
0xad969e lto_output_decl_state_streams(output_block*, lto_out_decl_state*)
        ../../gcc/lto-streamer-out.c:2465
0xad969e produce_asm_for_decls()
        ../../gcc/lto-streamer-out.c:2836
0xb4138f write_lto
        ../../gcc/passes.c:2455
0xb44d3e ipa_write_summaries_1
        ../../gcc/passes.c:2516
0xb44d3e ipa_write_summaries()
        ../../gcc/passes.c:2576
0x83694f ipa_passes
        ../../gcc/cgraphunit.c:2311
0x83694f symbol_table::compile()
        ../../gcc/cgraphunit.c:2405
0x8391a2 symbol_table::compile()
        ../../gcc/cgraphunit.c:2539
0x8391a2 symbol_table::finalize_compilation_unit()
        ../../gcc/cgraphunit.c:2565
>From gcc-bugs-return-529683-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:34:35 2016
Return-Path: <gcc-bugs-return-529683-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 71688 invoked by alias); 4 Jul 2016 17:34:35 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 71587 invoked by uid 55); 4 Jul 2016 17:34:22 -0000
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/71739] [6/7 Regression] ICE on valid C++11 code: tree check: expected identifier_node, have tree_list in private_is_attribute_p, at tree.c:6080
Date: Mon, 04 Jul 2016 17:34:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jakub at gcc dot gnu.org
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: jakub at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 6.2
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71739-4-fjHJZTxDMy@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71739-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71739-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00266.txt.bz2
Content-length: 646

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71739

--- Comment #5 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Author: jakub
Date: Mon Jul  4 17:33:50 2016
New Revision: 237992

URL: https://gcc.gnu.org/viewcvs?rev=237992&root=gcc&view=rev
Log:
        PR c++/71739
        * tree.c (attribute_value_equal): Use get_attribute_name instead of
        directly using TREE_PURPOSE.

        * g++.dg/cpp0x/pr71739.C: New test.

Added:
    branches/gcc-6-branch/gcc/testsuite/g++.dg/cpp0x/pr71739.C
Modified:
    branches/gcc-6-branch/gcc/ChangeLog
    branches/gcc-6-branch/gcc/testsuite/ChangeLog
    branches/gcc-6-branch/gcc/tree.c
>From gcc-bugs-return-529684-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:36:04 2016
Return-Path: <gcc-bugs-return-529684-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 74830 invoked by alias); 4 Jul 2016 17:36:04 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 74742 invoked by uid 48); 4 Jul 2016 17:35:51 -0000
From: "gerhard.steinmetz.fortran@t-online.de" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/47425] Array constructor with type-spec: Fails with more complicated length type expr
Date: Mon, 04 Jul 2016 17:36:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 4.6.0
X-Bugzilla-Keywords: ice-on-valid-code, rejects-valid
X-Bugzilla-Severity: normal
X-Bugzilla-Who: gerhard.steinmetz.fortran@t-online.de
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-47425-4-SiThVqFCan@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-47425-4@http.gcc.gnu.org/bugzilla/>
References: <bug-47425-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00267.txt.bz2
Content-length: 1961

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=47425

--- Comment #4 from Gerhard Steinmetz <gerhard.steinmetz.fortran@t-online.de> ---
Some simplifications :


$ cat z1.f90
program p
   character(3) :: x
   integer :: n = 3
   print *, [character(len(x(1:n))) :: 'a']
end


$ gfortran-7-20160703 z1.f90
z1.f90:4:0:

    print *, [character(len(x(1:n))) :: 'a']

Error: size of variable 'A.1' is too large

---


$ cat z2.f90
program p
   character(3) :: x
   print *, [character(len(x(1:3))) :: 'a', 'b']
end


$ gfortran-7-20160703 z2.f90
z2.f90:4:0:

 end

internal compiler error: in output_constructor_regular_field, at varasm.c:4979
0xef0ac5 output_constructor_regular_field
        ../../gcc/varasm.c:4979
0xef0ac5 output_constructor
        ../../gcc/varasm.c:5287
0xef0e64 output_constant
        ../../gcc/varasm.c:4664
0xef0e64 assemble_variable_contents
        ../../gcc/varasm.c:2073
0xef8619 assemble_variable(tree_node*, int, int, int)
        ../../gcc/varasm.c:2249
0xefde08 varpool_node::assemble_decl()
        ../../gcc/varpool.c:589
0x8363c3 output_in_order
        ../../gcc/cgraphunit.c:2232
0x83674d symbol_table::compile()
        ../../gcc/cgraphunit.c:2469
0x8391a2 symbol_table::compile()
        ../../gcc/cgraphunit.c:2539
0x8391a2 symbol_table::finalize_compilation_unit()
        ../../gcc/cgraphunit.c:2565

---


$ cat z3.f90
program p
   character(3) :: x
   print *, [character(len(x(:))) :: 'a', 'b']
end


$ gfortran-7-20160703 z3.f90
$ a.out
 a  b

---


$ cat z1_parameter.f90
program p
   character(3) :: x
   integer, parameter :: n = 3
   print *, [character(len(x(1:n))) :: 'a']
end


$ gfortran-7-20160703 z1_parameter.f90
$ a.out
 a

---


$ cat z4.f90
program p
   character(3) :: x
   integer, parameter :: n = 3
   print *, [character(len(x(1:n))) :: 'a', 'b']
end


$ gfortran-7-20160703 z4.f90
z4.f90:5:0:

 end

internal compiler error: in output_constructor_regular_field, at varasm.c:4979
#...
>From gcc-bugs-return-529685-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:37:43 2016
Return-Path: <gcc-bugs-return-529685-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 75970 invoked by alias); 4 Jul 2016 17:37:43 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 75905 invoked by uid 48); 4 Jul 2016 17:37:30 -0000
From: "gerhard.steinmetz.fortran@t-online.de" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/71758] New: ICE in verify_gimple_in_cfg, at tree-cfg.c:5212
Date: Mon, 04 Jul 2016 17:37:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: gerhard.steinmetz.fortran@t-online.de
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone
Message-ID: <bug-71758-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00268.txt.bz2
Content-length: 1215

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71758

            Bug ID: 71758
           Summary: ICE in verify_gimple_in_cfg, at tree-cfg.c:5212
           Product: gcc
           Version: 7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: gerhard.steinmetz.fortran@t-online.de
  Target Milestone: ---

With example .../libgomp/testsuite/libgomp.fortran/examples-4/device-2.f90 :


$ gfortran-7-20160703 -fdefault-integer-8 -fopenmp device-2.f90
device-2.f90:5:0:

   use omp_lib, only: omp_is_initial_device, omp_get_num_devices

Error: invalid argument to gimple call
(integer(kind=4)) D.3574
__builtin_GOMP_target_ext ((integer(kind=4)) D.3574, MAIN__._omp_fn.1, 3,
&.omp_data_arr.5, &.omp_data_sizes.6, &.omp_data_kinds.7, 0, 0B,
&.omp_target_args.9);
device-2.f90:5:0: internal compiler error: verify_gimple failed
0xc51336 verify_gimple_in_cfg(function*, bool)
        ../../gcc/tree-cfg.c:5212
0xb41283 execute_function_todo
        ../../gcc/passes.c:1964
0xb41aed do_per_function
        ../../gcc/passes.c:1655
0xb41c3b execute_todo
        ../../gcc/passes.c:2016
>From gcc-bugs-return-529686-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:41:42 2016
Return-Path: <gcc-bugs-return-529686-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 82178 invoked by alias); 4 Jul 2016 17:41:42 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 82104 invoked by uid 48); 4 Jul 2016 17:41:34 -0000
From: "gerhard.steinmetz.fortran@t-online.de" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/71759] New: ICE in enforce_single_undo_checkpoint, at fortran/symbol.c:3478
Date: Mon, 04 Jul 2016 17:41:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: gerhard.steinmetz.fortran@t-online.de
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone
Message-ID: <bug-71759-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00269.txt.bz2
Content-length: 2469

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71759

            Bug ID: 71759
           Summary: ICE in enforce_single_undo_checkpoint, at
                    fortran/symbol.c:3478
           Product: gcc
           Version: 7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: gerhard.steinmetz.fortran@t-online.de
  Target Milestone: ---

Typo, e.g. for intrinsic functions with a non-scalar argument :

$ cat z1.f90
program p
   print *, abs([real(1)/9., real(2)/9.])
   print *, abs([real(10/9., real(2)/9.])
end


$ gfortran-6 z1.f90
z1.f90:3:39:

    print *, abs([real(10/9., real(2)/9.])
                                       1
Error: Syntax error in argument list at (1)


$ gfortran-7-20160703 z1.f90
f951: internal compiler error: in enforce_single_undo_checkpoint, at
fortran/symbol.c:3478
0x5d872a enforce_single_undo_checkpoint
        ../../gcc/fortran/symbol.c:3478
0x7090c8 enforce_single_undo_checkpoint
        ../../gcc/fortran/symbol.c:3566
0x7090c8 gfc_commit_symbol(gfc_symbol*)
        ../../gcc/fortran/symbol.c:3554
0x69e5fd gfc_convert_type_warn(gfc_expr*, gfc_typespec*, int, int)
        ../../gcc/fortran/intrinsic.c:4767
0x6561b0 eval_intrinsic
        ../../gcc/fortran/arith.c:1544
0x6564ce eval_intrinsic_f3
        ../../gcc/fortran/arith.c:1725
0x6b4493 match_add_operand
        ../../gcc/fortran/matchexp.c:394
0x6b46bc match_level_2
        ../../gcc/fortran/matchexp.c:480
0x6b4812 match_level_3
        ../../gcc/fortran/matchexp.c:551
0x6b4924 match_level_4
        ../../gcc/fortran/matchexp.c:599
0x6b4924 match_and_operand
        ../../gcc/fortran/matchexp.c:693
0x6b4ae2 match_or_operand
        ../../gcc/fortran/matchexp.c:722
0x6b4bd2 match_equiv_operand
        ../../gcc/fortran/matchexp.c:765
0x6b4cc2 match_level_5
        ../../gcc/fortran/matchexp.c:811
0x6b4031 gfc_match_expr(gfc_expr**)
        ../../gcc/fortran/matchexp.c:870
0x688522 gfc_match_init_expr(gfc_expr**)
        ../../gcc/fortran/expr.c:2702
0x672598 gfc_match_kind_spec(gfc_typespec*, bool)
        ../../gcc/fortran/decl.c:2569
0x6af456 gfc_match_type_spec(gfc_typespec*)
        ../../gcc/fortran/match.c:2063
0x65ac45 gfc_match_array_constructor(gfc_expr**)
        ../../gcc/fortran/array.c:1106
0x6b41c9 match_primary
        ../../gcc/fortran/matchexp.c:153

# (configured with --enable-checking=yes)
>From gcc-bugs-return-529687-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:42:15 2016
Return-Path: <gcc-bugs-return-529687-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 83059 invoked by alias); 4 Jul 2016 17:42:15 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 82992 invoked by uid 48); 4 Jul 2016 17:42:09 -0000
From: "gerhard.steinmetz.fortran@t-online.de" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/71759] ICE in enforce_single_undo_checkpoint, at fortran/symbol.c:3478
Date: Mon, 04 Jul 2016 17:42:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: gerhard.steinmetz.fortran@t-online.de
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71759-4-82knNzlS2v@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71759-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71759-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00270.txt.bz2
Content-length: 534

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71759

--- Comment #1 from Gerhard Steinmetz <gerhard.steinmetz.fortran@t-online.de> ---

Another typo :

$ cat z2.f90
program p
   print *, [character((100)) :: 'x']
   print *, [character((1,0)) :: 'x']
end


$ gfortran-6 z2.f90
z2.f90:3:23:

    print *, [character((1,0)) :: 'x']
                       1
Error: Scalar INTEGER expression expected at (1)


$ gfortran-7-20160703 z2.f90
f951: internal compiler error: in enforce_single_undo_checkpoint, at
fortran/symbol.c:3478
#...
>From gcc-bugs-return-529688-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 17:51:05 2016
Return-Path: <gcc-bugs-return-529688-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 113448 invoked by alias); 4 Jul 2016 17:51:04 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 113340 invoked by uid 48); 4 Jul 2016 17:50:52 -0000
From: "rocco at tecsiel dot it" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug other/71760] New: libiberty - Segmentation fault when attempting to delete a non-existent element in a hash table
Date: Mon, 04 Jul 2016 17:51:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: other
X-Bugzilla-Version: unknown
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: rocco at tecsiel dot it
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone attachments.created
Message-ID: <bug-71760-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00271.txt.bz2
Content-length: 2084

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71760

            Bug ID: 71760
           Summary: libiberty - Segmentation fault when attempting to
                    delete a non-existent element in a hash table
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: other
          Assignee: unassigned at gcc dot gnu.org
          Reporter: rocco at tecsiel dot it
  Target Milestone: ---

Created attachment 38831
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=38831&action=edit
C source file to reproduce the bug

Hello people,                                                        
the attached C-program can be used to reproduce a segmentation fault 
found in libliberty/hashtab.c

I am using a libiberty tar-gzipped source version found in a recent Debian 
Archive File (libiberty_20160215.tar.xz) where the first entry in ChangeLog is: 
 * 2016-01-27  Iain Buclaw  <ibuclaw@gdcproject.org> 

This is the output of the execution of my program before patching the 
library:

rocco@nuc.carbo.net 1221> ./bug-remove 
Hello world! 

  This program creates a hash table with htab_create(). 
    Then: 
      * inserts 2 objects with htab_find_slot(INSERT). 
      * delete 1 existent with htab_remove_elt(). 
      * attempt to delete 1 non existent with htab_remove_elt(). 
        Boom !!! 

Inserting [Hello - 1] ... Ok 
Inserting [World! - 2] ... Ok 
Searching for [Hello] ... Ok 
Searching for [World!] ... Ok 
Deleting [Hello] ... Ok 
Segmentation fault 

And this was the patch I applied in libiberty/libiberty: 
rocco@nuc.carbo.net 1222> diff hashtab.c hashtab.c.ORG  
729c729 
<   if (!slot || *slot == HTAB_EMPTY_ENTRY) 
--- 
>   if (*slot == HTAB_EMPTY_ENTRY)

the same error could be also in other different points for 
different API functions but I did not check. 

/rocco
>From gcc-bugs-return-529689-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 18:03:45 2016
Return-Path: <gcc-bugs-return-529689-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 9949 invoked by alias); 4 Jul 2016 18:03:45 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 9701 invoked by uid 48); 4 Jul 2016 18:03:32 -0000
From: "msebor at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug middle-end/49905] Better sanity checking on sprintf src & dest to produce warning for dodgy code ?
Date: Mon, 04 Jul 2016 18:03:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: middle-end
X-Bugzilla-Version: 4.7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: enhancement
X-Bugzilla-Who: msebor at gcc dot gnu.org
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: msebor at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-49905-4-lnAyZid0GE@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-49905-4@http.gcc.gnu.org/bugzilla/>
References: <bug-49905-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00272.txt.bz2
Content-length: 940

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=49905

--- Comment #16 from Martin Sebor <msebor at gcc dot gnu.org> ---
(In reply to Jakub Jelinek from comment #14)
> But 9 is maximum length just for the %+03d part, %02d with the limited VRP
> range is exactly 2 and then the '\0', so that is 12 maximum, 6 minimum.

Yes.

> So printing 9 is just misleading.

The 9 actually corresponds to a range between 3 and 9 bytes so the warning
could print that range, the same way it does for unknown and unbounded values
at level 2, like so:

  warning: ‘%+03d’ directive output may be truncated between ‘3’ and ‘9’ bytes
into a region of size ‘6’ [-Wformat-length=]

The note could also be extended to print a range:

  note: destination region size is ‘6’ bytes, minimum required ‘6’, maximum
‘12’

Does this make it clearer?
>From gcc-bugs-return-529690-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 18:09:39 2016
Return-Path: <gcc-bugs-return-529690-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 24825 invoked by alias); 4 Jul 2016 18:09:39 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 24576 invoked by uid 48); 4 Jul 2016 18:09:26 -0000
From: "timo.teras at iki dot fi" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libgcj/71757] libgcj: unknown symbol __cxa_throw_bad_array_new_length
Date: Mon, 04 Jul 2016 18:09:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: libgcj
X-Bugzilla-Version: 6.1.0
X-Bugzilla-Keywords: build
X-Bugzilla-Severity: normal
X-Bugzilla-Who: timo.teras at iki dot fi
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71757-4-YpeAzjgcSz@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71757-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71757-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00273.txt.bz2
Content-length: 710

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71757

--- Comment #8 from Timo Teräs <timo.teras at iki dot fi> ---
(In reply to Andrew Pinski from comment #5)
>   LIBSTDCXX_RAW_CXX_CXXFLAGS="\
>     -I\$(top_builddir)/../libstdc++-v3/include \
>     -I\$(top_builddir)/../libstdc++-v3/include/\$(target_noncanonical) \
>     -I\$(top_srcdir)/../libstdc++-v3/libsupc++"
>   LIBSTDCXX_RAW_CXX_LDFLAGS="\
>     \$(top_builddir)/../libstdc++-v3/src/libstdc++.la"
> 
> 
> That should be used.

config.log says that is indeed there.

Quick look at libjava/Makefile.in says LIBSTDCXX_RAW_CXX_* is used only for
lib_gnu_awt_xlib_la_*.

Should I try adding LIBSTRCXX_RAW_CXX_* to libgcj_la_* accordingly?
>From gcc-bugs-return-529691-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 18:28:00 2016
Return-Path: <gcc-bugs-return-529691-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 64853 invoked by alias); 4 Jul 2016 18:28:00 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 64623 invoked by uid 48); 4 Jul 2016 18:27:48 -0000
From: "vanyacpp at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/71761] New: missing tailcall optimization
Date: Mon, 04 Jul 2016 18:28:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 6.1.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: vanyacpp at gmail dot com
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone
Message-ID: <bug-71761-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00274.txt.bz2
Content-length: 836

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71761

            Bug ID: 71761
           Summary: missing tailcall optimization
           Product: gcc
           Version: 6.1.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: vanyacpp at gmail dot com
  Target Milestone: ---

Currently GCC doesn't optimize tailcall in the following function:

struct token
{
    char const* tok_start;
    char const* tok_end;
    int tok_type;
    unsigned identifier_hash;
};

token f();

token g()
{
  return f();
}

Generated code:

g():
        pushq   %rbx
        movq    %rdi, %rbx
        call    f()
        movq    %rbx, %rax
        popq    %rbx
        ret

Expected:

g():
        jmp     f()
>From gcc-bugs-return-529692-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 19:03:15 2016
Return-Path: <gcc-bugs-return-529692-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 125049 invoked by alias); 4 Jul 2016 19:03:14 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 124919 invoked by uid 48); 4 Jul 2016 19:03:01 -0000
From: "kargl at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/71758] ICE in verify_gimple_in_cfg, at tree-cfg.c:5212
Date: Mon, 04 Jul 2016 19:03:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: kargl at gcc dot gnu.org
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: cc
Message-ID: <bug-71758-4-VrzvME7DKD@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71758-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71758-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00275.txt.bz2
Content-length: 498

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71758

kargl at gcc dot gnu.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |kargl at gcc dot gnu.org

--- Comment #1 from kargl at gcc dot gnu.org ---
Don't use -fdefault-integer-8.  It breaks storage association rules
of Fortran.  This option along with the other -fdefault-* options
should be removed.
>From gcc-bugs-return-529693-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 19:15:38 2016
Return-Path: <gcc-bugs-return-529693-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 28796 invoked by alias); 4 Jul 2016 19:15:38 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 28727 invoked by uid 55); 4 Jul 2016 19:15:32 -0000
From: "jvdelisle at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/35849] "wrong" line shown in error message for parameter
Date: Mon, 04 Jul 2016 19:15:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 4.4.0
X-Bugzilla-Keywords: diagnostic, patch
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jvdelisle at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-35849-4-z0HgE5YVZj@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-35849-4@http.gcc.gnu.org/bugzilla/>
References: <bug-35849-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00276.txt.bz2
Content-length: 723

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=35849

--- Comment #6 from Jerry DeLisle <jvdelisle at gcc dot gnu.org> ---
Author: jvdelisle
Date: Mon Jul  4 19:14:54 2016
New Revision: 237993

URL: https://gcc.gnu.org/viewcvs?rev=237993&root=gcc&view=rev
Log:
2016-07-04  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
            Steven G. Kargl  <kargl@gcc.gnu.org>

        PR fortran/35849
        * simplify.c (gfc_simplify_ishftc): Check that absolute value of
        SHIFT is less than or equal to SIZE.

        * gfortran.dg: pr35849.f90: New test.

Added:
    trunk/gcc/testsuite/gfortran.dg/pr35849.f90
Modified:
    trunk/gcc/fortran/ChangeLog
    trunk/gcc/fortran/simplify.c
    trunk/gcc/testsuite/ChangeLog
>From gcc-bugs-return-529694-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 19:36:20 2016
Return-Path: <gcc-bugs-return-529694-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 62265 invoked by alias); 4 Jul 2016 19:36:19 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 62218 invoked by uid 48); 4 Jul 2016 19:36:07 -0000
From: "glisse at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/71761] missing tailcall optimization
Date: Mon, 04 Jul 2016 19:36:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 6.1.0
X-Bugzilla-Keywords: missed-optimization
X-Bugzilla-Severity: enhancement
X-Bugzilla-Who: glisse at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: keywords bug_status cf_reconfirmed_on everconfirmed bug_severity
Message-ID: <bug-71761-4-V7YaXQUzPe@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71761-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71761-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00277.txt.bz2
Content-length: 661

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71761

Marc Glisse <glisse at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |missed-optimization
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2016-07-04
     Ever confirmed|0                           |1
           Severity|normal                      |enhancement

--- Comment #1 from Marc Glisse <glisse at gcc dot gnu.org> ---
Works with typedef int token;
Fails with struct token { int i; };
>From gcc-bugs-return-529695-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 19:45:10 2016
Return-Path: <gcc-bugs-return-529695-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 82803 invoked by alias); 4 Jul 2016 19:45:10 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 82619 invoked by uid 48); 4 Jul 2016 19:44:57 -0000
From: "jvdelisle at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/35849] "wrong" line shown in error message for parameter
Date: Mon, 04 Jul 2016 19:45:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 4.4.0
X-Bugzilla-Keywords: diagnostic, patch
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jvdelisle at gcc dot gnu.org
X-Bugzilla-Status: RESOLVED
X-Bugzilla-Resolution: FIXED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_status resolution
Message-ID: <bug-35849-4-PAvplD6aPN@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-35849-4@http.gcc.gnu.org/bugzilla/>
References: <bug-35849-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00278.txt.bz2
Content-length: 449

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=35849

Jerry DeLisle <jvdelisle at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #7 from Jerry DeLisle <jvdelisle at gcc dot gnu.org> ---
Closing, Fixed on Trunk.
>From gcc-bugs-return-529696-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 20:07:05 2016
Return-Path: <gcc-bugs-return-529696-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 109067 invoked by alias); 4 Jul 2016 20:07:05 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 108985 invoked by uid 48); 4 Jul 2016 20:06:53 -0000
From: "vanyacpp at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/71761] missing tailcall optimization
Date: Mon, 04 Jul 2016 20:07:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 6.1.0
X-Bugzilla-Keywords: missed-optimization
X-Bugzilla-Severity: enhancement
X-Bugzilla-Who: vanyacpp at gmail dot com
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71761-4-M1sPf4gcUO@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71761-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71761-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00279.txt.bz2
Content-length: 654

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71761

--- Comment #2 from Ivan Sorokin <vanyacpp at gmail dot com> ---
I compared this with clang.

1) typedef int token;
Both GCC and clang optimize this to a single jump.

2) struct token {int a};
clang optimizes this into a single jump. GCC generates:
        subq    $8, %rsp
        call    f()
        addq    $8, %rsp
        ret

3) struct token as in the issue
Both compilers do
        pushq   %rbx
        movq    %rdi, %rbx
        call    f()
        movq    %rbx, %rax
        popq    %rbx
        ret

I don't quite understand why both clang and GCC generate different code all
these cases.
>From gcc-bugs-return-529697-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 20:36:07 2016
Return-Path: <gcc-bugs-return-529697-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 83483 invoked by alias); 4 Jul 2016 20:36:07 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 83164 invoked by uid 48); 4 Jul 2016 20:35:53 -0000
From: "glisse at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/71761] missing tailcall optimization
Date: Mon, 04 Jul 2016 20:36:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 6.1.0
X-Bugzilla-Keywords: missed-optimization
X-Bugzilla-Severity: enhancement
X-Bugzilla-Who: glisse at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71761-4-TOL9hSTWPq@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71761-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71761-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00280.txt.bz2
Content-length: 1066

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71761

--- Comment #3 from Marc Glisse <glisse at gcc dot gnu.org> ---
For clang, this seems based on size: up to size 16 they get jmp, starting from
17 they get a call.

For gcc, we give up on anything more complicated than a "register":

  /* If the LHS of our call is not just a simple register, we can't
     transform this into a tail or sibling call.  This situation happens,
     in (e.g.) "*p = foo()" where foo returns a struct.  In this case
     we won't have a temporary here, but we need to carry out the side
     effect anyway, so tailcall is impossible.

     ??? In some situations (when the struct is returned in memory via
     invisible argument) we could deal with this, e.g. by passing 'p'
     itself as that argument to foo, but it's too early to do this here,
     and expand_call() will not handle it anyway.  If it ever can, then
     we need to revisit this here, to allow that situation.  */
  if (ass_var && !is_gimple_reg (ass_var))
    return;

The ??? comment is exactly your case.
>From gcc-bugs-return-529698-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 20:52:29 2016
Return-Path: <gcc-bugs-return-529698-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 81719 invoked by alias); 4 Jul 2016 20:52:29 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 78387 invoked by uid 48); 4 Jul 2016 20:52:17 -0000
From: "ldionne.2 at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/59498] [DR 1430][4.9/5/6/7 Regression] Pack expansion error in template alias
Date: Mon, 04 Jul 2016 20:52:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords: rejects-valid
X-Bugzilla-Severity: normal
X-Bugzilla-Who: ldionne.2 at gmail dot com
X-Bugzilla-Status: SUSPENDED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P5
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 4.9.4
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-59498-4-Y26BmfbQrE@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-59498-4@http.gcc.gnu.org/bugzilla/>
References: <bug-59498-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00281.txt.bz2
Content-length: 310

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59498

--- Comment #12 from Louis Dionne <ldionne.2 at gmail dot com> ---
Not sure, as I've been off pure-type computations for a while now. Looking at
how Meta does it might be useful:
https://github.com/ericniebler/meta/blob/master/include/meta/meta.hpp#L819
>From gcc-bugs-return-529699-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 21:05:40 2016
Return-Path: <gcc-bugs-return-529699-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 98924 invoked by alias); 4 Jul 2016 21:05:40 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 98811 invoked by uid 55); 4 Jul 2016 21:05:27 -0000
From: "jvdelisle at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/66575] Endless compilation on missing end interface
Date: Mon, 04 Jul 2016 21:05:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 5.1.1
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jvdelisle at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: jvdelisle at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-66575-4-wHYS81qwIT@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-66575-4@http.gcc.gnu.org/bugzilla/>
References: <bug-66575-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00282.txt.bz2
Content-length: 657

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66575

--- Comment #5 from Jerry DeLisle <jvdelisle at gcc dot gnu.org> ---
Author: jvdelisle
Date: Mon Jul  4 21:04:55 2016
New Revision: 237994

URL: https://gcc.gnu.org/viewcvs?rev=237994&root=gcc&view=rev
Log:
2016-07-04  Jerry DeLisle  <jvdelisle@gcc.gnu.org>

        PR fortran/66575
        * decl.c (match_procedure_interface): Exit loop if procedure
        interface refers to itself.

        * gfortran.dg: pr65575.f90: New test.

Added:
    trunk/gcc/testsuite/gfortran.dg/pr66575.f90
Modified:
    trunk/gcc/fortran/ChangeLog
    trunk/gcc/fortran/decl.c
    trunk/gcc/testsuite/ChangeLog
>From gcc-bugs-return-529700-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 21:06:36 2016
Return-Path: <gcc-bugs-return-529700-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 101891 invoked by alias); 4 Jul 2016 21:06:34 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 100594 invoked by uid 48); 4 Jul 2016 21:06:21 -0000
From: "jvdelisle at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/66575] Endless compilation on missing end interface
Date: Mon, 04 Jul 2016 21:06:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 5.1.1
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jvdelisle at gcc dot gnu.org
X-Bugzilla-Status: RESOLVED
X-Bugzilla-Resolution: FIXED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: jvdelisle at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_status resolution
Message-ID: <bug-66575-4-Xok1MAYnht@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-66575-4@http.gcc.gnu.org/bugzilla/>
References: <bug-66575-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00283.txt.bz2
Content-length: 449

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66575

Jerry DeLisle <jvdelisle at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #6 from Jerry DeLisle <jvdelisle at gcc dot gnu.org> ---
Fixed on trunk, closing.
>From gcc-bugs-return-529701-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 21:13:03 2016
Return-Path: <gcc-bugs-return-529701-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 108584 invoked by alias); 4 Jul 2016 21:13:03 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 108430 invoked by uid 48); 4 Jul 2016 21:12:49 -0000
From: "eugene.zelenko at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/71069] -Waddress didn't catch all cases
Date: Mon, 04 Jul 2016 21:13:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 6.1.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: eugene.zelenko at gmail dot com
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71069-4-y1nSdfb5XT@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71069-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71069-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00284.txt.bz2
Content-length: 386

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71069

--- Comment #3 from Eugene Zelenko <eugene.zelenko at gmail dot com> ---
(In reply to Andrew Pinski from comment #2)
> -fsantize=undefined will catch this at runtime.  What is undefined is
> passing a NULL to setData.

It'll be much better to report such problems during compilation, since run-time
paths depends on test cases.
>From gcc-bugs-return-529702-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 21:36:11 2016
Return-Path: <gcc-bugs-return-529702-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 110184 invoked by alias); 4 Jul 2016 21:36:11 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 110066 invoked by uid 48); 4 Jul 2016 21:35:58 -0000
From: "marxin at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/71756] [6/7 Regression] internal compiler error: in ~saved_token_sentinel, at cp/parser.c:1228
Date: Mon, 04 Jul 2016 21:36:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: ice-on-invalid-code
X-Bugzilla-Severity: normal
X-Bugzilla-Who: marxin at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 6.2
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: keywords bug_status cf_reconfirmed_on cc target_milestone short_desc everconfirmed
Message-ID: <bug-71756-4-0eiLkYyDfI@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71756-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71756-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00285.txt.bz2
Content-length: 999

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71756

Martin Liška <marxin at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |ice-on-invalid-code
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2016-07-04
                 CC|                            |marxin at gcc dot gnu.org
   Target Milestone|---                         |6.2
            Summary|internal compiler error: in |[6/7 Regression] internal
                   |~saved_token_sentinel, at   |compiler error: in
                   |cp/parser.c:1228            |~saved_token_sentinel, at
                   |                            |cp/parser.c:1228
     Ever confirmed|0                           |1

--- Comment #1 from Martin Liška <marxin at gcc dot gnu.org> ---
Confirmed, ICEs since GCC 6.1.0 release.
>From gcc-bugs-return-529703-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 21:39:17 2016
Return-Path: <gcc-bugs-return-529703-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 112688 invoked by alias); 4 Jul 2016 21:39:16 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 112607 invoked by uid 48); 4 Jul 2016 21:39:04 -0000
From: "marxin at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/71759] [7 Regression] ICE in enforce_single_undo_checkpoint, at fortran/symbol.c:3478
Date: Mon, 04 Jul 2016 21:39:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: ice-on-invalid-code
X-Bugzilla-Severity: normal
X-Bugzilla-Who: marxin at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 7.0
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: keywords bug_status cf_reconfirmed_on cc target_milestone short_desc everconfirmed
Message-ID: <bug-71759-4-HnUTdjRS31@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71759-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71759-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00286.txt.bz2
Content-length: 978

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71759

Martin Liška <marxin at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |ice-on-invalid-code
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2016-07-04
                 CC|                            |marxin at gcc dot gnu.org
   Target Milestone|---                         |7.0
            Summary|ICE in                      |[7 Regression] ICE in
                   |enforce_single_undo_checkpo |enforce_single_undo_checkpo
                   |int, at                     |int, at
                   |fortran/symbol.c:3478       |fortran/symbol.c:3478
     Ever confirmed|0                           |1

--- Comment #2 from Martin Liška <marxin at gcc dot gnu.org> ---
Confirmed on current trunk.
>From gcc-bugs-return-529704-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 21:39:55 2016
Return-Path: <gcc-bugs-return-529704-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 113521 invoked by alias); 4 Jul 2016 21:39:55 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 113442 invoked by uid 48); 4 Jul 2016 21:39:43 -0000
From: "pkeir at outlook dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/59498] [DR 1430][4.9/5/6/7 Regression] Pack expansion error in template alias
Date: Mon, 04 Jul 2016 21:39:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords: rejects-valid
X-Bugzilla-Severity: normal
X-Bugzilla-Who: pkeir at outlook dot com
X-Bugzilla-Status: SUSPENDED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P5
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 4.9.4
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-59498-4-4zoHqdUVUI@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-59498-4@http.gcc.gnu.org/bugzilla/>
References: <bug-59498-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00287.txt.bz2
Content-length: 176

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59498

--- Comment #13 from Paul Keir <pkeir at outlook dot com> ---
Yup, I just came up with exactly the same solution. Thanks.
>From gcc-bugs-return-529705-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 04 22:19:29 2016
Return-Path: <gcc-bugs-return-529705-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 68546 invoked by alias); 4 Jul 2016 22:19:29 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 56129 invoked by uid 48); 4 Jul 2016 22:19:16 -0000
From: "ibuclaw at gdcproject dot org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug middle-end/71762] New: [4.9 Regression] ifcombine wrong codegen with uninitialized data
Date: Mon, 04 Jul 2016 22:19:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: middle-end
X-Bugzilla-Version: 4.9.4
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: ibuclaw at gdcproject dot org
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone
Message-ID: <bug-71762-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00288.txt.bz2
Content-length: 1328

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71762

            Bug ID: 71762
           Summary: [4.9 Regression] ifcombine wrong codegen with
                    uninitialized data
           Product: gcc
           Version: 4.9.4
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: middle-end
          Assignee: unassigned at gcc dot gnu.org
          Reporter: ibuclaw at gdcproject dot org
  Target Milestone: ---

In the following minimal test built with: g++ -O2
---
#include <stdio.h>

struct S
{
  void* get()
  {
    return NULL;
  }

  ~S()
  {
    printf("dtor\n");
  }
};


void foo(void* x)
{
  printf("foo\n");
}


void testFunc(int len)
{
  bool __cond59;
  bool __cond60;

  foo ((__cond60 = len > 1, __cond60) ? NULL : (__cond59 = len == 1, __cond59)
? S().get() : NULL);

  if (!__cond60)
    {
      if (__cond59)
        {
          printf("fail\n");
        }
    }
}

void check(void (*dg)(int))
{
  dg(2);
}

int main()
{
  check(&testFunc);
}
---

The optimizer simplifies the two if statements as: `if (__cond59 > __cond60)`,
where __cond59 is never initialized in `testFunc`.

This regression is only present in 4.9.  gcc-4.8 and gcc-5 are unaffected.

The commit that caused the regression was r204194, and it went away after
r217496.
>From gcc-bugs-return-529706-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 01:20:15 2016
Return-Path: <gcc-bugs-return-529706-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 66388 invoked by alias); 5 Jul 2016 01:20:14 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 66270 invoked by uid 48); 5 Jul 2016 01:20:02 -0000
From: "anton at samba dot org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/71763] New: powerpc64: ICE due to need for output reload on jump
Date: Tue, 05 Jul 2016 01:20:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: target
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: anton at samba dot org
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone
Message-ID: <bug-71763-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00289.txt.bz2
Content-length: 2109

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71763

            Bug ID: 71763
           Summary: powerpc64: ICE due to need for output reload on jump
           Product: gcc
           Version: 7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: anton at samba dot org
  Target Milestone: ---

The following test case:

int a, b;
float c;

void fn2(void);

void fn1(void)
{
        long d;

        for (d = 3; d; d--) {
                for (a = 0; a <= 1; a++) {
                        b &= 1;
                        if (b) {
                                for (;;) {
                                        fn2();
                                        c = d;
                                }
                        }
                }
        }
}

built with -O1 hits an ICE:

crash1b.c:21:1: error: unable to generate reloads for:
 }
 ^
(jump_insn 43 42 62 7 (parallel [
            (set (pc)
                (if_then_else (ne (reg/v:DI 108 31 [orig:157 d ] [157])
                        (const_int 1 [0x1]))
                    (label_ref:DI 41)
                    (pc)))
            (set (reg/v:DI 108 31 [orig:157 d ] [157])
                (plus:DI (reg/v:DI 108 31 [orig:157 d ] [157])
                    (const_int -1 [0xffffffffffffffff])))
            (clobber (scratch:CC))
            (clobber (scratch:DI))
        ]) crash1b.c:10 797 {*ctrdi_internal1}
     (int_list:REG_BR_PROB 7500 (nil))
 -> 41)
crash1b.c:21:1: internal compiler error: in find_reloads, at reload.c:3830
0x10836413 _fatal_insn(char const*, rtx_def const*, char const*, int, char
const*)
        ../../gcc/gcc/rtl-error.c:108
0x1081c173 find_reloads(rtx_insn*, int, int, int, short*)
        ../../gcc/gcc/reload.c:3830
0x1083178f calculate_needs_all_insns
        ../../gcc/gcc/reload1.c:1483
0x1083178f reload(rtx_insn*, int)
        ../../gcc/gcc/reload1.c:995
0x1068c84b do_reload
        ../../gcc/gcc/ira.c:5396
0x1068c84b execute
        ../../gcc/gcc/ira.c:5568
>From gcc-bugs-return-529707-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 02:14:33 2016
Return-Path: <gcc-bugs-return-529707-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 50115 invoked by alias); 5 Jul 2016 02:14:33 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 50025 invoked by uid 48); 5 Jul 2016 02:14:21 -0000
From: "amodra at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/71763] powerpc64: ICE due to need for output reload on jump
Date: Tue, 05 Jul 2016 02:14:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: target
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: amodra at gmail dot com
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_status cf_reconfirmed_on cc everconfirmed
Message-ID: <bug-71763-4-TcKemGbXhJ@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71763-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71763-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00290.txt.bz2
Content-length: 817

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71763

Alan Modra <amodra at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2016-07-05
                 CC|                            |amodra at gmail dot com
     Ever confirmed|0                           |1

--- Comment #1 from Alan Modra <amodra at gmail dot com> ---
Confirmed.  This long-standing reload problem won't be fixed until something
like https://gcc.gnu.org/ml/gcc-patches/2004-12/msg00739.html is implemented. 
I'm not sure why I didn't pursue that patch not, but have a recollection that
it introduced a spec performance regression.
>From gcc-bugs-return-529708-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 02:58:57 2016
Return-Path: <gcc-bugs-return-529708-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 17890 invoked by alias); 5 Jul 2016 02:58:56 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 13120 invoked by uid 48); 5 Jul 2016 02:58:44 -0000
From: "msebor at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug middle-end/49905] Better sanity checking on sprintf src & dest to produce warning for dodgy code ?
Date: Tue, 05 Jul 2016 02:58:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: middle-end
X-Bugzilla-Version: 4.7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: enhancement
X-Bugzilla-Who: msebor at gcc dot gnu.org
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: msebor at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-49905-4-p2xfBlIgC3@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-49905-4@http.gcc.gnu.org/bugzilla/>
References: <bug-49905-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00291.txt.bz2
Content-length: 2230

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=49905

--- Comment #17 from Martin Sebor <msebor at gcc dot gnu.org> ---
I have tweaked the patch to print the following for the test case in comment
#13:

xyz.c: In function ‘f’:
xyz.c:10:46: warning: ‘%+03d’ directive output may be truncated between ‘3’ and
‘9’ bytes into a region of size ‘6’ [-Wformat-length=]
     __builtin_snprintf (zone, ZONE_LEN + 1, "%+03d%02d",
                                              ^
xyz.c:10:46: note: directive argument determined to be in the range
[‘-35791394’, ‘35791394’]
xyz.c:10:5: note: destination region size is ‘6’ bytes, minimum required ‘6’,
maximum ‘12’

The computation to determine the range of bytes on output is less
straightforward than might be expected when the argument is determined to be in
a range whose bounds have different signs and different magnitudes.  The
checker then has to decide which of the bounds to use as the maximum (the
minimum is zero).  For instance, if the argument is in range [-3, 123], the
relevant upper bound is 123 for %i but -3 for %u.  This is because formatting a
value in this range results in between 1 and 3 bytes on output for %i, but in
as many as 10 bytes for %u given 32-bit ints (-3 formats as "4294967293"). 
This may not be completely intuitive but I hope the new note helps make it
clearer.  For the %u case with [-3, 123], it results in:

warning: ‘%u’ directive output may be truncated between ‘1’ and ‘10’ bytes into
a region of size ‘3’ [-Wformat-length=]
     __builtin_snprintf (d, sizeof d, "%u", x);
                                       ^
note: directive argument determined to be in the range [‘-3’, ‘123’]

It still assumes the user will figure out that it's the lower end of the range
that results in the maximum of 10 bytes.  I'm not sure how to help with that
without cluttering the output with too much verbiage and possibly making some
cases seem more complicated than they are.
>From gcc-bugs-return-529709-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 03:29:16 2016
Return-Path: <gcc-bugs-return-529709-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 23511 invoked by alias); 5 Jul 2016 03:29:16 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 23423 invoked by uid 48); 5 Jul 2016 03:28:52 -0000
From: "heresy-me at hotmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/71764] New: compiler internal error: segmentation fault
Date: Tue, 05 Jul 2016 03:29:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 5.4.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: heresy-me at hotmail dot com
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone attachments.created
Message-ID: <bug-71764-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00292.txt.bz2
Content-length: 2155

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71764

            Bug ID: 71764
           Summary: compiler internal error: segmentation fault
           Product: gcc
           Version: 5.4.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: heresy-me at hotmail dot com
  Target Milestone: ---

Created attachment 38832
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=38832&action=edit
libfsqlite-full

I am wrapping the libsqlite3-dev for Fortran.


gfortran fsqlite_runtime.f08 -o fsqlite_runtime.o -fopenmp -Warray-bounds -Wall
-Wextra -fno-strict-aliasing -fwrapv -g -std=f2008ts -c

fsqlite_runtime.f08:103:0:

                 c_err = sqlite3_exec_ex(db, sqls, to_cb, to_dat, c_null_ptr)
 1

编译器内部错误: Segmentation fault
请提交一份完整的错误报告,
如有可能请附上经预处理后的源文件。
参阅 <http://gcc.gnu.org/bugs.html> 以获取指示。
make: *** [Makefile:56:fsqlite_runtime.o] 错误 1


fsqlite_runtime.f08:129:0:

                 c_err = sqlite3_prepare_ex(db, sql, c_strlen(c_loc(sql)),
stmt, c_null_ptr)
 1
编译器内部错误: Segmentation fault
请提交一份完整的错误报告,
如有可能请附上经预处理后的源文件。
参阅 <http://gcc.gnu.org/bugs.html> 以获取指示。
make: *** [Makefile:56:fsqlite_runtime.o] 错误 1

If I place the relevant code to a single file and compile it, it will be
successlly compiled.
>From gcc-bugs-return-529710-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 03:34:11 2016
Return-Path: <gcc-bugs-return-529710-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 72191 invoked by alias); 5 Jul 2016 03:33:58 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 72007 invoked by uid 48); 5 Jul 2016 03:33:42 -0000
From: "heresy-me at hotmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/71764] compiler internal error: segmentation fault
Date: Tue, 05 Jul 2016 03:33:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 5.4.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: heresy-me at hotmail dot com
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71764-4-sgaiSwlCho@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71764-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71764-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00293.txt.bz2
Content-length: 1712

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71764

--- Comment #1 from 鍾 <heresy-me at hotmail dot com> ---
$ uname -a
CYGWIN_NT-6.1 LLVM 2.5.2(0.297/5/3) 2016-06-23 14:29 x86_64 Cygwin
$ gcc -v
使用内建 specs。
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/lto-wrapper.exe
目标:x86_64-pc-cygwin
配置为:/cygdrive/i/szsz/tmpp/gcc/gcc-5.4.0-1.x86_64/src/gcc-5.4.0/configure
--srcdir=/cygdrive/i/szsz/tmpp/gcc/gcc-5.4.0-1.x86_64/src/gcc-5.4.0
--prefix=/usr --exec-prefix=/usr --localstatedir=/var --sysconfdir=/etc
--docdir=/usr/share/doc/gcc --htmldir=/usr/share/doc/gcc/html -C
--build=x86_64-pc-cygwin --host=x86_64-pc-cygwin --target=x86_64-pc-cygwin
--without-libiconv-prefix --without-libintl-prefix --libexecdir=/usr/lib
--enable-shared --enable-shared-libgcc --enable-static
--enable-version-specific-runtime-libs --enable-bootstrap --enable-__cxa_atexit
--with-dwarf2 --with-tune=generic
--enable-languages=ada,c,c++,fortran,lto,objc,obj-c++ --enable-graphite
--enable-threads=posix --enable-libatomic --enable-libcilkrts --enable-libgomp
--enable-libitm --enable-libquadmath --enable-libquadmath-support
--enable-libssp --enable-libada --enable-libgcj-sublibs --disable-java-awt
--disable-symvers --with-ecj-jar=/usr/share/java/ecj.jar --with-gnu-ld
--with-gnu-as --with-cloog-include=/usr/include/cloog-isl
--without-libiconv-prefix --without-libintl-prefix --with-system-zlib
--enable-linker-build-id --with-default-libstdcxx-abi=gcc4-compatible
线程模型:posix
gcc 版本 5.4.0 (GCC)
>From gcc-bugs-return-529711-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 03:50:22 2016
Return-Path: <gcc-bugs-return-529711-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 103648 invoked by alias); 5 Jul 2016 03:50:22 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 103387 invoked by uid 48); 5 Jul 2016 03:49:51 -0000
From: "segher at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/71763] powerpc64: ICE due to need for output reload on jump
Date: Tue, 05 Jul 2016 03:50:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: target
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: segher at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71763-4-6m9gkcwwxZ@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71763-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71763-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00294.txt.bz2
Content-length: 256

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71763

--- Comment #2 from Segher Boessenkool <segher at gcc dot gnu.org> ---
Well.  Here it is using a vector register (v31) as the iterator reg,
which we do not handle.  Should we?  Where does it come from?
>From gcc-bugs-return-529712-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 05:05:53 2016
Return-Path: <gcc-bugs-return-529712-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 92679 invoked by alias); 5 Jul 2016 05:05:52 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 92496 invoked by uid 48); 5 Jul 2016 05:05:40 -0000
From: "trippels at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug ipa/71190] [7 Regression] ICE in assemble_variable_contents, at varasm.c:2054
Date: Tue, 05 Jul 2016 05:05:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: ipa
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: ice-on-valid-code, lto
X-Bugzilla-Severity: normal
X-Bugzilla-Who: trippels at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 7.0
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71190-4-rxxVUoYlzA@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71190-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71190-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00295.txt.bz2
Content-length: 628

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71190

--- Comment #6 from Markus Trippelsdorf <trippels at gcc dot gnu.org> ---
OK. I've given up on reducing.

Honza, you can find the unreduced testcase on gcc112 in
/home/trippels/lto_ice_testcase :

trippels@gcc2-power8 lto_ice_testcase % ~/gcc_test/usr/local/bin/c++ -w
-flto=60 -flto-partition=max -ffunction-sections -fdata-sections
-fno-exceptions -fno-strict-aliasing -fno-rtti -fno-exceptions -fno-math-errno
-std=gnu++0x -pthread -pipe -O3 -fomit-frame-pointer -fPIC -shared *.ii
lto1: internal compiler error: in assemble_variable_contents, at varasm.c:2065
>From gcc-bugs-return-529713-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 05:15:58 2016
Return-Path: <gcc-bugs-return-529713-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 124453 invoked by alias); 5 Jul 2016 05:15:57 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 124316 invoked by uid 48); 5 Jul 2016 05:15:43 -0000
From: "gerhard.steinmetz.fortran@t-online.de" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/71758] ICE in verify_gimple_in_cfg, at tree-cfg.c:5212
Date: Tue, 05 Jul 2016 05:15:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: gerhard.steinmetz.fortran@t-online.de
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71758-4-GZIT8Gd7bJ@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71758-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71758-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00296.txt.bz2
Content-length: 1197

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71758

--- Comment #2 from Gerhard Steinmetz <gerhard.steinmetz.fortran@t-online.de> ---
Reduced to mismatch in device(.), without option -fdefault* :


$ cat z1.f90
program p
  use omp_lib, only: omp_is_initial_device
  integer(8), parameter :: n = 10
  integer(8) :: i
  logical(8) :: offload(N)
  !$omp parallel do
  do i = 1, n
    !$omp target device(i-1) map(from: offload(i:i))
      offload(i) = omp_is_initial_device ()
    !$omp end target
  end do
end program


$ gfortran-6 -fopenmp z1.f90


$ gfortran-7-20160703 -fopenmp z1.f90
z1.f90:2:0:

   use omp_lib, only: omp_is_initial_device

Error: invalid argument to gimple call
(integer(kind=4)) D.3548
__builtin_GOMP_target_ext ((integer(kind=4)) D.3548, MAIN__._omp_fn.1, 3,
&.omp_data_arr.5, &.omp_data_sizes.6, &.omp_data_kinds.7, 0, 0B,
&.omp_target_args.9);
z1.f90:2:0: internal compiler error: verify_gimple failed
0xc51336 verify_gimple_in_cfg(function*, bool)
        ../../gcc/tree-cfg.c:5212
0xb41283 execute_function_todo
        ../../gcc/passes.c:1964
0xb41aed do_per_function
        ../../gcc/passes.c:1655
0xb41c3b execute_todo
        ../../gcc/passes.c:2016
>From gcc-bugs-return-529714-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 07:18:00 2016
Return-Path: <gcc-bugs-return-529714-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 45205 invoked by alias); 5 Jul 2016 07:18:00 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 45083 invoked by uid 48); 5 Jul 2016 07:17:47 -0000
From: "su at cs dot ucdavis.edu" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/71765] New: incorrectly accepts invalid C++ code that invokes base class constructor
Date: Tue, 05 Jul 2016 07:18:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: su at cs dot ucdavis.edu
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone
Message-ID: <bug-71765-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00297.txt.bz2
Content-length: 1520

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71765

            Bug ID: 71765
           Summary: incorrectly accepts invalid C++ code that invokes base
                    class constructor
           Product: gcc
           Version: 7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: su at cs dot ucdavis.edu
  Target Milestone: ---

Please see: 

https://llvm.org/bugs/show_bug.cgi?id=28408

in particular, Richard Smith's comment. 


$ g++-trunk -v
Using built-in specs.
COLLECT_GCC=g++-trunk
COLLECT_LTO_WRAPPER=/usr/local/gcc-trunk/libexec/gcc/x86_64-pc-linux-gnu/7.0.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: ../gcc-source-trunk/configure --enable-languages=c,c++,lto
--prefix=/usr/local/gcc-trunk --disable-bootstrap
Thread model: posix
gcc version 7.0.0 20160704 (experimental) [trunk revision 237986] (GCC) 
$ 
$ g++-trunk -c -Wall -Wextra -pedantic -std=c++98 good.cpp
$ 
$ clang++-3.8 -c good.cpp
good.cpp:14:7: error: destructor type 'A' in object destruction expression does
not match the type 'B' of the
      object being destroyed
  b->~A (); 
      ^
good.cpp:1:8: note: type 'A' is declared here
struct A 
       ^
1 error generated.
$ 
$ cat good.cpp
struct A 
{
  virtual ~A () {}
};

struct B : public A 
{
  virtual ~B () {} 
};

void foo ()
{
  B *b = new B;
  b->~A (); 
  // but okay: b->A::~A(); 
}
>From gcc-bugs-return-529715-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 07:37:32 2016
Return-Path: <gcc-bugs-return-529715-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 38214 invoked by alias); 5 Jul 2016 07:37:32 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 38069 invoked by uid 48); 5 Jul 2016 07:37:19 -0000
From: "ibuclaw at gdcproject dot org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug middle-end/71762] [4.9 Regression] ifcombine wrong codegen with uninitialized data
Date: Tue, 05 Jul 2016 07:37:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: middle-end
X-Bugzilla-Version: 4.9.4
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: ibuclaw at gdcproject dot org
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71762-4-puroYksuj6@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71762-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71762-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00298.txt.bz2
Content-length: 788

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71762

--- Comment #1 from Iain Buclaw <ibuclaw at gdcproject dot org> ---
Backporting r217638 to gcc-4.9 fixes the problem too.

Allowing propagation of __cond60 and __cond59 comparisons into comparisons of
len elides the wrong optimization.

---
__cond60_9 = len_8(D) > 1;
if (__cond60_9 != 0)
  goto <bb 6>;
else
  goto <bb 3>;

<bb 3>:
__cond59_13 = len_8(D) == 1;
if (__cond59_13 != 0)
  goto <bb 4>;
else
  goto <bb 5>;

/* ... */

<bb 9>:
if (__cond60_9 != 0)
  goto <bb 12>;
else
  goto <bb 10>;
---

Becomes:

---
if (len_8(D) > 1)
  goto <bb 6>;
else
  goto <bb 3>;

<bb 3>:
if (len_8(D) == 1)
  goto <bb 4>;
else
  goto <bb 5>;

/* ... */

<bb 9>:
if (len_8(D) <= 1)
  goto <bb 10>;
else
  goto <bb 12>;
---
>From gcc-bugs-return-529716-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 08:36:42 2016
Return-Path: <gcc-bugs-return-529716-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 50682 invoked by alias); 5 Jul 2016 08:36:42 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 50420 invoked by uid 48); 5 Jul 2016 08:36:27 -0000
From: "timo.teras at iki dot fi" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libgcj/71757] libgcj: unknown symbol __cxa_throw_bad_array_new_length
Date: Tue, 05 Jul 2016 08:36:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: libgcj
X-Bugzilla-Version: 6.1.0
X-Bugzilla-Keywords: build
X-Bugzilla-Severity: normal
X-Bugzilla-Who: timo.teras at iki dot fi
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71757-4-5BztTj4Y69@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71757-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71757-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00299.txt.bz2
Content-length: 1922

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71757

--- Comment #9 from Timo Teräs <timo.teras at iki dot fi> ---
Adding the following also works for me:

--- gcc-6.1.0/libjava/Makefile.am
+++ gcc-6.1.0/libjava/Makefile.am
@@ -488,10 +488,14 @@
 nat_files = $(nat_source_files:.cc=.lo)
 xlib_nat_files = $(xlib_nat_source_files:.cc=.lo)

+libgcj_la_CPPFLAGS = \
+        $(AM_CPPFLAGS) \
+        $(LIBSTDCXX_RAW_CXX_CXXFLAGS)
+
 # Include THREADLIBS here to ensure that the correct version of
 # certain linuxthread functions get linked:
 ## The mysterious backslash in the grep pattern is consumed by make.
-libgcj_la_LDFLAGS = -rpath $(toolexeclibdir) $(THREADLDFLAGS) $(extra_ldflags)
$(THREADLIBS) \
+libgcj_la_LDFLAGS = $(LIBSTDCXX_RAW_CXX_LDFLAGS) -rpath $(toolexeclibdir)
$(THREADLDFLAGS) $(extra_ldflags) $(THREADLIBS) \
        $(LIBLTDL) $(SYS_ZLIBS) $(LIBJAVA_LDFLAGS_NOUNDEF) \
        -version-info `grep -v '^\#' $(srcdir)/libtool-version` \
        $(LIBGCJ_LD_SYMBOLIC_FUNCTIONS) $(LIBGCJ_LD_EXPORT_ALL)
--- gcc-6.1.0/libjava/Makefile.in
+++ gcc-6.1.0/libjava/Makefile.in
@@ -1103,9 +1103,13 @@
 nat_files = $(nat_source_files:.cc=.lo)
 xlib_nat_files = $(xlib_nat_source_files:.cc=.lo)

+libgcj_la_CPPFLAGS = \
+       $(AM_CPPFLAGS) \
+        $(LIBSTDCXX_RAW_CXX_CXXFLAGS)
+
 # Include THREADLIBS here to ensure that the correct version of
 # certain linuxthread functions get linked:
-libgcj_la_LDFLAGS = -rpath $(toolexeclibdir) $(THREADLDFLAGS) $(extra_ldflags)
$(THREADLIBS) \
+libgcj_la_LDFLAGS = $(LIBSTDCXX_RAW_CXX_LDFLAGS) -rpath $(toolexeclibdir)
$(THREADLDFLAGS) $(extra_ldflags) $(THREADLIBS) \
        $(LIBLTDL) $(SYS_ZLIBS) $(LIBJAVA_LDFLAGS_NOUNDEF) \
        -version-info `grep -v '^\#' $(srcdir)/libtool-version` \
        $(LIBGCJ_LD_SYMBOLIC_FUNCTIONS) $(LIBGCJ_LD_EXPORT_ALL)

After this the proper .so dependency is picked up for libstdc++.
>From gcc-bugs-return-529717-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 09:16:03 2016
Return-Path: <gcc-bugs-return-529717-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 32192 invoked by alias); 5 Jul 2016 09:16:03 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 31229 invoked by uid 48); 5 Jul 2016 09:15:50 -0000
From: "d.v.a at ngs dot ru" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/71214] Typo in feature test macro for rvalue references
Date: Tue, 05 Jul 2016 09:16:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 4.9.2
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: d.v.a at ngs dot ru
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: cc
Message-ID: <bug-71214-4-qsDfUioYWU@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71214-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71214-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00300.txt.bz2
Content-length: 366

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71214

__vic <d.v.a at ngs dot ru> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |d.v.a at ngs dot ru

--- Comment #1 from __vic <d.v.a at ngs dot ru> ---
The same in GCC 6.1
>From gcc-bugs-return-529718-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 09:49:24 2016
Return-Path: <gcc-bugs-return-529718-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 18231 invoked by alias); 5 Jul 2016 09:49:23 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 18071 invoked by uid 48); 5 Jul 2016 09:49:11 -0000
From: "redi at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/71765] incorrectly accepts invalid C++ code that invokes base class constructor
Date: Tue, 05 Jul 2016 09:49:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: accepts-invalid
X-Bugzilla-Severity: normal
X-Bugzilla-Who: redi at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: keywords bug_status cf_reconfirmed_on everconfirmed
Message-ID: <bug-71765-4-whf3uCuEL1@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71765-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71765-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00301.txt.bz2
Content-length: 1065

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71765

Jonathan Wakely <redi at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |accepts-invalid
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2016-07-05
     Ever confirmed|0                           |1

--- Comment #1 from Jonathan Wakely <redi at gcc dot gnu.org> ---
From the clang bug report:

[basic.lookup.classref]p3 says:

"If the unqualified-id is ~type-name, the type-name is looked up in the context
of the entire postfix-expression. If the type T of the object expression is of
a class type C, the type-name is also looked up in the scope of class C. At
least one of the lookups shall find a name that refers to (possibly
cv-qualified) T."

So Richard is right that we should reject it, because lookup for ~A finds the
type-name A, but that doesn't refer to B, so it's ill-formed.
>From gcc-bugs-return-529719-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 09:50:59 2016
Return-Path: <gcc-bugs-return-529719-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 50694 invoked by alias); 5 Jul 2016 09:50:58 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 50536 invoked by uid 48); 5 Jul 2016 09:50:45 -0000
From: "redi at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/71755] friend function may not be defined inside a class using a qualified name but GCC allows that
Date: Tue, 05 Jul 2016 09:50:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 6.1.0
X-Bugzilla-Keywords: accepts-invalid
X-Bugzilla-Severity: minor
X-Bugzilla-Who: redi at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: keywords bug_status cf_reconfirmed_on everconfirmed
Message-ID: <bug-71755-4-xpPQjJHr1t@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71755-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71755-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00302.txt.bz2
Content-length: 467

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71755

Jonathan Wakely <redi at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |accepts-invalid
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2016-07-05
     Ever confirmed|0                           |1
>From gcc-bugs-return-529720-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 09:59:42 2016
Return-Path: <gcc-bugs-return-529720-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 16369 invoked by alias); 5 Jul 2016 09:59:41 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 16262 invoked by uid 48); 5 Jul 2016 09:59:29 -0000
From: "trippels at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/71214] Typo in feature test macro for rvalue references
Date: Tue, 05 Jul 2016 09:59:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 4.9.2
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: trippels at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: trippels at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_status cf_reconfirmed_on cc assigned_to everconfirmed
Message-ID: <bug-71214-4-Q6yLBAncIh@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71214-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71214-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00303.txt.bz2
Content-length: 680

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71214

Markus Trippelsdorf <trippels at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2016-07-05
                 CC|                            |trippels at gcc dot gnu.org
           Assignee|unassigned at gcc dot gnu.org      |trippels at gcc dot gnu.org
     Ever confirmed|0                           |1

--- Comment #2 from Markus Trippelsdorf <trippels at gcc dot gnu.org> ---
Confirmed. I will post a patch.
>From gcc-bugs-return-529721-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 12:07:08 2016
Return-Path: <gcc-bugs-return-529721-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 41993 invoked by alias); 5 Jul 2016 12:07:08 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 41812 invoked by uid 55); 5 Jul 2016 12:06:54 -0000
From: "vehre at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/71623] [5/6/7 Regression] Segfault when allocating deferred-length characters to size of a pointer
Date: Tue, 05 Jul 2016 12:07:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 6.1.1
X-Bugzilla-Keywords: wrong-code
X-Bugzilla-Severity: normal
X-Bugzilla-Who: vehre at gcc dot gnu.org
X-Bugzilla-Status: WAITING
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P4
X-Bugzilla-Assigned-To: vehre at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 5.5
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71623-4-g0diX03Us1@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71623-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71623-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00304.txt.bz2
Content-length: 808

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71623

--- Comment #6 from vehre at gcc dot gnu.org ---
Author: vehre
Date: Tue Jul  5 12:06:22 2016
New Revision: 238002

URL: https://gcc.gnu.org/viewcvs?rev=238002&root=gcc&view=rev
Log:
gcc/fortran/ChangeLog:

2016-07-05  Andre Vehreschild  <vehre@gcc.gnu.org>

        PR fortran/71623
        * trans-stmt.c (gfc_trans_allocate): Add code of pre block of typespec
        in allocate to parent block.

gcc/testsuite/ChangeLog:

2016-07-05  Andre Vehreschild  <vehre@gcc.gnu.org>

        PR fortran/71623
        * gfortran.dg/deferred_character_17.f90: New test.



Added:
    trunk/gcc/testsuite/gfortran.dg/deferred_character_17.f90
Modified:
    trunk/gcc/fortran/ChangeLog
    trunk/gcc/fortran/trans-stmt.c
    trunk/gcc/testsuite/ChangeLog
>From gcc-bugs-return-529722-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 12:11:16 2016
Return-Path: <gcc-bugs-return-529722-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 58354 invoked by alias); 5 Jul 2016 12:11:16 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 58243 invoked by uid 48); 5 Jul 2016 12:11:03 -0000
From: "vehre at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/71623] [5/6/7 Regression] Segfault when allocating deferred-length characters to size of a pointer
Date: Tue, 05 Jul 2016 12:11:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 6.1.1
X-Bugzilla-Keywords: wrong-code
X-Bugzilla-Severity: normal
X-Bugzilla-Who: vehre at gcc dot gnu.org
X-Bugzilla-Status: WAITING
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P4
X-Bugzilla-Assigned-To: vehre at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 5.5
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71623-4-byJZS8h64d@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71623-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71623-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00305.txt.bz2
Content-length: 179

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71623

--- Comment #7 from vehre at gcc dot gnu.org ---
Waiting one week for regressions to pop up before applying to gcc-6 and -5.
>From gcc-bugs-return-529723-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 12:28:13 2016
Return-Path: <gcc-bugs-return-529723-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 101861 invoked by alias); 5 Jul 2016 12:28:13 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 100189 invoked by uid 48); 5 Jul 2016 12:28:01 -0000
From: "goswin-v-b at web dot de" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/66960] Add interrupt attribute to x86 backend
Date: Tue, 05 Jul 2016 12:28:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: target
X-Bugzilla-Version: 6.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: enhancement
X-Bugzilla-Who: goswin-v-b at web dot de
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 6.2
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-66960-4-spea30qan8@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-66960-4@http.gcc.gnu.org/bugzilla/>
References: <bug-66960-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00306.txt.bz2
Content-length: 1317

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66960

--- Comment #15 from Goswin von Brederlow <goswin-v-b at web dot de> ---
(In reply to H.J. Lu from comment #14)
> (In reply to Goswin von Brederlow from comment #13)
> > > > Secondly why pass error_code as argument if is already on the stack and
> > > > could be accessed through the frame pointer? The argument register (amd64)
> > > > would have to be saved on the stack too causing an extra push/pop. But if it
> > > > is passed as argument then why not pop it before the call to keep the stack
> > > > frame the same as for interrupts (assuming the saved registers are not
> > > > included in the frame)?
> > > 
> > > error_code is a pseudo parameter, which is mapped to error code on stack
> > > pushed by CPU.  You can write a simple code to see it yourself.
> > 
> > Couldn't the same trick be used for registers? Pass them as pseudo
> > parameters and they either resolve to the location on the stack where gcc
> > did save them or become the original register unchanged.
> 
> No.  We only do it for data pushed onto stack by CPU.

I was thinking of something like:

__attribute__ ((interrupt("save_regs")))
void
f (struct interrupt_frame *frame, uword_t error_code, struct regs regs)
{
    kprintf("user SP = %#016x\n", regs.sp);
}
>From gcc-bugs-return-529724-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 12:55:38 2016
Return-Path: <gcc-bugs-return-529724-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 50202 invoked by alias); 5 Jul 2016 12:55:37 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 50065 invoked by uid 48); 5 Jul 2016 12:55:25 -0000
From: "segher at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/71763] powerpc64: ICE due to need for output reload on jump
Date: Tue, 05 Jul 2016 12:55:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: target
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: segher at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: cf_gcctarget
Message-ID: <bug-71763-4-1kQgZU3K3a@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71763-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71763-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00307.txt.bz2
Content-length: 439

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71763

Segher Boessenkool <segher at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Target|powerpc64le-linux           |powerpc64*-linux

--- Comment #3 from Segher Boessenkool <segher at gcc dot gnu.org> ---
Testcase needs -O1 -mvsx -m64; fails on BE just the same.
>From gcc-bugs-return-529725-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 12:57:37 2016
Return-Path: <gcc-bugs-return-529725-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 76644 invoked by alias); 5 Jul 2016 12:57:37 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 64051 invoked by uid 48); 5 Jul 2016 12:57:24 -0000
From: "izamyatin at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/71088] [i386, AVX-512, Perf] vpermi2ps instead of vpermps emitted
Date: Tue, 05 Jul 2016 12:57:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: target
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: izamyatin at gmail dot com
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71088-4-UtKH9aB8Uo@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71088-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71088-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00308.txt.bz2
Content-length: 138

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71088

--- Comment #1 from Igor Zamyatin <izamyatin at gmail dot com> ---
Fixed by r237982
>From gcc-bugs-return-529726-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 13:04:54 2016
Return-Path: <gcc-bugs-return-529726-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 114704 invoked by alias); 5 Jul 2016 13:04:54 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 114549 invoked by uid 48); 5 Jul 2016 13:04:41 -0000
From: "amodra at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/71763] powerpc64: ICE due to need for output reload on jump
Date: Tue, 05 Jul 2016 13:04:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: target
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: amodra at gmail dot com
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: attachments.created
Message-ID: <bug-71763-4-Y1qgjAEU25@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71763-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71763-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00309.txt.bz2
Content-length: 350

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71763

--- Comment #4 from Alan Modra <amodra at gmail dot com> ---
Created attachment 38833
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=38833&action=edit
output reloads on jump insns

Revised https://gcc.gnu.org/ml/gcc-patches/2004-12/msg00739.html
It's surprising how little has changed.
>From gcc-bugs-return-529727-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 13:10:23 2016
Return-Path: <gcc-bugs-return-529727-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 11504 invoked by alias); 5 Jul 2016 13:10:22 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 11361 invoked by uid 48); 5 Jul 2016 13:10:10 -0000
From: "segher at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/71763] powerpc64: ICE due to need for output reload on jump
Date: Tue, 05 Jul 2016 13:10:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: target
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: segher at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71763-4-kMJ0yUtjmT@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71763-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71763-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00310.txt.bz2
Content-length: 304

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71763

--- Comment #5 from Segher Boessenkool <segher at gcc dot gnu.org> ---
Actually, needs -mcpu=power8 as well, otherwise we get another ICE (we need
direct moves for FP regs in the ctr patterns; this is the case that is not
yet solved in PR70098).
>From gcc-bugs-return-529728-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 13:20:39 2016
Return-Path: <gcc-bugs-return-529728-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 27006 invoked by alias); 5 Jul 2016 13:20:39 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 26822 invoked by uid 48); 5 Jul 2016 13:20:31 -0000
From: "ch3root at openwall dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: =?UTF-8?B?W0J1ZyBjLzcxNzY2XSBOZXc6IFN0cmFuZ2UgcG9zaXRpb24gb2YgImVycm9y?= =?UTF-8?B?OiByZXF1ZXN0IGZvciBtZW1iZXIg4oCYLi4u4oCZIGluIHNvbWV0aGluZyBu?= =?UTF-8?B?b3QgYSBzdHJ1Y3R1cmUgb3IgdW5pb24i?Date: Tue, 05 Jul 2016 13:20:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: ch3root at openwall dot com
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone
Message-ID: <bug-71766-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00311.txt.bz2
Content-length: 1862

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71766

            Bug ID: 71766
           Summary: Strange position of "error: request for member ‘...’
                    in something not a structure or union"
           Product: gcc
           Version: 7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: ch3root at openwall dot com
  Target Milestone: ---

Only the first letter of 'offsetof' is shown in another color for the following
testcase.

Source code:

----------------------------------------------------------------------
#include <stddef.h>

int main()
{
  +offsetof(int, a);
}
----------------------------------------------------------------------

Results:

----------------------------------------------------------------------
$ gcc -std=c11 -pedantic -Wall -Wextra -O3 test.c && ./a.out
In file included from test.c:1:0:
test.c: In function ‘main’:
test.c:5:4: error: request for member ‘a’ in something not a structure or union
   +offsetof(int, a);
    ^
----------------------------------------------------------------------

gcc version: gcc (GCC) 7.0.0 20160704 (experimental)


For comparison:

----------------------------------------------------------------------
$ clang -std=c11 -Weverything -O3 test.c && ./a.out
test.c:5:4: error: offsetof requires struct, union, or class type, 'int'
invalid
  +offsetof(int, a);
   ^        ~~~
.../lib/clang/3.9.0/include/stddef.h:120:24: note: expanded from macro
'offsetof'
#define offsetof(t, d) __builtin_offsetof(t, d)
                       ^                  ~
1 error generated.
----------------------------------------------------------------------

clang version: clang version 3.9.0 (trunk 274502)
>From gcc-bugs-return-529729-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 13:27:19 2016
Return-Path: <gcc-bugs-return-529729-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 44218 invoked by alias); 5 Jul 2016 13:27:18 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 43187 invoked by uid 48); 5 Jul 2016 13:27:06 -0000
From: "asolokha at gmx dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug rtl-optimization/71621] [7 Regression] ICE in assign_by_spills, at lra-assigns.c:1417 (error: unable to find a register to spill) w/ -O2 -mavx2 -ftree-vectorize
Date: Tue, 05 Jul 2016 13:27:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: rtl-optimization
X-Bugzilla-Version: 7.0
X-Bugzilla-Keywords: ice-on-valid-code, ra
X-Bugzilla-Severity: normal
X-Bugzilla-Who: asolokha at gmx dot com
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 7.0
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-71621-4-pzxXwZD5HZ@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71621-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71621-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00312.txt.bz2
Content-length: 1095

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71621

--- Comment #2 from Arseny Solokha <asolokha at gmx dot com> ---
Another one, just for the record:

int hf, sv, zz, aj;

void
dn (int xb, int bl)
{
  while (zz < 1)
  {
    if (xb == 0)
      goto mr;

    while (bl < 3)
    {
      int d3;
      unsigned char vh;
      unsigned char *fj = &vh;

 mr:
      while (bl < 1)
      {
        hf += vh;
        ++bl;
      }
      if (xb == 0)
        zz = bl;
      if (d3 == 0)
        return;
      while (sv < 1)
      {
        --vh;
        aj += vh;
        ++sv;
      }
    }
    sv = 0;
  }
}

% x86_64-pc-linux-gnu-gcc-7.0.0-alpha20160703 -c -mavx2 -O3 md4gkoj3.c
md4gkoj3.c: In function 'dn':
md4gkoj3.c:36:1: error: unable to find a register to spill
 }
 ^
md4gkoj3.c:36:1: error: this is the insn:
(insn 93 571 35 3 (set (reg:V32QI 172 [ vect_cst__257 ])
        (vec_duplicate:V32QI (reg:QI 330))) 4215 {*vec_dupv32qi}
     (expr_list:REG_DEAD (reg:QI 330)
        (nil)))
md4gkoj3.c:36:1: internal compiler error: in assign_by_spills, at
lra-assigns.c:1417
>From gcc-bugs-return-529730-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 13:57:05 2016
Return-Path: <gcc-bugs-return-529730-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 53065 invoked by alias); 5 Jul 2016 13:57:05 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 52563 invoked by uid 48); 5 Jul 2016 13:56:52 -0000
From: "hjl.tools at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/66960] Add interrupt attribute to x86 backend
Date: Tue, 05 Jul 2016 13:57:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: target
X-Bugzilla-Version: 6.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: enhancement
X-Bugzilla-Who: hjl.tools at gmail dot com
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 6.2
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-66960-4-goA2MopAhb@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-66960-4@http.gcc.gnu.org/bugzilla/>
References: <bug-66960-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00313.txt.bz2
Content-length: 754

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66960

--- Comment #16 from H.J. Lu <hjl.tools at gmail dot com> ---
(In reply to Goswin von Brederlow from comment #15)

> > No.  We only do it for data pushed onto stack by CPU.
> 
> I was thinking of something like:
> 
> __attribute__ ((interrupt("save_regs")))
> void
> f (struct interrupt_frame *frame, uword_t error_code, struct regs regs)
> {
>     kprintf("user SP = %#016x\n", regs.sp);
> }

It is an interesting idea.  But frame and err_code are created by caller,
which is CPU, not by callee.  You want to not only save all original
registers of interrupted process, but also make them available to interrupt
handler.  This won't be supported without significant changes in
infrastructure.
>From gcc-bugs-return-529731-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 14:07:41 2016
Return-Path: <gcc-bugs-return-529731-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 100188 invoked by alias); 5 Jul 2016 14:07:41 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 75396 invoked by uid 48); 5 Jul 2016 14:07:29 -0000
From: "rguenth at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug middle-end/71762] [4.9/5/6/7 Regression] ifcombine wrong codegen with uninitialized data
Date: Tue, 05 Jul 2016 14:07:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: middle-end
X-Bugzilla-Version: 4.9.4
X-Bugzilla-Keywords: wrong-code
X-Bugzilla-Severity: normal
X-Bugzilla-Who: rguenth at gcc dot gnu.org
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 4.9.4
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: keywords cc target_milestone short_desc
Message-ID: <bug-71762-4-TT4x6l5HLT@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-71762-4@http.gcc.gnu.org/bugzilla/>
References: <bug-71762-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00314.txt.bz2
Content-length: 809

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71762

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |wrong-code
                 CC|                            |rguenth at gcc dot gnu.org
   Target Milestone|---                         |4.9.4
            Summary|[4.9 Regression] ifcombine  |[4.9/5/6/7 Regression]
                   |wrong codegen with          |ifcombine wrong codegen
                   |uninitialized data          |with uninitialized data

--- Comment #2 from Richard Biener <rguenth at gcc dot gnu.org> ---
I think the issue is probably gone latent only, the revs that "fix" this merely
hide it.
>From gcc-bugs-return-529732-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 15:51:39 2016
Return-Path: <gcc-bugs-return-529732-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 89373 invoked by alias); 5 Jul 2016 15:51:39 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 88842 invoked by uid 55); 5 Jul 2016 15:51:26 -0000
From: "dmalcolm at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/62314] Fix-it Hints
Date: Tue, 05 Jul 2016 15:51:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: unknown
X-Bugzilla-Keywords:
X-Bugzilla-Severity: enhancement
X-Bugzilla-Who: dmalcolm at gcc dot gnu.org
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: dmalcolm at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-62314-4-zSc1PI3ZZQ@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-62314-4@http.gcc.gnu.org/bugzilla/>
References: <bug-62314-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2016-07/txt/msg00315.txt.bz2
Content-length: 1010

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62314

--- Comment #8 from David Malcolm <dmalcolm at gcc dot gnu.org> ---
Author: dmalcolm
Date: Tue Jul  5 15:50:54 2016
New Revision: 238008

URL: https://gcc.gnu.org/viewcvs?rev=238008&root=gcc&view=rev
Log:
PR c++/62314: add fixit hint for "expected ';' after class definition"

gcc/cp/ChangeLog:
        PR c++/62314
        * parser.c (cp_parser_class_specifier_1): When reporting
        missing semicolons, use a fixit-hint to suggest insertion
        of a semicolon immediately after the closing brace,
        offsetting the reported column accordingly.

gcc/testsuite/ChangeLog:
        PR c++/62314
        * gcc/testsuite/g++.dg/parse/error5.C: Update column
        number of missing semicolon error.
        * g++.dg/pr62314-2.C: New test case.


Added:
    trunk/gcc/testsuite/g++.dg/pr62314-2.C
Modified:
    trunk/gcc/cp/ChangeLog
    trunk/gcc/cp/parser.c
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/testsuite/g++.dg/parse/error5.C
>From gcc-bugs-return-529733-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jul 05 15:56:19 2016
Return-Path: <gcc-bugs-return-529733-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 97040 invoked by alias); 5 Jul 2016 15:56:19 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 97021 invoked by uid 89); 5 Jul 2016 15:56:18 -0000
Authentication-Results: sourceware.org; auth=none
X-Virus-Found: No
X-Spam-SWARE-Status: No, score=-2.6 required=5.0 testsºYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 spammy=filecpp, file.cpp, UD:file.cpp, Best
X-HELO: mail-wm0-f43.google.com
Received: from mail-wm0-f43.google.com (HELO mail-wm0-f43.google.com) (74.125.82.43) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-GCM-SHA256 encrypted) ESMTPS; Tue, 05 Jul 2016 15:56:17 +0000
Received: by mail-wm0-f43.google.com with SMTP id a66so158854953wme.0        for <gcc-bugs@gcc.gnu.org>; Tue, 05 Jul 2016 08:56:16 -0700 (PDT)
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;        d\x1e100.net; s 130820;        h=x-gm-message-state:mime-version:reply-to:from:date:message-id         :subject:to;        bh=dNNznByH/xCR+JWZ55C9tdXxw8ZN72PhYVc8spbwkaE=;        b=jb5jXHAnlFQPcC2oI3BgCPbOItgECHzoDfupjUVMxfr3JYRIruGjhe7/vYjW9j9lnU         k0PLv7CStklmGtWTf0Yc7oqes3xLr3op0ox4YmjRbvO4vwAsKnwLIXo9oeUCuM59rg6d         Zdhapn9PN29C9AgR1ClsQk2A3d00iSFqOfvu2xgqVK0QpIXOsaUKp2DcOMcxN5OnUYyU         Sv08YkIlHnStTvtenHpJXK1Yim0JDrulc3CKl7uqHoAzSisg90MM8utNefQ81LoJhbnK         7LU2HafvtKt9SSRUzZpxq9ntN6+qvp7c5/3g/1qjVJblMdbfw8L5OpJHz4ItjpXv06Az         Da4g=X-Gm-Message-State: ALyK8tIQ9sK/jwcug2q9bq3ZApLONM7wW8pouzvsmJKUPMwzOz0aWJhozzpFKKid8pXySUe+7TUXtxBjrv2plA=X-Received: by 10.194.110.234 with SMTP id id10mr15989184wjb.17.1467734173823; Tue, 05 Jul 2016 08:56:13 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.28.67.5 with HTTP; Tue, 5 Jul 2016 08:56:13 -0700 (PDT)
Reply-To: ronnybrendel@gmail.com
From: Ronny Brendel <ronnybrendel@gmail.com>
Date: Tue, 05 Jul 2016 15:56:00 -0000
Message-ID: <CAD_uPkCWFrT8gWMpmMozpRHAOMF6WOUQ6r9VTHPs6oLxbvBcqQ@mail.gmail.com>
Subject: Missing support for demangling lambdas with auto paramters in libbfd
To: gcc-bugs@gcc.gnu.org
Content-Type: text/plain; charset=UTF-8
X-SW-Source: 2016-07/txt/msg00316.txt.bz2
Content-length: 777

Hi gcc-developers and -users,

#include <iostream>
using namespace std;
int main() {

    auto my_lambda = [](auto i) {
        cout << "asdf\n" << i;
    };

    auto my_lambda2 = [](int i) {
        cout << "asdf\n" << i;
    };

    my_lambda(1);
    my_lambda(2.0);
    my_lambda2(3);

    return 0;
}

$ g++ --std=c++14 file.cpp

In this example the mangled names for the lamdbas are:

_ZZ4mainENKUliE0_clEi               <- int
_ZZ4mainENKUlT_E_clIdEEDaS_  <- auto : double
_ZZ4mainENKUlT_E_clIiEEDaS_   <- auto : int

c++filt and libbfd are unable to demangle the last two: (binutils
version 2.26 on Kubuntu 16.04, GCC version: gcc (Ubuntu
5.3.1-14ubuntu2.1) 5.3.1 20160413)

(lambdas with auto parameters is a c++14 feature)

Thanks for your help.
Best regards,
Ronny


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug target/66960] Add interrupt attribute to x86 backend
  2015-07-21 17:07 [Bug middle-end/66960] New: Add a builtin to get the address of the current stack frame hjl.tools at gmail dot com
                   ` (3 preceding siblings ...)
  2016-07-04 10:39 ` [Bug target/66960] Add interrupt " goswin-v-b at web dot de
@ 2021-08-10 21:37 ` pinskia at gcc dot gnu.org
  4 siblings, 0 replies; 6+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-08-10 21:37 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66960

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |christian.gnu at juner dot de

--- Comment #22 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
*** Bug 50187 has been marked as a duplicate of this bug. ***

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2021-08-10 21:37 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-07-21 17:07 [Bug middle-end/66960] New: Add a builtin to get the address of the current stack frame hjl.tools at gmail dot com
2015-07-21 21:46 ` [Bug target/66960] " hjl.tools at gmail dot com
2015-09-04 15:48 ` [Bug target/66960] Need a builtin function to access interrupt or exception data hjl.tools at gmail dot com
2015-09-29 22:17 ` [Bug target/66960] Add interrupt/exception attribute to x86 backend hjl.tools at gmail dot com
2016-07-04 10:39 ` [Bug target/66960] Add interrupt " goswin-v-b at web dot de
2021-08-10 21:37 ` pinskia at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).