[Bug c/78732] New: Wrong description for Wendif-labels

2016-12-08 Thread fmarchal at perso dot be
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78732

Bug ID: 78732
   Summary: Wrong description for Wendif-labels
   Product: gcc
   Version: 6.2.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c
  Assignee: unassigned at gcc dot gnu.org
  Reporter: fmarchal at perso dot be
  Target Milestone: ---

In file gcc/c-family/c.opt, at line 421, the description for Wendif-labels is

"Warn about stray tokens after #elif and #endif."

I believe the message is about #else and #endif instead of #elif. Tokens are
expected after #elif.

[Bug target/78694] [ARM] ICE with -mthumb -ftls-model=local-exec -O2

2016-12-08 Thread sebastian.hu...@embedded-brains.de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78694

--- Comment #9 from Sebastian Huber  ---
I did a fresh git clone today on gcc113 of the GCC compile farm. I built an
arm-linux-gnueabihf GCC:

./install/bin/arm-linux-gnueabihf-gcc --version --verbose
Using built-in specs.
COLLECT_GCC=./install/bin/arm-linux-gnueabihf-gcc
COLLECT_LTO_WRAPPER=/home/sh/install/libexec/gcc/arm-linux-gnueabihf/7.0.0/lto-wrapper
arm-linux-gnueabihf-gcc (GCC) 7.0.0 20161208 (experimental) [trunk revision
5b2a614:e5a02c3:beea0800baadbe98febe5a4e54112d76ea10a9d3]
Copyright (C) 2016 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.


Target: arm-linux-gnueabihf
Configured with: ../gcc/configure --prefix=/home/sh/install
--target=arm-linux-gnueabihf --disable-multilib --enable-languages=c
Thread model: posix
gcc version 7.0.0 20161208 (experimental) [trunk revision
5b2a614:e5a02c3:beea0800baadbe98febe5a4e54112d76ea10a9d3] (GCC) 
COLLECT_GCC_OPTIONS='--version' '-v' '-mtls-dialect=gnu'
 /home/sh/install/libexec/gcc/arm-linux-gnueabihf/7.0.0/cc1 -quiet -v
help-dummy -quiet -dumpbase help-dummy -mtls-dialect=gnu -auxbase help-dummy
-version --version -o /tmp/ccDBeQFm.s
GNU C11 (GCC) version 7.0.0 20161208 (experimental) [trunk revision
5b2a614:e5a02c3:beea0800baadbe98febe5a4e54112d76ea10a9d3] (arm-linux-gnueabihf)
compiled by GNU C version 4.8.4, GMP version 5.1.3, MPFR version
3.1.2-p3, MPC version 1.0.1, isl version none
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
COLLECT_GCC_OPTIONS='--version' '-v' '-mtls-dialect=gnu'
 as -v -meabi=5 --version -o /tmp/cc6waYtC.o /tmp/ccDBeQFm.s
GNU assembler version 2.24 (aarch64-linux-gnu) using BFD version (GNU Binutils
for Ubuntu) 2.24
Assembler messages:
Error: unrecognized option -meabi=5

I get:

./install/bin/arm-linux-gnueabihf-gcc -S task.i -mthumb -O2
-ftls-model=local-exec
/home/EB/sebastian_h/archive/gcc-git/libgomp/task.c: In function
‘gomp_create_target_task’:
/home/EB/sebastian_h/archive/gcc-git/libgomp/task.c:778:1: error: invalid rtl
sharing found in the insn
(insn 1569 1568 1570 (unspec_volatile [
(const:SI (unspec:SI [
(symbol_ref:SI ("gomp_tls_data") [flags 0xea] )
(const_int 4 [0x4])
] UNSPEC_TLS))
] VUNSPEC_POOL_4) -1
 (nil))
/home/EB/sebastian_h/archive/gcc-git/libgomp/task.c:778:1: error: shared rtx
(const:SI (unspec:SI [
(symbol_ref:SI ("gomp_tls_data") [flags 0xea] )
(const_int 4 [0x4])
] UNSPEC_TLS))
/home/EB/sebastian_h/archive/gcc-git/libgomp/task.c:778:1: internal compiler
error: internal consistency failure
0x7beabf verify_rtx_sharing
../../gcc/gcc/emit-rtl.c:2752
0x7bea1b verify_rtx_sharing
../../gcc/gcc/emit-rtl.c:2785
0x7bef07 verify_insn_sharing
../../gcc/gcc/emit-rtl.c:2838
0x7c3cfb verify_rtl_sharing()
../../gcc/gcc/emit-rtl.c:2861
0xa56e2f execute_function_todo
../../gcc/gcc/passes.c:1982
0xa5770f do_per_function
../../gcc/gcc/passes.c:1649
0xa578c7 execute_todo
../../gcc/gcc/passes.c:2015
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.

[Bug bootstrap/78733] New: [7 Regression] bootstrap broken on aarch64-linux-gnu

2016-12-08 Thread doko at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78733

Bug ID: 78733
   Summary: [7 Regression] bootstrap broken on aarch64-linux-gnu
   Product: gcc
   Version: 7.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: bootstrap
  Assignee: unassigned at gcc dot gnu.org
  Reporter: doko at gcc dot gnu.org
  Target Milestone: ---

trunk 20161207 fails to build on aarch64-linux-gnu in libgfortran (binutils
trunk 20161202 is used for the build):

/tmp/ccEfI0qj.s: Assembler messages:
/tmp/ccEfI0qj.s:194: Error: invalid addressing mode at operand 3 -- `ldp
x8,x9,.LC0'
/tmp/ccEfI0qj.s:1305: Error: invalid addressing mode at operand 3 -- `ldp
x10,x11,.LC9'
Makefile:2982: recipe for target 'maxval_i16.lo' failed
make[5]: *** [maxval_i16.lo] Error 1

configured as -enable-languages=c,ada,c++,go,fortran,objc,obj-c++
--prefix=/usr/lib/gcc-snapshot --program-prefix= --enable-shared
--enable-linker-build-id  --disable-nls --with-sysroot=/ --enable-clocale=gnu
--enable-libstdcxx-debug --enable-libstdcxx-time=yes
--with-default-libstdcxx-abi=new --enable-gnu-unique-object
--disable-libquadmath --enable-plugin --with-system-zlib --enable-multiarch
--enable-fix-cortex-a53-843419 --disable-werror --enable-checking=yes
--build=aarch64-linux-gnu --host=aarch64-linux-gnu --target=aarch64-linux-gnu

[Bug target/78733] [7 Regression] bootstrap broken on aarch64-linux-gnu

2016-12-08 Thread pinskia at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78733

--- Comment #2 from Andrew Pinski  ---
I don't see it in my last build
https://gcc.gnu.org/ml/gcc-testresults/2016-12/msg00866.html

[Bug target/78733] [7 Regression] bootstrap broken on aarch64-linux-gnu

2016-12-08 Thread pinskia at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78733

Andrew Pinski  changed:

   What|Removed |Added

   Keywords||assemble-failure, build
  Component|bootstrap   |target
   Target Milestone|--- |7.0

--- Comment #1 from Andrew Pinski  ---
Ihttps://gcc.gnu.org/ml/gcc-testresults/2016-12/msg00866.html

[Bug fortran/59997] c_pointer = c_loc(...) internal compiler error

2016-12-08 Thread janus at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59997

janus at gcc dot gnu.org changed:

   What|Removed |Added

 Status|WAITING |RESOLVED
  Known to work||4.9.4
 Resolution|--- |FIXED
   Target Milestone|--- |4.9.0
  Known to fail||4.7.4, 4.8.5

--- Comment #10 from janus at gcc dot gnu.org ---
(In reply to kargl from comment #9)
> The original code in comment #1 compiles and executes.

... with everything from 4.9 on upward.


> Is there some reason why this PR is still open?

I don't think so. Apparently there was some effort planned to fix it on 4.8
(which did not happen after all, it seems). That branch is closed by now.

Closing this PR.

[Bug target/78733] [7 Regression] bootstrap broken on aarch64-linux-gnu

2016-12-08 Thread jgreenhalgh at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78733

James Greenhalgh  changed:

   What|Removed |Added

 CC||jgreenhalgh at gcc dot gnu.org,
   ||wdijkstr at arm dot com

--- Comment #3 from James Greenhalgh  ---
I see about 250 new failures when testing with -mcmodel=tiny after r243346.

These are of the same form as the failure you report:

FAIL: gfortran.dg/alloc_comp_assign_4.f90   -O3 -fomit-frame-pointer
-funroll-loops -fpeel-loops -ftracer -finline-functions  (test for excess
errors)

/tmp/ccxfODDL.s: Assembler messages:
/tmp/ccxfODDL.s:30: Error: invalid addressing mode at operand 3 -- `ldp
x24,x25,.LC2'

I haven't seen this for other values of mcmodel in my testing. I wonder how
-mcmodel=tiny made it in to your bootstrap flags?

This patch probably should be reverted for now given the number of failures.

[Bug target/78733] [7 Regression] bootstrap broken on aarch64-linux-gnu

2016-12-08 Thread ktkachov at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78733

ktkachov at gcc dot gnu.org changed:

   What|Removed |Added

 CC||ktkachov at gcc dot gnu.org

--- Comment #4 from ktkachov at gcc dot gnu.org ---

> I haven't seen this for other values of mcmodel in my testing. I wonder how
> -mcmodel=tiny made it in to your bootstrap flags?
> 

Perhaps the --enable-multiarch option gets gcc to build the libraries for all
the -mcmodel variations?

[Bug c++/77375] [5 Regression] constant object with mutable subobject allocated in read-only memory

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77375

Jakub Jelinek  changed:

   What|Removed |Added

Summary|[5/6 Regression] constant   |[5 Regression] constant
   |object with mutable |object with mutable
   |subobject allocated in  |subobject allocated in
   |read-only memory|read-only memory

--- Comment #10 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug c++/77482] [6 Regression] Segfault when compiling ill-formed constexpr code

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77482

Jakub Jelinek  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution|--- |FIXED

--- Comment #7 from Jakub Jelinek  ---
Fixed.

[Bug middle-end/77624] [5 Regression] ICE on x86_64-linux-gnu (internal compiler error: in fold_builtin_atomic_always_lock_free, at builtins.c:5583)

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77624

Jakub Jelinek  changed:

   What|Removed |Added

Summary|[5/6 Regression] ICE on |[5 Regression] ICE on
   |x86_64-linux-gnu (internal  |x86_64-linux-gnu (internal
   |compiler error: in  |compiler error: in
   |fold_builtin_atomic_always_ |fold_builtin_atomic_always_
   |lock_free, at   |lock_free, at
   |builtins.c:5583)|builtins.c:5583)

--- Comment #8 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug fortran/69860] ICE on missing end apostrophe with character(kind=4)

2016-12-08 Thread janus at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69860

janus at gcc dot gnu.org changed:

   What|Removed |Added

   Keywords||ice-on-invalid-code

--- Comment #14 from janus at gcc dot gnu.org ---
(In reply to kargl from comment #13)
> Gerhard can re-do your testing.  I seem to have good luck with FreeBSD
> in testing this.

On Ubuntu 16.10, I don't see any ICE with current trunk either, using the
method from comment #11.

But then, I don't even see ICEs with 5.4.1 or 6.2.0. I only see some with 4.9.

From my side, this can be closed.

[Bug ipa/77587] [5 Regression] C compiler produces incorrect stack alignment with __attribute__((weak))

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77587

Jakub Jelinek  changed:

   What|Removed |Added

Summary|[5/6 Regression] C compiler |[5 Regression] C compiler
   |produces incorrect stack|produces incorrect stack
   |alignment with  |alignment with
   |__attribute__((weak))   |__attribute__((weak))

--- Comment #8 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug c++/77638] [6 Regression] ICE on x86_64-linux-gnu (internal compiler error: tree check: expected tree that contains ‘decl common’ structure, have ‘error_mark’ in cp_parser_template_declaration_af

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77638

Jakub Jelinek  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution|--- |FIXED

--- Comment #6 from Jakub Jelinek  ---
Fixed.

[Bug c++/77637] ICE on x86_64-linux-gnu (Segmentation fault, tree_check, cp_parser_std_attribute_list...)

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77637

--- Comment #9 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug target/78733] [7 Regression] bootstrap broken on aarch64-linux-gnu

2016-12-08 Thread pinskia at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78733

--- Comment #5 from Andrew Pinski  ---
(In reply to ktkachov from comment #4)
> > I haven't seen this for other values of mcmodel in my testing. I wonder how
> > -mcmodel=tiny made it in to your bootstrap flags?
> > 
> 
> Perhaps the --enable-multiarch option gets gcc to build the libraries for
> all the -mcmodel variations?

My build is auto turning on multi-arch so no.  I am suspecting the workaround
a53 errata is the difference that matters.

[Bug tree-optimization/77665] [5 Regression] ICE in expand_GOMP_SIMD_VF, at internal-fn.c:172

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77665

Jakub Jelinek  changed:

   What|Removed |Added

Summary|[5/6 Regression] ICE in |[5 Regression] ICE in
   |expand_GOMP_SIMD_VF, at |expand_GOMP_SIMD_VF, at
   |internal-fn.c:172   |internal-fn.c:172

--- Comment #6 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug fortran/77666] ICE in gfc_omp_clause_default_ctor, at fortran/trans-openmp.c:471

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77666

--- Comment #5 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug c++/77722] -fsanitize=undefined doesn't give runtime error in function without return value, unless at least 2 instructions

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77722

--- Comment #4 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug sanitizer/66343] "Error: .Lubsan_type3 already defined" with UBSan and precompiled headers

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66343

--- Comment #16 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug c++/77467] Segmentation fault with switch statement in constexpr function

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77467

--- Comment #6 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug middle-end/78025] [5 Regression] ICE in simd_clone_adjust, at omp-simd-clone.c:1126

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78025

Jakub Jelinek  changed:

   What|Removed |Added

Summary|[5/6 Regression] ICE in |[5 Regression] ICE in
   |simd_clone_adjust, at   |simd_clone_adjust, at
   |omp-simd-clone.c:1126   |omp-simd-clone.c:1126

--- Comment #7 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug rtl-optimization/77919] [5 Regression] ICE converting DC to V2DF mode

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77919

Jakub Jelinek  changed:

   What|Removed |Added

Summary|[5/6 Regression] ICE|[5 Regression] ICE
   |converting DC to V2DF mode  |converting DC to V2DF mode

--- Comment #12 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug c++/78089] __builtin_shuffle parsing bug

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78089

--- Comment #3 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug fortran/77973] [6 Regression] ICE in scan_omp_1_op, at omp-low.c:3841

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77973

Jakub Jelinek  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution|--- |FIXED

--- Comment #8 from Jakub Jelinek  ---
Fixed.

[Bug target/78733] [7 Regression] bootstrap broken on aarch64-linux-gnu

2016-12-08 Thread doko at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78733

--- Comment #6 from Matthias Klose  ---
yes, I'm configuring with --enable-fix-cortex-a53-843419

[Bug tree-optimization/78721] [7 Regression] ICE on valid code at -O2 and -O3 on x86_64-linux-gnu: in set_value_range, at tree-vrp.c:371

2016-12-08 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78721

Marek Polacek  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2016-12-08
 CC||mpolacek at gcc dot gnu.org
   Target Milestone|--- |7.0
Summary|ICE on valid code at -O2|[7 Regression] ICE on valid
   |and -O3 on  |code at -O2 and -O3 on
   |x86_64-linux-gnu: in|x86_64-linux-gnu: in
   |set_value_range, at |set_value_range, at
   |tree-vrp.c:371  |tree-vrp.c:371
 Ever confirmed|0   |1

--- Comment #1 from Marek Polacek  ---
Confirmed.

[Bug tree-optimization/78721] [7 Regression] ICE on valid code at -O2 and -O3 on x86_64-linux-gnu: in set_value_range, at tree-vrp.c:371

2016-12-08 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78721

--- Comment #2 from Marek Polacek  ---
commit 166f817874730a11c132419554bb13a34c01963f
Author: kugan 
Date:   Wed Nov 9 01:41:26 2016 +

Fix ice in set_value_range
gcc/ChangeLog:

2016-11-09  Kugan Vivekanandarajah  

PR ipa/78121
* ipa-cp.c (propagate_vr_accross_jump_function): Pass param type.
Also fold constant passed as argument while computing value range.
(propagate_constants_accross_call): Pass param type.
* ipa-prop.c: export ipa_get_callee_param_type.
* ipa-prop.h: export ipa_get_callee_param_type.

gcc/testsuite/ChangeLog:

2016-11-09  Kugan Vivekanandarajah  

PR ipa/78121
* gcc.dg/ipa/pr78121.c: New test.




git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@241989
138bc75d-0d04-0410-961f-82ee72b054a4

[Bug target/78733] [7 Regression] bootstrap broken on aarch64-linux-gnu

2016-12-08 Thread jgreenhalgh at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78733

James Greenhalgh  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2016-12-08
 Ever confirmed|0   |1

--- Comment #7 from James Greenhalgh  ---
(In reply to Matthias Klose from comment #6)
> yes, I'm configuring with --enable-fix-cortex-a53-843419

And running the testsuite with -mfix-cortex-a53-843419 shows the failures.

So the problem is visible with either -mcmodel=tiny or -mfix-cortex-a53-843419

[Bug fortran/78299] [6 Regression] ICE in expand_omp_for_static_nochunk, at omp-low.c:9622

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78299

Jakub Jelinek  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution|--- |FIXED

--- Comment #6 from Jakub Jelinek  ---
Fixed.

[Bug middle-end/78419] ICE with target_clone on invalid target

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78419

--- Comment #7 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug middle-end/67335] [6 Regression] ICE in compiling omp simd function with unused argument

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67335

Jakub Jelinek  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution|--- |FIXED

--- Comment #6 from Jakub Jelinek  ---
Fixed.

[Bug rtl-optimization/78378] [5 Regression] wrong code when combining shift + mult + zero_extend

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78378

Jakub Jelinek  changed:

   What|Removed |Added

Summary|[5/6 Regression] wrong code |[5 Regression] wrong code
   |when combining shift + mult |when combining shift + mult
   |+ zero_extend   |+ zero_extend

--- Comment #10 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug c++/77285] [5 Regression] extern thread_local linkage

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77285

Jakub Jelinek  changed:

   What|Removed |Added

Summary|[5/6 Regression] extern |[5 Regression] extern
   |thread_local linkage|thread_local linkage

--- Comment #12 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug middle-end/78416] wrong code for division by (u128)~INT64_MAX at -O0

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78416

--- Comment #5 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug fortran/78298] ICE in lookup_decl_in_outer_ctx, bei omp-low.c:4115

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78298

--- Comment #6 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug c++/77591] [6 Regression] decltype(auto) and ternary operator allow returning local reference without a warning

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77591

Jakub Jelinek  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution|--- |FIXED

--- Comment #8 from Jakub Jelinek  ---
Fixed.

[Bug middle-end/69183] ICE when using OpenMP PRIVATE keyword in OMP DO loop not explicitly encapsulated in OMP PARALLEL region

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69183

--- Comment #8 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug c++/77739] [5 Regression] internal compiler error: in create_tmp_var, at gimple-expr.c:524

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77739

Jakub Jelinek  changed:

   What|Removed |Added

Summary|[5/6 Regression] internal   |[5 Regression] internal
   |compiler error: in  |compiler error: in
   |create_tmp_var, at  |create_tmp_var, at
   |gimple-expr.c:524   |gimple-expr.c:524

--- Comment #9 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug rtl-optimization/78546] [6 Regression] wrong code at -O2 and above

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78546

Jakub Jelinek  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution|--- |FIXED

--- Comment #20 from Jakub Jelinek  ---
Fixed.

[Bug c++/72808] [6 Regression] ICE on valid c++ code in verify_type (gcc/tree.c:14047)

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=72808

Jakub Jelinek  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution|--- |FIXED

--- Comment #11 from Jakub Jelinek  ---
Fixed.

[Bug middle-end/78540] [6 Regression] ICE: in df_refs_verify, at df-scan.c:4062 with -O -march=core2

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78540

Jakub Jelinek  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution|--- |FIXED

--- Comment #7 from Jakub Jelinek  ---
Fixed.

[Bug c++/78734] New: [C++17] P0145R3: function arguments are indeterminately sequenced

2016-12-08 Thread trippels at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78734

Bug ID: 78734
   Summary: [C++17] P0145R3: function arguments are
indeterminately sequenced
   Product: gcc
   Version: 7.0
Status: UNCONFIRMED
  Keywords: wrong-code
  Severity: normal
  Priority: P3
 Component: c++
  Assignee: unassigned at gcc dot gnu.org
  Reporter: trippels at gcc dot gnu.org
CC: jason at gcc dot gnu.org
  Target Milestone: ---

P0145R3 says that function arguments are indeterminately sequenced.

Consider the following example from
http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2016/p0431r0.htm:

markus@x4 /tmp % cat order.cpp
#include 
void foo(int a, int b, int c) { printf("%d %d %d\n", a, b, c); }
int main() {
  int i = 0;
  foo(++i, ++i, ++i);
}

markus@x4 /tmp % g++ -std=c++1z  order.cpp
markus@x4 /tmp % ./a.out
3 3 3

This is wrong. It should be a permutation of "1 2 3".

[Bug c++/78649] [5 Regression] ICE on invalid C++ code on x86_64-linux-gnu (internal compiler error: tree check: expected class ‘type’, have ‘exceptional’ (error_mark) in build_value_init_noctor, at c

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78649

Jakub Jelinek  changed:

   What|Removed |Added

Summary|[5/6 Regression] ICE on |[5 Regression] ICE on
   |invalid C++ code on |invalid C++ code on
   |x86_64-linux-gnu (internal  |x86_64-linux-gnu (internal
   |compiler error: tree check: |compiler error: tree check:
   |expected class ‘type’, have |expected class ‘type’, have
   |‘exceptional’ (error_mark)  |‘exceptional’ (error_mark)
   |in build_value_init_noctor, |in build_value_init_noctor,
   |at cp/init.c:380)   |at cp/init.c:380)

--- Comment #6 from Jakub Jelinek  ---
Fixed for 6.3+ as well.

[Bug tree-optimization/78725] wrong code at -O3 on x86_64-linux-gnu (in both 32-bit and 64-bit modes)

2016-12-08 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78725

Marek Polacek  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2016-12-08
 CC||mpolacek at gcc dot gnu.org
 Ever confirmed|0   |1

--- Comment #1 from Marek Polacek  ---
This used to work correctly, then with introduction of loop splitting in
r241374 it started to ICE:

/home/brq/mpolacek/2.c: In function ‘main’:
/home/brq/mpolacek/2.c:12:5: error: type mismatch in binary expression
 int main ()
 ^~~~
int

int

unsigned char

_38 = _37 - d_lsm.12_20;
/home/brq/mpolacek/2.c:12:5: internal compiler error: verify_gimple failed
0xe85c03 verify_gimple_in_cfg(function*, bool)
../../gcc/tree-cfg.c:5208
0xd19da0 execute_function_todo
../../gcc/passes.c:1965
0xd18e2b do_per_function
../../gcc/passes.c:1649
0xd19f72 execute_todo
../../gcc/passes.c:2015
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See  for instructions.

This ICE was fixed in r241551 but we've miscompiled this since.

[Bug tree-optimization/78725] [7 Regression] wrong code at -O3 on x86_64-linux-gnu (in both 32-bit and 64-bit modes)

2016-12-08 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78725

Marek Polacek  changed:

   What|Removed |Added

   Keywords||wrong-code
   Target Milestone|--- |7.0
Summary|wrong code at -O3 on|[7 Regression] wrong code
   |x86_64-linux-gnu (in both   |at -O3 on x86_64-linux-gnu
   |32-bit and 64-bit modes)|(in both 32-bit and 64-bit
   ||modes)

[Bug target/78694] [ARM] ICE with -mthumb -ftls-model=local-exec -O2

2016-12-08 Thread ktkachov at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78694

ktkachov at gcc dot gnu.org changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2016-12-08
 Ever confirmed|0   |1

--- Comment #10 from ktkachov at gcc dot gnu.org ---
Now reproduced. Sorry for the trouble. I also had to explicitly specify:
-mcpu=arm7tdmi -mfloat-abi=soft -mfpu=vfp

[Bug target/78694] [ARM] ICE with -mthumb -ftls-model=local-exec -O2

2016-12-08 Thread ktkachov at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78694

--- Comment #11 from ktkachov at gcc dot gnu.org ---
Though it is quite fragile. I can't reproduce it on a cross-toolchain, but it
does trigger on a native machine

[Bug middle-end/78726] [5/6/7 Regression] Incorrect unsigned arithmetic optimization

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78726

Jakub Jelinek  changed:

   What|Removed |Added

 CC||jakub at gcc dot gnu.org

--- Comment #1 from Jakub Jelinek  ---
Single file testcase:
unsigned char b = 36, c = 173;
unsigned int d;

__attribute__((noinline, noclone)) void
foo (void)
{
  unsigned a = ~b;
  d = a * c * c + 1023094746 * a;
}

int
main ()
{
  if (__SIZEOF_INT__ != 4 || __CHAR_BIT__ != 8)
return 0;
  asm volatile ("" : : "g" (&b), "g" (&c) : "memory");
  foo ();
  if (d != 799092689)
__builtin_abort ();
  return 0;
}

[Bug libstdc++/78723] [variant] P0393r3: "Making variant greater equal again" is unimplemented

2016-12-08 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78723

Jonathan Wakely  changed:

   What|Removed |Added

 Status|UNCONFIRMED |ASSIGNED
   Last reconfirmed||2016-12-08
 Ever confirmed|0   |1

--- Comment #2 from Jonathan Wakely  ---
(In reply to Tim Shen from comment #1)
> I refuse to implement this due to a different political stance.

That was exactly my thought too!

[Bug middle-end/78726] [5/6/7 Regression] Incorrect unsigned arithmetic optimization

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78726

Jakub Jelinek  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2016-12-08
 Ever confirmed|0   |1

--- Comment #2 from Jakub Jelinek  ---
Started with r220164, let me have a look.

[Bug libstdc++/78723] [variant] P0393r3: "Making variant greater equal again" is unimplemented

2016-12-08 Thread eric at efcs dot ca
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78723

--- Comment #3 from Eric Fiselier  ---
The joke title was a lot funnier a year ago.

[Bug rtl-optimization/78729] [7 Regression] ICE in rtl_verify_bb_insns, at cfgrtl.c:2656 (error: flow control insn inside a basic block)

2016-12-08 Thread marxin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78729

Martin Liška  changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 CC||marxin at gcc dot gnu.org
 Resolution|--- |DUPLICATE

--- Comment #1 from Martin Liška  ---
Dup.

*** This bug has been marked as a duplicate of bug 78727 ***

[Bug rtl-optimization/78730] [7 Regression] ICE in rtl_verify_bb_insns, at cfgrtl.c:2656 (error: flow control insn inside a basic block)

2016-12-08 Thread marxin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78730

Martin Liška  changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 CC||marxin at gcc dot gnu.org
 Resolution|--- |DUPLICATE

--- Comment #1 from Martin Liška  ---
Dup.

*** This bug has been marked as a duplicate of bug 78727 ***

[Bug rtl-optimization/78727] [7 Regression] ICE in rtl_verify_bb_insns, at cfgrtl.c:2656 (error: flow control insn inside a basic block)

2016-12-08 Thread marxin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78727

--- Comment #2 from Martin Liška  ---
*** Bug 78729 has been marked as a duplicate of this bug. ***

[Bug rtl-optimization/78728] [7 Regression] ICE in rtl_verify_bb_insns, at cfgrtl.c:2656 (error: flow control insn inside a basic block)

2016-12-08 Thread marxin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78728

Martin Liška  changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 CC||marxin at gcc dot gnu.org
 Resolution|--- |DUPLICATE

--- Comment #1 from Martin Liška  ---
Dup.

*** This bug has been marked as a duplicate of bug 78727 ***

[Bug rtl-optimization/78727] [7 Regression] ICE in rtl_verify_bb_insns, at cfgrtl.c:2656 (error: flow control insn inside a basic block)

2016-12-08 Thread marxin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78727

--- Comment #1 from Martin Liška  ---
*** Bug 78728 has been marked as a duplicate of this bug. ***

[Bug rtl-optimization/78727] [7 Regression] ICE in rtl_verify_bb_insns, at cfgrtl.c:2656 (error: flow control insn inside a basic block)

2016-12-08 Thread marxin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78727

--- Comment #3 from Martin Liška  ---
*** Bug 78730 has been marked as a duplicate of this bug. ***

[Bug middle-end/78726] [5/6/7 Regression] Incorrect unsigned arithmetic optimization

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78726

--- Comment #3 from Jakub Jelinek  ---
Most likely one of the endless reassoc bugs not properly updating or
invalidating range information.  Before reassoc1 we have:
  # RANGE [4294967040, 4294967295]
  a_11 = (unsigned int) _3;
  c.1_4 = c;
  # RANGE [0, 255] NONZERO 255
  _5 = (unsigned int) c.1_4;
  # RANGE ~[1, 4294902015]
  _6 = _5 * a_11;
  # RANGE ~[1, 4278320895]
  _7 = _5 * _6;
which looks correct, a_11 is int [-256, 1] converted to unsigned int, and c is
unsigned char.
But reassoc1 turns this into:
  # RANGE [4294967040, 4294967295]
  a_11 = (unsigned int) _3;
  c.1_4 = c;
  # RANGE [0, 255] NONZERO 255
  _5 = (unsigned int) c.1_4;
  # RANGE ~[1, 4278320895]
  _7 = _5 * _5;
  _13 = _7 + 1023094746;
  _14 = _13 * a_11;
It should have reused the SSA_NAME (_7) for something different, _5 * _5 has a
range of [0, 65025] and could have been used in debug stmts later on.

[Bug libstdc++/77459] [6 Regression] undefined reference to `snprintf' when building mingw-w64 cross-compiler

2016-12-08 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77459

Jonathan Wakely  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2016-12-08
 Ever confirmed|0   |1

--- Comment #12 from Jonathan Wakely  ---
I'm backporting this to gcc-6-branch too.

[Bug tree-optimization/78721] [7 Regression] ICE on valid code at -O2 and -O3 on x86_64-linux-gnu: in set_value_range, at tree-vrp.c:371

2016-12-08 Thread kugan at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78721

kugan at gcc dot gnu.org changed:

   What|Removed |Added

 CC||kugan at gcc dot gnu.org

--- Comment #3 from kugan at gcc dot gnu.org ---
Created attachment 40280
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=40280&action=edit
untested patch

[Bug target/78694] [ARM] ICE with -mthumb -ftls-model=local-exec -O2

2016-12-08 Thread sebastian.hu...@embedded-brains.de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78694

--- Comment #12 from Sebastian Huber  ---
Its strange that it is so hard to reproduce.  Maybe it has something to do with
the default architecture version.

It fails with:

-mthumb -O2 -ftls-model=local-exec -march=armv4t
-mthumb -O2 -ftls-model=local-exec -march=armv5t
-mthumb -O2 -ftls-model=local-exec -march=armv6

It works with:

-mthumb -O2 -ftls-model=local-exec -march=armv7

[Bug middle-end/78684] [7 Regression] ICE in create_intersect_range_checks_index, at tree-vect-loop-manip.c:2074

2016-12-08 Thread amker at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78684

--- Comment #9 from amker at gcc dot gnu.org ---
Author: amker
Date: Thu Dec  8 10:56:41 2016
New Revision: 243431

URL: https://gcc.gnu.org/viewcvs?rev=243431&root=gcc&view=rev
Log:
PR middle-end/78684
* tree-vect-loop-manip.c (create_intersect_range_checks_index): Check
sign bit for index step of data reference.
gcc/testsuite
PR middle-end/78684
* g++.dg/torture/pr78684.C: New test.

Added:
trunk/gcc/testsuite/g++.dg/torture/pr78684.C
Modified:
trunk/gcc/ChangeLog
trunk/gcc/testsuite/ChangeLog
trunk/gcc/tree-vect-loop-manip.c

[Bug debug/78112] [7 regression] invalid DWARF generated by the compiler: DIE has multiple AT_inline attributes

2016-12-08 Thread pmderodat at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78112

--- Comment #18 from pmderodat at gcc dot gnu.org ---
Author: pmderodat
Date: Thu Dec  8 11:01:03 2016
New Revision: 243432

URL: https://gcc.gnu.org/viewcvs?rev=243432&root=gcc&view=rev
Log:
[PR78112] Remove platform-dependent checks in g++.dg/pr78112.C

... as there checks failed on many platforms. As a replacement, this
commit also adds a new testcase from source reduction. The hope is that
this new testcase will get a consistent output across all platforms.

gcc/testsuite/
PR debug/78112
* g++.dg/pr78112.C: Remove platform-dependent checks.
* g++.dg/pr78112-2.C: New testcase.

Added:
trunk/gcc/testsuite/g++.dg/pr78112-2.C
Modified:
trunk/gcc/testsuite/g++.dg/pr78112.C

[Bug debug/78112] [7 regression] invalid DWARF generated by the compiler: DIE has multiple AT_inline attributes

2016-12-08 Thread pmderodat at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78112

--- Comment #19 from pmderodat at gcc dot gnu.org ---
Author: pmderodat
Date: Thu Dec  8 11:04:11 2016
New Revision: 243433

URL: https://gcc.gnu.org/viewcvs?rev=243433&root=gcc&view=rev
Log:
Add the missing ChangeLog entry for r243432

2016-12-08  Pierre-Marie de Rodat  

PR debug/78112
* g++.dg/pr78112.C: Remove platform-dependent checks.
* g++.dg/pr78112-2.C: New testcase.

Modified:
trunk/gcc/testsuite/ChangeLog

[Bug target/78694] [ARM] ICE with -mthumb -ftls-model=local-exec -O2

2016-12-08 Thread ktkachov at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78694

ktkachov at gcc dot gnu.org changed:

   What|Removed |Added

   Keywords||ice-checking
 Status|NEW |ASSIGNED
   Assignee|unassigned at gcc dot gnu.org  |ktkachov at gcc dot 
gnu.org
   Target Milestone|--- |7.0

--- Comment #13 from ktkachov at gcc dot gnu.org ---
Looks like dump_minipool should be doing a copy_rtx before emitting the
patterns.

[Bug libstdc++/78264] [7 regression] ICE in build_noexcept_spec, at cp/except.c:1196

2016-12-08 Thread ebotcazou at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78264

Eric Botcazou  changed:

   What|Removed |Added

 Status|NEW |ASSIGNED
   Assignee|unassigned at gcc dot gnu.org  |ebotcazou at gcc dot 
gnu.org

--- Comment #7 from Eric Botcazou  ---
It's the new macro in c++config:

#if __cpp_noexcept_function_type
#define _GLIBCXX_NOEXCEPT_PARM , bool _N
#define _GLIBCXX_NOEXCEPT_QUAL noexcept (_N)
#else
#define _GLIBCXX_NOEXCEPT_PARM
#define _GLIBCXX_NOEXCEPT_QUAL
#endif

See this comment a few lines below in the same file:

// This marks string literals in header files to be extracted for eventual
// translation.  It is primarily used for messages in thrown exceptions; see
// src/functexcept.cc.  We use __N because the more traditional _N is used
// for something else under certain OSes (see BADNAMES).
#define __N(msgid) (msgid)

Testing trivial fix...

[Bug rtl-optimization/78735] New: profiledbootstrap with --enable-checking=yes,rtl fails on trunk due to -Werror=strict-overflow

2016-12-08 Thread sirl at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78735

Bug ID: 78735
   Summary: profiledbootstrap with --enable-checking=yes,rtl fails
on trunk due to -Werror=strict-overflow
   Product: gcc
   Version: 7.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: rtl-optimization
  Assignee: unassigned at gcc dot gnu.org
  Reporter: sirl at gcc dot gnu.org
  Target Milestone: ---

Hi,

current trunk (tried r243299 and r243376) on x86_64 fails a profiledbootstrap
with --enable-checking=yes,rtl like that:

/home/fsirl/rpmbuild/BUILD/gcc-7.0.0-r243376/obj-x86_64-suse-linux/./prev-gcc/xg++
-B/home/fsirl/rpmbuild/BUILD/gcc-7.0.0-r243376/obj-x86_64-suse-linux/./prev-gcc/
-B/usr/x86_64-suse-linux/bin/ -nostdinc++
-B/home/fsirl/rpmbuild/BUILD/gcc-7.0.0-r243376/obj-x86_64-suse-linux/prev-x86_64-suse-linux/libstdc++-v3/src/.libs
-B/home/fsirl/rpmbuild/BUILD/gcc-7.0.0-r243376/obj-x86_64-suse-linux/prev-x86_64-suse-linux/libstdc++-v3/libsupc++/.libs

-I/home/fsirl/rpmbuild/BUILD/gcc-7.0.0-r243376/obj-x86_64-suse-linux/prev-x86_64-suse-linux/libstdc++-v3/include/x86_64-suse-linux

-I/home/fsirl/rpmbuild/BUILD/gcc-7.0.0-r243376/obj-x86_64-suse-linux/prev-x86_64-suse-linux/libstdc++-v3/include
 -I/home/fsirl/rpmbuild/BUILD/gcc-7.0.0-r243376/libstdc++-v3/libsupc++
-L/home/fsirl/rpmbuild/BUILD/gcc-7.0.0-r243376/obj-x86_64-suse-linux/prev-x86_64-suse-linux/libstdc++-v3/src/.libs
-L/home/fsirl/rpmbuild/BUILD/gcc-7.0.0-r243376/obj-x86_64-suse-linux/prev-x86_64-suse-linux/libstdc++-v3/libsupc++/.libs
-fno-PIE -c   -O2 -g -fmessage-length=0 -D_FORTIFY_SOURCE=2 -funwind-tables
-fasynchronous-unwind-tables -U_FORTIFY_SOURCE -fprofile-use -DIN_GCC
-fno-exceptions -fno-rtti -fasynchronous-unwind-tables -W -Wall -Wno-narrowing
-Wwrite-strings -Wcast-qual -Wmissing-format-attribute -Woverloaded-virtual
-pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings -Werror
-fno-common  -DHAVE_CONFIG_H -I. -I. -I../../gcc -I../../gcc/.
-I../../gcc/../include -I../../gcc/../libcpp/include 
-I../../gcc/../libdecnumber -I../../gcc/../libdecnumber/bid -I../libdecnumber
-I../../gcc/../libbacktrace   -o combine.o -MT combine.o -MMD -MP -MF
./.deps/combine.TPo ../../gcc/combine.c
In file included from ../../gcc/combine.c:83:0:
../../gcc/combine.c: In function 'int recog_for_combine(rtx_def**, rtx_insn*,
rtx_def**)':
../../gcc/rtl.h:1076:17: error: assuming signed overflow does not occur when
assuming that (X - c) > X is always false [-Werror=strict-overflow]
  if (_i < 0 || _i >= GET_NUM_ELEM (_rtvec))\
 ^
../../gcc/rtl.h:702:45: note: in definition of macro 'GET_CODE'
 #define GET_CODE(RTX) ((enum rtx_code) (RTX)->code)
 ^~~
../../gcc/rtl.h:1298:28: note: in expansion of macro 'RTVEC_ELT'
 #define XVECEXP(RTX, N, M) RTVEC_ELT (XVEC (RTX, N), M)
^
../../gcc/combine.c:11088:21: note: in expansion of macro 'XVECEXP'
   if (GET_CODE (XVECEXP (pat, 0, i)) == CLOBBER
 ^~~
../../gcc/rtl.h:1076:17: error: assuming signed overflow does not occur when
assuming that (X - c) > X is always false [-Werror=strict-overflow]
  if (_i < 0 || _i >= GET_NUM_ELEM (_rtvec))\
 ^
../../gcc/rtl.h:702:45: note: in definition of macro 'GET_CODE'
 #define GET_CODE(RTX) ((enum rtx_code) (RTX)->code)
 ^~~
../../gcc/rtl.h:1298:28: note: in expansion of macro 'RTVEC_ELT'
 #define XVECEXP(RTX, N, M) RTVEC_ELT (XVEC (RTX, N), M)
^
../../gcc/combine.c:11088:21: note: in expansion of macro 'XVECEXP'
   if (GET_CODE (XVECEXP (pat, 0, i)) == CLOBBER
 ^~~
../../gcc/rtl.h:1076:17: error: assuming signed overflow does not occur when
assuming that (X - c) > X is always false [-Werror=strict-overflow]
  if (_i < 0 || _i >= GET_NUM_ELEM (_rtvec))\
 ^
../../gcc/rtl.h:702:45: note: in definition of macro 'GET_CODE'
 #define GET_CODE(RTX) ((enum rtx_code) (RTX)->code)
 ^~~
../../gcc/rtl.h:1298:28: note: in expansion of macro 'RTVEC_ELT'
 #define XVECEXP(RTX, N, M) RTVEC_ELT (XVEC (RTX, N), M)
^
../../gcc/combine.c:11088:21: note: in expansion of macro 'XVECEXP'
   if (GET_CODE (XVECEXP (pat, 0, i)) == CLOBBER
 ^~~
More of the same errors follow. A simple "make bootstrap" works fine.

The build (actually the SRCRPM from OBS with updated sources) was configured
like that:

CFLAGS='-O2 -g -fmessage-length=0 -D_FORTIFY_SOURCE=2 -funwind-tables
-fasynchronous-unwind-tables -U_FORTIFY_SOURCE'
CXXFLAGS='-O2 -g -fmessage-length=0 -D_FORTIFY_SOURCE=2 -funwind-tables
-fasynchronous-unwind-tables -U_FORTIFY_SOURCE'
XCFLAGS='-O2 -g -fmessage-length=0 -D_FORTIFY_SOURCE=2 -funw

[Bug target/78733] [7 Regression] bootstrap broken on aarch64-linux-gnu

2016-12-08 Thread wilco at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78733

wilco at gcc dot gnu.org changed:

   What|Removed |Added

 CC||wilco at gcc dot gnu.org

--- Comment #8 from wilco at gcc dot gnu.org ---
(In reply to James Greenhalgh from comment #7)
> (In reply to Matthias Klose from comment #6)
> > yes, I'm configuring with --enable-fix-cortex-a53-843419
> 
> And running the testsuite with -mfix-cortex-a53-843419 shows the failures.
> 
> So the problem is visible with either -mcmodel=tiny or
> -mfix-cortex-a53-843419

It's -mpc-relative-literal-loads (which is set by both). There is an issue in
aarch64_classify_address that doesn't correctly identify TI/TFmode as possible
LDP/STP instructions. I'm testing a fix.

[Bug libstdc++/71856] [6/7 Regression] _GLIBCXX_DEBUG-mode breaks GNU parallel extension

2016-12-08 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71856

--- Comment #11 from Jonathan Wakely  ---
Author: redi
Date: Thu Dec  8 12:08:14 2016
New Revision: 243434

URL: https://gcc.gnu.org/viewcvs?rev=243434&root=gcc&view=rev
Log:
PR71856 try to fix Parallel Mode assertions again

PR libstdc++/71856
* doc/xml/manual/using.xml: Document macro.
* include/bits/c++config [_GLIBCXX_DEBUG || _GLIBCXX_PARALLEL]
(__glibcxx_assert): Rename to __glibcxx_assert_impl.
[_GLIBCXX_DEBUG] (__glibcxx_assert): Expand to __glibcxx_assert_impl.
* include/parallel/base.h [_GLIBCXX_PARALLEL_ASSERTIONS]
(_GLIBCXX_PARALLEL_ASSERT): Expand to __glibcxx_assert_impl.
[!_GLIBCXX_PARALLEL_ASSERTIONS] (_GLIBCXX_PARALLEL_ASSERT): Define as
empty.
* testsuite/25_algorithms/headers/algorithm/
parallel_algorithm_assert2.cc: New test.

Added:
   
trunk/libstdc++-v3/testsuite/25_algorithms/headers/algorithm/parallel_algorithm_assert2.cc
Modified:
trunk/libstdc++-v3/ChangeLog
trunk/libstdc++-v3/doc/xml/manual/using.xml
trunk/libstdc++-v3/include/bits/c++config
trunk/libstdc++-v3/include/parallel/base.h

[Bug c/78736] New: enum warnings in GCC

2016-12-08 Thread erika.molnar at cyberthorstudios dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78736

Bug ID: 78736
   Summary: enum warnings in GCC
   Product: gcc
   Version: unknown
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c
  Assignee: unassigned at gcc dot gnu.org
  Reporter: erika.molnar at cyberthorstudios dot com
  Target Milestone: ---

Hi,

This is not a bug but when compiling with gcc-6.2 the following code:

***
#include 

typedef enum {brandon, jon, mitch} name_t;
typedef enum {fred, dog, cat} name2_t;
name2_t name = brandon;
name_t hik = 3;


int hal_entry(void)
{

if (hik < name)

return(0);
return 1;
}

int main ()
{
printf ("%d\n", hal_entry());
return 0;
}
***

There is no warning about the enum(which is correct in C) however when I
compile the same code with a different/proprietary compiler I get the following
warning:

W0511180:The evaluation period has expired.
../src/cc.c(33):W0520188:Enumerated type mixed with another type
../src/cc.c(34):W0520188:Enumerated type mixed with another type


Would you consider implementing such a warning in GCC?

__
Thank you,
Erika Molnar

[Bug middle-end/78716] [7 Regression] ICE in gimplify_va_arg_expr, at gimplify.c:12650 (i686-linux-gnu)

2016-12-08 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78716

Marek Polacek  changed:

   What|Removed |Added

 Status|NEW |ASSIGNED
   Assignee|unassigned at gcc dot gnu.org  |mpolacek at gcc dot 
gnu.org

[Bug c/78736] enum warnings in GCC

2016-12-08 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78736

Marek Polacek  changed:

   What|Removed |Added

 CC||mpolacek at gcc dot gnu.org

--- Comment #1 from Marek Polacek  ---
We already have -Wenum-compare if that's what you want.

[Bug libstdc++/77459] [6 Regression] undefined reference to `snprintf' when building mingw-w64 cross-compiler

2016-12-08 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77459

--- Comment #13 from Jonathan Wakely  ---
Author: redi
Date: Thu Dec  8 12:40:58 2016
New Revision: 243435

URL: https://gcc.gnu.org/viewcvs?rev=243435&root=gcc&view=rev
Log:
PR77459 avoid snprintf for debug mode diagnostics

Backport from mainline
2016-11-10  François Dumont  

PR libstdc++/77459
* src/c++11/debug.cc (format_word): Delete.
(print_literal): New. Replace call to print_word for literals.

Modified:
branches/gcc-6-branch/libstdc++-v3/ChangeLog
branches/gcc-6-branch/libstdc++-v3/src/c++11/debug.cc

[Bug libstdc++/71856] [6/7 Regression] _GLIBCXX_DEBUG-mode breaks GNU parallel extension

2016-12-08 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71856

--- Comment #12 from Jonathan Wakely  ---
Author: redi
Date: Thu Dec  8 12:41:07 2016
New Revision: 243436

URL: https://gcc.gnu.org/viewcvs?rev=243436&root=gcc&view=rev
Log:
PR71856 try to fix Parallel Mode assertions again

PR libstdc++/71856
* doc/xml/manual/using.xml: Document macro.
* include/bits/c++config [_GLIBCXX_DEBUG || _GLIBCXX_PARALLEL]
(__glibcxx_assert): Rename to __glibcxx_assert_impl.
[_GLIBCXX_DEBUG] (__glibcxx_assert): Expand to __glibcxx_assert_impl.
* include/parallel/base.h [_GLIBCXX_PARALLEL_ASSERTIONS]
(_GLIBCXX_PARALLEL_ASSERT): Expand to __glibcxx_assert_impl.
[!_GLIBCXX_PARALLEL_ASSERTIONS] (_GLIBCXX_PARALLEL_ASSERT): Define as
empty.
* testsuite/25_algorithms/headers/algorithm/
parallel_algorithm_assert2.cc: New test.

Added:
   
branches/gcc-6-branch/libstdc++-v3/testsuite/25_algorithms/headers/algorithm/parallel_algorithm_assert2.cc
Modified:
branches/gcc-6-branch/libstdc++-v3/ChangeLog
branches/gcc-6-branch/libstdc++-v3/doc/xml/manual/using.xml
branches/gcc-6-branch/libstdc++-v3/include/bits/c++config
branches/gcc-6-branch/libstdc++-v3/include/parallel/base.h

[Bug libstdc++/71856] [6/7 Regression] _GLIBCXX_DEBUG-mode breaks GNU parallel extension

2016-12-08 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71856

Jonathan Wakely  changed:

   What|Removed |Added

 Status|REOPENED|RESOLVED
 Resolution|--- |FIXED

--- Comment #13 from Jonathan Wakely  ---
Fixed for 6.3

[Bug libstdc++/77459] [6 Regression] undefined reference to `snprintf' when building mingw-w64 cross-compiler

2016-12-08 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77459

Jonathan Wakely  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |FIXED

--- Comment #14 from Jonathan Wakely  ---
Fixed for 6.3

[Bug fortran/61767] [OOP] ICE in generate_finalization_wrapper at fortran/class.c:1491

2016-12-08 Thread janus at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61767

--- Comment #10 from janus at gcc dot gnu.org ---
(In reply to janus from comment #9)
> Thus: The patch in comment #7 should be discarded, and comment #5 is the way
> to go here.

I just realized that also comment #5 is not fully correct. Instead the problem
originates from a different place: The function 'has_finalizer_component' is
buggy and can be fixed like this ...



Index: gcc/fortran/class.c
===
--- gcc/fortran/class.c (revision 243433)
+++ gcc/fortran/class.c (working copy)
@@ -841,20 +841,19 @@ has_finalizer_component (gfc_symbol *derived)
gfc_component *c;

   for (c = derived->components; c; c = c->next)
-{
-  if (c->ts.type == BT_DERIVED && c->ts.u.derived->f2k_derived
- && c->ts.u.derived->f2k_derived->finalizers)
-   return true;
+if (c->ts.type == BT_DERIVED && !c->attr.pointer && !c->attr.allocatable)
+  {
+   if (c->ts.u.derived->f2k_derived
+   && c->ts.u.derived->f2k_derived->finalizers)
+ return true;

-  /* Stop infinite recursion through this function by inhibiting
-calls when the derived type and that of the component are
-the same.  */
-  if (c->ts.type == BT_DERIVED
- && !gfc_compare_derived_types (derived, c->ts.u.derived)
- && !c->attr.pointer && !c->attr.allocatable
- && has_finalizer_component (c->ts.u.derived))
-   return true;
-}
+   /* Stop infinite recursion through this function by inhibiting
+ calls when the derived type and that of the component are
+ the same.  */
+   if (!gfc_compare_derived_types (derived, c->ts.u.derived)
+   && has_finalizer_component (c->ts.u.derived))
+ return true;
+  }
   return false;
 }

[Bug c/78736] enum warnings in GCC

2016-12-08 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78736

--- Comment #2 from Jonathan Wakely  ---
And it's included in -Wall

[Bug middle-end/78720] [7 Regression] Illegal instruction in generated code

2016-12-08 Thread trippels at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78720

Markus Trippelsdorf  changed:

   What|Removed |Added

   Target Milestone|--- |7.0

[Bug tree-optimization/78720] [7 Regression] Illegal instruction in generated code

2016-12-08 Thread trippels at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78720

Markus Trippelsdorf  changed:

   What|Removed |Added

  Component|middle-end  |tree-optimization

--- Comment #4 from Markus Trippelsdorf  ---
From:

void foo() ()   
{   
  signed char var_13.0_1;   
  signed char _2;   
  int _3;   
  int _4;   
  int _5;   
  long int _6;  

   [0.0%]:
  var_13.0_1 = var_13;  
  _2 = var_13.0_1 >> -14;   
  _3 = (int) _2;
  _4 = _3 & 2097152;
  _5 = 1 % _4;  
  _6 = (long int) _5;   
  rrr = _6; 
  return;   

}

To (ccp1):

void foo() ()   
{   
  signed char var_13.0_1;   
  int _5;   
  long int _6;  

   [0.0%]:
  var_13.0_1 = var_13;  
  _5 = 1 % 0;   
  _6 = (long int) _5;   
  rrr = _6; 
  return;   

}

[Bug libstdc++/67807] [5/6/7 Regression] call to public member function catalog failed on Linux -std=c++03

2016-12-08 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67807

Jonathan Wakely  changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution|--- |INVALID

--- Comment #2 from Jonathan Wakely  ---
The testcase doesn't show any problem, and nothing fails as claimed.

The return value 1 does not mean opening the catalog failed, it is not an error
code, it's a handle for a catalog. After calling do_open() twice you have two
different handles (which happen to refer to the same catalog, but that's beside
the point).

The behaviour you see is conforming, and not a bug.

[Bug c/78666] conflicting attribute alloc_size accepted

2016-12-08 Thread joseph at codesourcery dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78666

--- Comment #4 from joseph at codesourcery dot com  ---
Multiple format attributes for the same function, naming different 
arguments as a format string, are perfectly valid; they mean the function 
uses multiple format strings (each of which has to match the arguments 
indicated by the attribute).

[Bug tree-optimization/78720] [7 Regression] Illegal instruction in generated code

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78720

Jakub Jelinek  changed:

   What|Removed |Added

 CC||jakub at gcc dot gnu.org

--- Comment #5 from Jakub Jelinek  ---
Already the >> -14 looks wrong.

[Bug ipa/77674] [7 Regression] ICE in binds_to_current_def_p with -fkeep-inline-functions

2016-12-08 Thread hubicka at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77674

--- Comment #7 from Jan Hubicka  ---
I am testing the following:
Index: symtab.c
===
--- symtab.c(revision 243291)
+++ symtab.c(working copy)
@@ -2214,6 +2214,8 @@ symtab_node::binds_to_current_def_p (sym
 {
   if (!definition)
 return false;
+  if (transparent_alias)
+return symtab_node::binds_to_current_def_p (get_alias_target ());
   if (decl_binds_to_current_def_p (decl))
 return true;

[Bug middle-end/78726] [5/6/7 Regression] Incorrect unsigned arithmetic optimization

2016-12-08 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78726

Jakub Jelinek  changed:

   What|Removed |Added

 Status|NEW |ASSIGNED
   Assignee|unassigned at gcc dot gnu.org  |jakub at gcc dot gnu.org

--- Comment #4 from Jakub Jelinek  ---
Created attachment 40281
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=40281&action=edit
gcc7-pr78726.patch

Untested fix.

[Bug target/78733] [7 Regression] bootstrap broken on aarch64-linux-gnu

2016-12-08 Thread wilco at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78733

--- Comment #9 from wilco at gcc dot gnu.org ---
Patch posted: https://gcc.gnu.org/ml/gcc-patches/2016-12/msg00653.html

[Bug c/78666] conflicting attribute alloc_size accepted

2016-12-08 Thread msebor at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78666

--- Comment #5 from Martin Sebor  ---
They sure are!  (We should document it.)

But what is specifying multiple declarations of the same function with
different sets of attributes supposed to mean?  Is it supposed to apply the
union of all of them?  How should conflicts be resolved?  Should the rules be
expected to be consistent across attributes with different names?

FWIW, I would be inclined to accept just the set of attributes on the first
declaration and ignore all the others (with a warning), and give an error on
conflicts in the same declaration.

Alternatively, take a union of non-conflicting attributes across all
declarations and warn about conflicts.  This would suffer from the problem that
if the function were called after only a subset of its declarations were seen
only the set of attributes seen so far would likely apply (and it would likely
change with optimization and inlining.)

[Bug fortran/78737] New: linking error with deferred, undefined user-defined derived-type I/O

2016-12-08 Thread damian at sourceryinstitute dot org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78737

Bug ID: 78737
   Summary: linking error with deferred, undefined user-defined
derived-type I/O
   Product: gcc
   Version: 7.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: fortran
  Assignee: unassigned at gcc dot gnu.org
  Reporter: damian at sourceryinstitute dot org
  Target Milestone: ---

A linking error results when an abstract type defers a user-defined derived
type output binding that is not implemented anywhere in the program:

$ cat undefined-ud-dtio.f90 
module object_interface
  type, abstract :: object
  contains
procedure(write_formatted_interface), deferred ::write_formatted 
generic :: write(formatted)=>write_formatted
  end type 
  abstract interface
subroutine write_formatted_interface(this,unit,iotype,vlist,iostat,iomsg)
  import object
  class(object), intent(in) :: this
  integer, intent(in) :: unit
  character (len=*), intent(in) :: iotype
  integer, intent(in) :: vlist(:)
  integer, intent(out) :: iostat
  character (len=*), intent(inout) :: iomsg
end subroutine
  end interface
contains
  subroutine assert(a)
class(object):: a
write(*,*) a 
  end subroutine
end module

end

$ gfortran undefined-ud-dtio.f90 
Undefined symbols for architecture x86_64:
  "_write_formatted_interface_", referenced from:
  ___object_interface_MOD_assert in ccMQHXbf.o
ld: symbol(s) not found for architecture x86_64
collect2: error: ld returned 1 exit status
rouson@localhost:~/xfr$ gfortran --version
GNU Fortran (MacPorts gcc7 7-20161127_0) 7.0.0 20161127 (experimental)

Adding a type that defines the binding eliminates the linking error.

[Bug libstdc++/78264] [7 regression] ICE in build_noexcept_spec, at cp/except.c:1196

2016-12-08 Thread ebotcazou at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78264

--- Comment #8 from Eric Botcazou  ---
Author: ebotcazou
Date: Thu Dec  8 15:52:11 2016
New Revision: 243443

URL: https://gcc.gnu.org/viewcvs?rev=243443&root=gcc&view=rev
Log:
PR libstdc++/78264
* include/bits/c++config (_GLIBCXX_NOEXCEPT_PARM): Turn _N into _NE.
(_GLIBCXX_NOEXCEPT_QUAL): Likewise.

Modified:
trunk/libstdc++-v3/ChangeLog
trunk/libstdc++-v3/include/bits/c++config

[Bug libstdc++/78264] [7 regression] ICE in build_noexcept_spec, at cp/except.c:1196

2016-12-08 Thread ebotcazou at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78264

Eric Botcazou  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution|--- |FIXED

--- Comment #9 from Eric Botcazou  ---
.

[Bug target/78695] [7 Regression] ICE (segfault) on powerpc64le-linux-gnu

2016-12-08 Thread doko at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78695

--- Comment #8 from Matthias Klose  ---
still seen with r243430, but you need -fstack-protector or
-fstack-protector-strong

[Bug target/78695] [7 Regression] ICE (segfault) on powerpc64le-linux-gnu

2016-12-08 Thread trippels at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78695

Markus Trippelsdorf  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2016-12-08
 CC||trippels at gcc dot gnu.org
 Ever confirmed|0   |1

--- Comment #9 from Markus Trippelsdorf  ---
Confirmed with -fstack-protector:

Program received signal SIGSEGV, Segmentation fault.
0x10cf2918 in find_alignment_op (insn=0x3fffaf641a00,
base_reg=0x3fffaf580300) at ../../gcc/gcc/config/rs6000/rs6000.c:41445
41445 rtx_insn *and_insn = DF_REF_INSN (base_def_link->ref);
(gdb) l
41440
41441 struct df_link *base_def_link = DF_REF_CHAIN (base_use);
41442 if (!base_def_link || base_def_link->next)
41443   break;
41444
41445 rtx_insn *and_insn = DF_REF_INSN (base_def_link->ref);
41446 and_operation = alignment_mask (and_insn);
41447 if (and_operation != 0)
41448   break;
41449   }
(gdb) p base_def_link->ref->base->insn_info
$1 = (df_insn_info *) 0x0

[Bug target/78695] [7 Regression] ICE (segfault) on powerpc64le-linux-gnu

2016-12-08 Thread wschmidt at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78695

--- Comment #10 from Bill Schmidt  ---
Excellent, thanks.

I am out of the office today but will have a look at this tomorrow.

[Bug libstdc++/42679] RTLD_DEEPBIND dlopen option for shared library that uses libstdc++ std::ostream crashes

2016-12-08 Thread maemarcus at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=42679

maemarcus at gmail dot com changed:

   What|Removed |Added

 CC||maemarcus at gmail dot com

--- Comment #23 from maemarcus at gmail dot com ---
FWIW, I came across this issue with SEGFAULT in cerr on g++ 4.8.5.
Interestingly, cout in the same time works fine. Got resolved either by
removing RTLD_DEEPBIND, or by adding -static-libstdc++ to link line. Hint on
adding -fPIC was not helpful, as it is already added everywhere.

Program received signal SIGSEGV, Segmentation fault.
0x77b5af40 in std::ostream::sentry::sentry (this=0x7fffcf10,
__os=...)
at
/build/gcc-4.8-Iyjgor/gcc-4.8-4.8.5/build/x86_64-linux-gnu/libstdc++-v3/include/bits/ostream.tcc:51
51if (__os.tie() && __os.good())

[Bug rtl-optimization/78738] New: [7 Regression] ICE in extract_insn, at recog.c:2311

2016-12-08 Thread doko at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78738

Bug ID: 78738
   Summary: [7 Regression] ICE in extract_insn, at recog.c:2311
   Product: gcc
   Version: 7.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: rtl-optimization
  Assignee: unassigned at gcc dot gnu.org
  Reporter: doko at gcc dot gnu.org
  Target Milestone: ---

seen with r243219 on i686-linux-gnu, either omitting the -std=c99 or
-ffast-math works around it:

$ cat fractal_cache.i
double a;
long double roundl();
void b() {
  int c = roundl(a);
  b(c);
}

$ gcc -c -O2 -std=c99 -ffast-math fractal_cache.i 
fractal_cache.i: In function 'b':
fractal_cache.i:6:1: error: unrecognizable insn:
 }
 ^
(insn 10 9 11 2 (set (reg:DF 93)
(plus:DF (reg:DF 92)
(reg:DF 95))) "fractal_cache.i":4 -1
 (nil))
fractal_cache.i:6:1: internal compiler error: in extract_insn, at recog.c:2311
0x85c48cf _fatal_insn(char const*, rtx_def const*, char const*, int, char
const*)
../../src/gcc/rtl-error.c:108
0x85c490c _fatal_insn_not_found(rtx_def const*, char const*, int, char const*)
../../src/gcc/rtl-error.c:116
0x8596890 extract_insn(rtx_insn*)
../../src/gcc/recog.c:2311
0x83eb32d instantiate_virtual_regs_in_insn
../../src/gcc/function.c:1589
0x83eb32d instantiate_virtual_regs
../../src/gcc/function.c:1956
0x83eb32d execute
../../src/gcc/function.c:2005
Please submit a full bug report,
with preprocessed source if appropriate.

[Bug rtl-optimization/78738] [7 Regression] ICE in extract_insn, at recog.c:2311

2016-12-08 Thread doko at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78738

--- Comment #1 from Matthias Klose  ---
Created attachment 40282
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=40282&action=edit
preprocessed source

[Bug fortran/66544] [F03] ICE on function with procedure-pointer result in combination with implicit none

2016-12-08 Thread janus at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66544

--- Comment #8 from janus at gcc dot gnu.org ---
(In reply to janus from comment #4)
> Btw, I don't fully understand why "implicit none" should make any difference
> here.

The problem is that we simply do not know which typespec to give to 'z' (and
thus to 'f'), therefore it stays with BT_UNKNOWN which causes the ICE. When
omitting the 'implicit none', the symbols get typed implicitly, which is not
really correct either.

If you believe it's valid, one could hack around the ICE using BT_VOID or so:

Index: resolve.c
===
--- resolve.c   (revision 243433)
+++ resolve.c   (working copy)
@@ -220,6 +220,8 @@ resolve_procedure_interface (gfc_symbol *sym)
  sym->attr.class_ok = ifc->result->attr.class_ok;
  sym->as = gfc_copy_array_spec (ifc->result->as);
  sym->result = sym;
+ if (sym->ts.type == BT_UNKNOWN && ifc->result->attr.proc_pointer)
+   sym->ts.type = BT_VOID;
}
   else
{


But that's certainly not a very nice and clean solution and I have no idea if
it would produce the expected results at runtime.

I'm still a bit doubtful if it's really valid. Are there any other compilers
which accept such a construct?

[Bug fortran/69398] [OOP] ICE on class with duplicate dimension attribute specified

2016-12-08 Thread janus at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69398

--- Comment #4 from janus at gcc dot gnu.org ---
Note that we also have a rejects-valid problem with the following code:


program p
   type t
   end type
   class(t), allocatable :: z
   target :: z(:)
   allocate (z(2))
end


which is rejected with:

allocate (z(2))
  1
Error: Syntax error in ALLOCATE statement at (1)



The problem is that the class container is built too early (and thus we build a
container for a scalar class variable).

[Bug c++/71913] [5/6/7 Regression] Missing copy elision with operator new

2016-12-08 Thread P at draigBrady dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71913

Pádraig Brady  changed:

   What|Removed |Added

 CC||P at draigBrady dot com

--- Comment #13 from Pádraig Brady  ---
It would be good to have this backported to the 5 branch.
thanks

  1   2   >