[Bug rtl-optimization/63843] [5 Regression] wrong code generation at -O1 and higher

2014-11-19 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63843

--- Comment #4 from Jakub Jelinek jakub at gcc dot gnu.org ---
Author: jakub
Date: Wed Nov 19 08:18:53 2014
New Revision: 217753

URL: https://gcc.gnu.org/viewcvs?rev=217753root=gccview=rev
Log:
PR rtl-optimization/63843
* simplify-rtx.c (simplify_binary_operation_1) case ASHIFTRT: For
optimization of ashiftrt of subreg of lshiftrt, check that code
is ASHIFTRT.

* gcc.c-torture/execute/pr63843.c: New test.

Added:
trunk/gcc/testsuite/gcc.c-torture/execute/pr63843.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/simplify-rtx.c
trunk/gcc/testsuite/ChangeLog


[Bug tree-optimization/63947] Wrong assembly code generation

2014-11-19 Thread ubizjak at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63947

Uroš Bizjak ubizjak at gmail dot com changed:

   What|Removed |Added

 Status|UNCONFIRMED |ASSIGNED
   Last reconfirmed||2014-11-19
   Assignee|unassigned at gcc dot gnu.org  |ubizjak at gmail dot com
 Ever confirmed|0   |1

--- Comment #1 from Uroš Bizjak ubizjak at gmail dot com ---
Created attachment 34033
  -- https://gcc.gnu.org/bugzilla/attachment.cgi?id=34033action=edit
Patch to correct fcmov suffix

Untested patch.

[Bug target/63947] Wrong assembly code generation

2014-11-19 Thread ubizjak at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63947

Uroš Bizjak ubizjak at gmail dot com changed:

   What|Removed |Added

 Target||x86
  Component|tree-optimization   |target
   Target Milestone|--- |4.8.4

[Bug rtl-optimization/63843] [5 Regression] wrong code generation at -O1 and higher

2014-11-19 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63843

Jakub Jelinek jakub at gcc dot gnu.org changed:

   What|Removed |Added

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

--- Comment #5 from Jakub Jelinek jakub at gcc dot gnu.org ---
Fixed.


[Bug sanitizer/63813] [5 Regression][UBSAN] ICE in ubsan_type_descriptor, at ubsan.c:346

2014-11-19 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63813

Jakub Jelinek jakub at gcc dot gnu.org changed:

   What|Removed |Added

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

--- Comment #8 from Jakub Jelinek jakub at gcc dot gnu.org ---
Fixed.


[Bug c++/63946] [Compilation error] Compilation fails giving error in iomanip.

2014-11-19 Thread sch...@linux-m68k.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63946

Andreas Schwab sch...@linux-m68k.org changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution|--- |WONTFIX

--- Comment #1 from Andreas Schwab sch...@linux-m68k.org ---
You need to report that to RedHat, gcc 4.4 is no longer maintained.


[Bug c++/63928] [5 Regression] use after free in cp/constexpr.c

2014-11-19 Thread trippels at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63928

--- Comment #1 from Markus Trippelsdorf trippels at gcc dot gnu.org ---
Created attachment 34034
  -- https://gcc.gnu.org/bugzilla/attachment.cgi?id=34034action=edit
testcase

Also reproducible with valgrind:

trippels@gcc2-power8 c++11 % valgrind -q --track-origins=yes
--trace-children=yes ~/gcc_test/usr/local/bin/g++ -std=gnu++11 -O2 -w
condition_variable.ii
==80030== Invalid read of size 8
==80030==at 0x103EB1BC: cxx_eval_store_expression (constexpr.c:2552)
==80030==by 0x103EB1BC: cxx_eval_constant_expression(constexpr_ctx const*,
tree_node*, bool, bool*, bool*, tree_node**) (constexpr.c:2943)
==80030==by 0x103EACAB: cxx_eval_constant_expression(constexpr_ctx const*,
tree_node*, bool, bool*, bool*, tree_node**) (constexpr.c:2955)
==80030==by 0x103EB297: cxx_eval_constant_expression(constexpr_ctx const*,
tree_node*, bool, bool*, bool*, tree_node**) (constexpr.c:3047)
==80030==by 0x103EB66B: cxx_eval_constant_expression(constexpr_ctx const*,
tree_node*, bool, bool*, bool*, tree_node**) (constexpr.c:3214)
==80030==by 0x103E9A3B: cxx_eval_call_expression(constexpr_ctx const*,
tree_node*, bool, bool*, bool*) (constexpr.c:1328)
==80030==by 0x103EB623: cxx_eval_constant_expression(constexpr_ctx const*,
tree_node*, bool, bool*, bool*, tree_node**) (constexpr.c:2865)
==80030==by 0x103F0F7B: cxx_eval_outermost_constant_expr(tree_node*, bool,
tree_node*) (constexpr.c:3340)
==80030==by 0x103F5603: maybe_constant_value(tree_node*, tree_node*)
(constexpr.c:3453)
==80030==by 0x103506AB: finish_static_assert(tree_node*, tree_node*,
unsigned int, bool) (semantics.c:7046)
==80030==by 0x102B02C7: cp_parser_static_assert(cp_parser*, bool)
(parser.c:12139)
==80030==by 0x102D35EF: cp_parser_member_declaration(cp_parser*)
(parser.c:20673)
==80030==by 0x102A290B: cp_parser_member_specification_opt (parser.c:20542)
==80030==by 0x102A290B: cp_parser_class_specifier_1 (parser.c:19734)
==80030==by 0x102A290B: cp_parser_class_specifier (parser.c:19970)
==80030==by 0x102A290B: cp_parser_type_specifier(cp_parser*, int,
cp_decl_specifier_seq*, bool, int*, bool*) (parser.c:14630)
==80030==  Address 0xb69b348 is 104 bytes inside a block of size 208 free'd
==80030==at 0x407764C: free (vg_replace_malloc.c:473)
==80030==by 0x1022934B: data_free (hash-table.h:233)
==80030==by 0x1022934B: hash_tablehash_maptree_node*, tree_node*,
default_hashmap_traits::hash_entry, xcallocator, true::expand()
(hash-table.h:1346)
==80030==by 0x10229583: find_slot_with_hash (hash-table.h:1455)
==80030==by 0x10229583: hash_maptree_node*, tree_node*,
default_hashmap_traits::put(tree_node* const, tree_node* const)
(hash-map.h:207)
==80030==by 0x103EC5EF: cxx_eval_constant_expression(constexpr_ctx const*,
tree_node*, bool, bool*, bool*, tree_node**) (constexpr.c:2917)
==80030==by 0x103EB57F: cxx_eval_constant_expression(constexpr_ctx const*,
tree_node*, bool, bool*, bool*, tree_node**) (constexpr.c:2985)
==80030==by 0x103E93A3: cxx_bind_parameters_in_call (constexpr.c:1071)
==80030==by 0x103E93A3: cxx_eval_call_expression(constexpr_ctx const*,
tree_node*, bool, bool*, bool*) (constexpr.c:1234)
==80030==by 0x103EB623: cxx_eval_constant_expression(constexpr_ctx const*,
tree_node*, bool, bool*, bool*, tree_node**) (constexpr.c:2865)
==80030==by 0x103ED93F: cxx_eval_binary_expression(constexpr_ctx const*,
tree_node*, bool, bool*, bool*) (constexpr.c:1491)
==80030==by 0x103EB31F: cxx_eval_constant_expression(constexpr_ctx const*,
tree_node*, bool, bool*, bool*, tree_node**) (constexpr.c:3092)
==80030==by 0x103EB193: cxx_eval_store_expression (constexpr.c:2540)
==80030==by 0x103EB193: cxx_eval_constant_expression(constexpr_ctx const*,
tree_node*, bool, bool*, bool*, tree_node**) (constexpr.c:2943)
==80030==by 0x103EACAB: cxx_eval_constant_expression(constexpr_ctx const*,
tree_node*, bool, bool*, bool*, tree_node**) (constexpr.c:2955)
==80030==by 0x103EB297: cxx_eval_constant_expression(constexpr_ctx const*,
tree_node*, bool, bool*, bool*, tree_node**) (constexpr.c:3047)
==80030==


[Bug c/63944] [DR#413] Partial overriding of nonconstant struct/union initializers with designated initializers

2014-11-19 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63944

Jakub Jelinek jakub at gcc dot gnu.org changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2014-11-19
 Ever confirmed|0   |1

--- Comment #2 from Jakub Jelinek jakub at gcc dot gnu.org ---
I'm afraid I don't remember anything from my designated initializers changes,
it was too long time ago, so if anybody else (Joseph, Marek, anyone else?)
wants to implement this, go ahead ;).


[Bug c++/58930] [C++11] Bogus error: converting to ... from initializer list would use explicit constructor

2014-11-19 Thread paolo.carlini at oracle dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58930

Paolo Carlini paolo.carlini at oracle dot com changed:

   What|Removed |Added

 CC||filip.roseen at gmail dot com

--- Comment #10 from Paolo Carlini paolo.carlini at oracle dot com ---
*** Bug 60698 has been marked as a duplicate of this bug. ***


[Bug c++/60698] non-empty braced-init-list of non-static data member T[N] in class template results in error diagnostic, if T is a class

2014-11-19 Thread paolo.carlini at oracle dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60698

Paolo Carlini paolo.carlini at oracle dot com changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution|--- |DUPLICATE

--- Comment #1 from Paolo Carlini paolo.carlini at oracle dot com ---
Dup.

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


[Bug c++/58930] [C++11] Bogus error: converting to ... from initializer list would use explicit constructor

2014-11-19 Thread paolo.carlini at oracle dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58930

--- Comment #11 from Paolo Carlini paolo.carlini at oracle dot com ---
Let's adjust the Milestone: with the backport these bugs are fixed for 4.9.1.


[Bug c++/58930] [C++11] Bogus error: converting to ... from initializer list would use explicit constructor

2014-11-19 Thread paolo.carlini at oracle dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58930

Paolo Carlini paolo.carlini at oracle dot com changed:

   What|Removed |Added

   Target Milestone|5.0 |4.9.1


[Bug c++/58753] Brace-initializing a vector with a direct-initialization NSDMI doesn't work in a template

2014-11-19 Thread paolo.carlini at oracle dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58753

Paolo Carlini paolo.carlini at oracle dot com changed:

   What|Removed |Added

   Target Milestone|5.0 |4.9.1


[Bug libgcc/63882] internal compiler error: in int_mode_for_mode, at stor-layout.c:395

2014-11-19 Thread aiencai at 126 dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63882

--- Comment #1 from aiencai at 126 dot com ---
According to further exploration,mpc has nothing to do with this problem. This
problem is caused by configuration options '--disable-bootstrap' and
'--enable-languages=c++,lto'

[Bug sanitizer/63913] [5 Regression] ICE: verify_gimple failed: statement marked for throw, but doesn't with -fnon-call-exceptions -fsanitize=bool

2014-11-19 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63913

--- Comment #4 from Jakub Jelinek jakub at gcc dot gnu.org ---
Author: jakub
Date: Wed Nov 19 09:27:30 2014
New Revision: 217755

URL: https://gcc.gnu.org/viewcvs?rev=217755root=gccview=rev
Log:
PR sanitizer/63913
* ubsan.c: Include tree-eh.h.
(instrument_bool_enum_load): Handle loads that can throw.

* g++.dg/ubsan/pr63913.C: New test.

Added:
trunk/gcc/testsuite/g++.dg/ubsan/pr63913.C
Modified:
trunk/gcc/ChangeLog
trunk/gcc/testsuite/ChangeLog
trunk/gcc/ubsan.c


[Bug c++/57654] [c++11] static class member reference-to-a-reference will not compile

2014-11-19 Thread paolo.carlini at oracle dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=57654

Paolo Carlini paolo.carlini at oracle dot com changed:

   What|Removed |Added

Summary|[c++11][constexpr] static   |[c++11] static class member
   |class member|reference-to-a-reference
   |reference-to-a-reference|will not compile
   |will not compile|

--- Comment #1 from Paolo Carlini paolo.carlini at oracle dot com ---
This is fixed for 4.9.0. I'm adding the testcase and closing the bug.


[Bug tree-optimization/63677] Failure to constant fold with vectorization.

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63677

--- Comment #5 from Richard Biener rguenth at gcc dot gnu.org ---
With the patch from PR63864 we still don't optimize:

  bb 2:
  vect_cst_.12_23 = { 0, 1, 2, 3 };
  vect_cst_.11_32 = { 4, 5, 6, 7 };
  vectp.14_2 = a[0];
  MEM[(int *)a] = { 0, 1, 2, 3 };
  vectp.14_21 = a[0] + 16;
  MEM[(int *)vectp.14_21] = { 4, 5, 6, 7 };
  vectp_a.5_22 = a;
  vect__13.6_20 = MEM[(int *)a];

this is because while seeing the candidate MEM[(int *)a] = { 0, 1, 2, 3 };
for the load vect__13.6_20 = MEM[(int *)a]; we fail to disambiguate
against the store to MEM[(int *)vectp.14_21] which is not simplified
to MEM[a, 16] = { 4, 5, 6, 7 }; because DOM does not have the trick
of representing invariant-ptr + CST as MEM[..., CST'] for propagation.

If I fix that (huh, not sure why we don't simply fold the pointer-plus that
way,
now four places do that trick for propagation...) then it works:

LKUP STMT vect__13.6_20 = MEM[(int *)a]
  vect__13.6_20 = MEM[(int *)a];
FIND: { 0, 1, 2, 3 }
  Replaced redundant expr 'MEM[(int *)a]' with '{ 0, 1, 2, 3 }'

t.c.183t.optimized:

foo ()
{
  bb 2:
  return 28;

}


[Bug c++/57654] [c++11] static class member reference-to-a-reference will not compile

2014-11-19 Thread paolo.carlini at oracle dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=57654

Paolo Carlini paolo.carlini at oracle dot com changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution|--- |FIXED
   Target Milestone|--- |4.9.0

--- Comment #3 from Paolo Carlini paolo.carlini at oracle dot com ---
Done.


[Bug c++/57654] [c++11] static class member reference-to-a-reference will not compile

2014-11-19 Thread paolo at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=57654

--- Comment #2 from paolo at gcc dot gnu.org paolo at gcc dot gnu.org ---
Author: paolo
Date: Wed Nov 19 09:36:40 2014
New Revision: 217756

URL: https://gcc.gnu.org/viewcvs?rev=217756root=gccview=rev
Log:
2014-11-19  Paolo Carlini  paolo.carl...@oracle.com

PR c++/57654
* g++.dg/cpp0x/constexpr-ref7.C: New.

Added:
trunk/gcc/testsuite/g++.dg/cpp0x/constexpr-ref7.C
Modified:
trunk/gcc/testsuite/ChangeLog


[Bug sanitizer/62141] [GCC-4.10.0][ASAN] ICE: Segmentation fault: 11

2014-11-19 Thread fxcoudert at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62141

Francois-Xavier Coudert fxcoudert at gcc dot gnu.org changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |FIXED
   Target Milestone|--- |5.0

--- Comment #6 from Francois-Xavier Coudert fxcoudert at gcc dot gnu.org ---
The ICE is gone for me (trunk revision 217694 with patch at
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63534#c50), and testcase
Wsizeof-pointer-memaccess1.c now passes. Thus probably IPA related, and now
fixed.


[Bug c++/60399] constexpr ctor that does not init an attribute should be rejected but isn't

2014-11-19 Thread paolo.carlini at oracle dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60399

Paolo Carlini paolo.carlini at oracle dot com changed:

   What|Removed |Added

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

--- Comment #2 from Paolo Carlini paolo.carlini at oracle dot com ---
Closing then.


[Bug tree-optimization/63844] [4.8/4.9/5 Regression] open mp parallelization prevents vectorization

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63844

--- Comment #14 from Richard Biener rguenth at gcc dot gnu.org ---
Author: rguenth
Date: Wed Nov 19 09:47:19 2014
New Revision: 217757

URL: https://gcc.gnu.org/viewcvs?rev=217757root=gccview=rev
Log:
2014-11-19  Richard Biener  rguent...@suse.de

PR tree-optimization/63844
* omp-low.c (fixup_child_record_type): Use a restrict qualified
referece type for the receiver parameter.

Modified:
trunk/gcc/ChangeLog
trunk/gcc/omp-low.c


[Bug tree-optimization/63844] [4.8/4.9 Regression] open mp parallelization prevents vectorization

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63844

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

  Known to work||5.0
Summary|[4.8/4.9/5 Regression] open |[4.8/4.9 Regression] open
   |mp parallelization prevents |mp parallelization prevents
   |vectorization   |vectorization

--- Comment #15 from Richard Biener rguenth at gcc dot gnu.org ---
Fixed on trunk(?)


[Bug sanitizer/63520] ICE: in get_biv_step, at loop-iv.c:824 with -fsanitize=undefined on ppc64

2014-11-19 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63520

--- Comment #12 from Jakub Jelinek jakub at gcc dot gnu.org ---
Author: jakub
Date: Wed Nov 19 09:49:18 2014
New Revision: 217758

URL: https://gcc.gnu.org/viewcvs?rev=217758root=gccview=rev
Log:
PR sanitizer/63520
* internal-fn.c (expand_ubsan_result_store): New function.
(expand_addsub_overflow, expand_neg_overflow, expand_mul_overflow):
Use it instead of just emit_move_insn.

* c-c++-common/ubsan/pr63520.c: New test.

Added:
trunk/gcc/testsuite/c-c++-common/ubsan/pr63520.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/internal-fn.c
trunk/gcc/testsuite/ChangeLog


[Bug tree-optimization/63915] gomp/pr60823-2.c:31:1: error: dead STMT in EH table

2014-11-19 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63915

--- Comment #3 from Jakub Jelinek jakub at gcc dot gnu.org ---
Author: jakub
Date: Wed Nov 19 09:50:58 2014
New Revision: 217759

URL: https://gcc.gnu.org/viewcvs?rev=217759root=gccview=rev
Log:
PR tree-optimization/63915
* tree-vect-stmts.c (vectorizable_simd_clone_call): Pass
true instead of false as last argument to gsi_replace.

* c-c++-common/gomp/pr60823-4.c: New test.

Added:
trunk/gcc/testsuite/c-c++-common/gomp/pr60823-4.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/testsuite/ChangeLog
trunk/gcc/tree-vect-stmts.c


[Bug libstdc++/63942] [5.0 Regression] constexpr conflicts with previous declaration

2014-11-19 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63942

--- Comment #1 from Jonathan Wakely redi at gcc dot gnu.org ---
I think this must be a front end issue, not libstdc++


[Bug c++/63942] [5.0 Regression] constexpr conflicts with previous declaration

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63942

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

  Component|libstdc++   |c++
   Target Milestone|--- |5.0


[Bug tree-optimization/63941] [5 Regression] ICE on valid code at -O3 and above on x86_64-linux-gnu

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63941

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Priority|P3  |P1


[Bug sanitizer/63948] New: Sanitizer testsuite full of failures on darwin

2014-11-19 Thread fxcoudert at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63948

Bug ID: 63948
   Summary: Sanitizer testsuite full of failures on darwin
   Product: gcc
   Version: 5.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: sanitizer
  Assignee: unassigned at gcc dot gnu.org
  Reporter: fxcoudert at gcc dot gnu.org
CC: dodji at gcc dot gnu.org, dvyukov at gcc dot gnu.org,
jakub at gcc dot gnu.org, kcc at gcc dot gnu.org

sanitizer's testsuite is full of failures on x86_64-apple-darwin14, to the
point of making test results hardly readable:
https://gcc.gnu.org/ml/gcc-testresults/2014-11/msg01921.html

Maybe there are some real failures in there, but it seems they're mostly
failures to match output, like global-overflow-1.c, where we output this:

==41438==ERROR: AddressSanitizer: global-buffer-overflow on address
0x000101ce122a at pc 0x000101ce0d88 bp 0x7fff5df1fa10 sp 0x7fff5df1fa08
READ of size 1 at 0x000101ce122a thread T0
#0 0x101ce0d87  (/Users/fx/devel/gcc/irun2/./a.out+0x10d87)
#1 0x7fff942575c8  (/usr/lib/system/libdyld.dylib+0x35c8)
#2 0x0  (unknown module)

0x000101ce122a is located 0 bytes to the right of global variable 'YYY' defined
in 'global-overflow-1.c:15:15' (0x101ce1220) of size 10
0x000101ce122a is located 54 bytes to the left of global variable 'ZZZ' defined
in 'global-overflow-1.c:16:15' (0x101ce1260) of size 10

and I believe this does not match the regexp in the testcase:

/* { dg-output READ of size 1 at 0x\[0-9a-f\]+ thread T0.*(\n|\r\n|\r) } */
/* { dg-output #0 0x\[0-9a-f\]+ (in _*main
(\[^\n\r]*global-overflow-1.c:20|\[^\n\r]*:0)|\[(\])\[^\n\r]*(\n|\r\n|\r).* }
*/
/* { dg-output 0x\[0-9a-f\]+ is located 0 bytes to the right of global
variable } */
/* { dg-output .*YYY\[^\n\r]* of size 10\[^\n\r]*(\n|\r\n|\r) } */

(though that second line is hard to parse). I suppose the dg-output expects
symbol names, and they are not produced on darwin. In the meantime, the
testcases should be amended.


[Bug testsuite/63939] [5 Regression] Massive asan failures (356) on x86_64-apple-darwin14

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63939

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|--- |5.0


[Bug c++/59296] [c++11] ref-qualified member function is ambiguous

2014-11-19 Thread paolo.carlini at oracle dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59296

Paolo Carlini paolo.carlini at oracle dot com changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 CC|jason at gcc dot gnu.org   |
 Resolution|--- |FIXED
   Target Milestone|--- |4.9.1

--- Comment #8 from Paolo Carlini paolo.carlini at oracle dot com ---
Fixed for 4.9.1 then.


[Bug c++/63935] internal compiler error: output_operand: invalid expression as operand

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63935

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
  Known to work||4.9.0, 4.9.2
 Resolution|--- |FIXED
  Known to fail||4.9.1

--- Comment #1 from Richard Biener rguenth at gcc dot gnu.org ---
This was fixed in 4.9.2 and there is probably a duplicate bugreport.


[Bug target/59843] ICE with return of generic vector on aarch64

2014-11-19 Thread alalaw01 at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59843

alalaw01 at gcc dot gnu.org changed:

   What|Removed |Added

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

--- Comment #13 from alalaw01 at gcc dot gnu.org ---
Fixed on trunk in r211502 and backported to 4.9.


[Bug go/63812] Compilation error due to a large floating point constant truncated to integer

2014-11-19 Thread e29253 at jp dot ibm.com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63812

--- Comment #5 from Tatsushi Inagaki e29253 at jp dot ibm.com ---
Submitted a pull request to Docker:
https://github.com/docker/docker/pull/9233


[Bug target/63949] New: Aarch64 instruction combiner does not optimize subsi_sxth function as expected

2014-11-19 Thread vekumar at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63949

Bug ID: 63949
   Summary: Aarch64 instruction combiner does not optimize
subsi_sxth function as expected
   Product: gcc
   Version: 5.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: target
  Assignee: unassigned at gcc dot gnu.org
  Reporter: vekumar at gcc dot gnu.org

Reference: https://bugs.linaro.org/show_bug.cgi?id=863

Test case 

int   subsi_sxth (int a, short  i)
{
  /* { dg-final { scan-assembler sub\tw\[0-9\]+,.*sxth #?1 } } */
  return a - ((int)i  1);
}

Assembly generated with GCC 5.0.0 20141114

subsi_sxth:
sbfiz   w1, w1, 1, 16
sub w0, w0, w1
ret

Expected 
   subww0,w0,w1,sxth 1


Combiner Says Failed to mismatch 

set (reg/i:SI 0 x0)
(minus:SI (reg:SI 0 x0 [ a ])
(subreg:SI (sign_extract:DI (mult:DI (reg:DI 1 x1 [ i ])
(const_int 2 [0x2]))
(const_int 17 [0x11])
(const_int 0 [0])) 0)))

We have a pattern that would match in aarch64.md file, but it is not
recognized.

(define_insn *sub_optabmode_multp2
   [(set (match_operand:GPI 0 register_operand =rk)
 (minus:GPI (match_operand:GPI 4 register_operand r)
(ANY_EXTRACT:GPI
 (mult:GPI (match_operand:GPI 1 register_operand r)
   (match_operand 2 aarch64_pwr_imm3 Up3))
 (match_operand 3 const_int_operand n)
 (const_int 0]
   aarch64_is_extend_from_extract (MODEmode, operands[2], operands[3])
   sub\\t%w0, %w4, %w1, suxt%e3 %p2
   [(set_attr type alu_ext)]
 )


[Bug c++/55425] constexpr does not work in many situations (both built-in and user supplied literals)

2014-11-19 Thread paolo.carlini at oracle dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55425

--- Comment #7 from Paolo Carlini paolo.carlini at oracle dot com ---
I think we can close this. The __func__ snippet now works in mainline with
-std=c++14, I'm adding it to the testsuite.


[Bug target/63950] New: [AArch64] ICE at -O0 on vld1_lane intrinsics

2014-11-19 Thread alalaw01 at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63950

Bug ID: 63950
   Summary: [AArch64] ICE at -O0 on vld1_lane intrinsics
   Product: gcc
   Version: 5.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: target
  Assignee: unassigned at gcc dot gnu.org
  Reporter: alalaw01 at gcc dot gnu.org

Testcase

#include arm_neon.h

int8x8_t
f_vld1_lane (int8_t * p, int8x8_t v)
{
  int8x8_t res;
  res = vld1_lane_s8 (p, v, 1);
  return res;
}

$ aarch64-none-elf-gcc -S test.c

In file included from neon_const_range_tests/vld1.c:2:0:
/work/alalaw01/sbuild/install/lib/gcc/aarch64-none-elf/5.0.0/include/arm_neon.h:
In function 'f_vld1_lane':
/work/alalaw01/sbuild/install/lib/gcc/aarch64-none-elf/5.0.0/include/arm_neon.h:658:10:
internal compiler error: in aarch64_simd_lane_bounds, at
config/aarch64/aarch64.c:8394
   return __aarch64_vset_lane_any (__vec, __index, __elem, 8);
  ^
0xf9419d aarch64_simd_lane_bounds(rtx_def*, long, long)
/work/alalaw01/svn/gcc/gcc/config/aarch64/aarch64.c:8394
0xfffcf4 gen_aarch64_im_lane_boundsi(rtx_def*, rtx_def*)
/work/alalaw01/svn/gcc/gcc/config/aarch64/aarch64-simd.md:4524
0x7cc10e insn_gen_fn::operator()(rtx_def*, rtx_def*) const
/work/alalaw01/svn/gcc/gcc/recog.h:303
0xf9a366 aarch64_simd_expand_args
/work/alalaw01/svn/gcc/gcc/config/aarch64/aarch64-builtins.c:970
0xf9a703 aarch64_simd_expand_builtin(int, tree_node*, rtx_def*)
/work/alalaw01/svn/gcc/gcc/config/aarch64/aarch64-builtins.c:1051
0xf9ac21 aarch64_expand_builtin(tree_node*, rtx_def*, rtx_def*, machine_mode,
int)
/work/alalaw01/svn/gcc/gcc/config/aarch64/aarch64-builtins.c:1133

.

Seems to be caused by lack of constant propagation at -O0, compiles fine at -O1
and higher.


[Bug target/63951] New: [5 Regression] bootstrap failure (ICE in adjust_temp_type) on arm-linux-gnueabi{,hf} building the libstdc++ pch file

2014-11-19 Thread doko at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63951

Bug ID: 63951
   Summary: [5 Regression] bootstrap failure (ICE in
adjust_temp_type) on arm-linux-gnueabi{,hf} building
the libstdc++ pch file
   Product: gcc
   Version: unknown
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: target
  Assignee: unassigned at gcc dot gnu.org
  Reporter: doko at gcc dot gnu.org

seen with both arm-linux-gnueabi and arm-linux-gnueabihf

make[7]: Entering directory
'/home/doko/gcc/gcc-snapshot-20141118/build/arm-linux-gnue
abihf/libstdc++-v3/include'
mkdir -p ./arm-linux-gnueabihf/bits/stdc++.h.gch
/home/doko/gcc/gcc-snapshot-20141118/build/./gcc/xgcc -shared-libgcc
-B/home/doko/gcc/
gcc-snapshot-20141118/build/./gcc -nostdinc++
-L/home/doko/gcc/gcc-snapshot-20141118/b
uild/arm-linux-gnueabihf/libstdc++-v3/src
-L/home/doko/gcc/gcc-snapshot-20141118/build
/arm-linux-gnueabihf/libstdc++-v3/src/.libs
-L/home/doko/gcc/gcc-snapshot-20141118/bui
ld/arm-linux-gnueabihf/libstdc++-v3/libsupc++/.libs
-B/usr/lib/gcc-snapshot/arm-linux-
gnueabihf/bin/ -B/usr/lib/gcc-snapshot/arm-linux-gnueabihf/lib/ -isystem
/usr/lib/gcc-
snapshot/arm-linux-gnueabihf/include -isystem
/usr/lib/gcc-snapshot/arm-linux-gnueabih
f/sys-include-x c++-header -nostdinc++ -g -O2 -D_GNU_SOURCE 
-I/home/doko/gcc/gcc-
snapshot-20141118/build/arm-linux-gnueabihf/libstdc++-v3/include/arm-linux-gnueabihf
-
I/home/doko/gcc/gcc-snapshot-20141118/build/arm-linux-gnueabihf/libstdc++-v3/include
-
I/home/doko/gcc/gcc-snapshot-20141118/src/libstdc++-v3/libsupc++ -O2 -g
-std=gnu++0x /
home/doko/gcc/gcc-snapshot-20141118/src/libstdc++-v3/include/precompiled/stdc++.h
\
-o arm-linux-gnueabihf/bits/stdc++.h.gch/O2ggnu++0x.gch
In file included from
/home/doko/gcc/gcc-snapshot-20141118/src/libstdc++-v3/include/pr
ecompiled/stdc++.h:100:0:
/home/doko/gcc/gcc-snapshot-20141118/build/arm-linux-gnueabihf/libstdc++-v3/include/ch
rono:723:49:   in constexpr expansion of 'std::chrono::duration_Rep,
_Period::minlo
ng long int, std::ratio1ll, 10ll ()'
/home/doko/gcc/gcc-snapshot-20141118/build/arm-linux-gnueabihf/libstdc++-v3/include/ch
rono:725:66:   in constexpr expansion of 'std::chrono::durationlong long int,
std::ra
tio1ll, 10ll ((*  std::chrono::duration_values_Rep::minlong long
int()
))'
/home/doko/gcc/gcc-snapshot-20141118/build/arm-linux-gnueabihf/libstdc++-v3/include/ch
rono:725:66: internal compiler error: in adjust_temp_type, at
cp/constexpr.c:1020
   a clock's minimum duration cannot be less than its epoch);
  ^
0x46620b adjust_temp_type
../../src/gcc/cp/constexpr.c:1020
0x4675c9 cxx_eval_call_expression
../../src/gcc/cp/constexpr.c:1377
0x46bee9 cxx_eval_constant_expression
../../src/gcc/cp/constexpr.c:2835
0x46c399 cxx_eval_constant_expression
../../src/gcc/cp/constexpr.c:2895
0x46b05b cxx_eval_store_expression
../../src/gcc/cp/constexpr.c:2529
0x46c3f5 cxx_eval_constant_expression
../../src/gcc/cp/constexpr.c:2914
0x46c479 cxx_eval_constant_expression
../../src/gcc/cp/constexpr.c:2926
0x46c4c1 cxx_eval_constant_expression
../../src/gcc/cp/constexpr.c:2940
0x46729d cxx_eval_call_expression
../../src/gcc/cp/constexpr.c:1329
0x46bee9 cxx_eval_constant_expression
../../src/gcc/cp/constexpr.c:2835
0x46c399 cxx_eval_constant_expression
../../src/gcc/cp/constexpr.c:2895
0x46c523 cxx_eval_constant_expression
../../src/gcc/cp/constexpr.c:2958
0x46ca47 cxx_eval_constant_expression
../../src/gcc/cp/constexpr.c:3147
0x46ca47 cxx_eval_constant_expression
../../src/gcc/cp/constexpr.c:3147
0x46646b cxx_bind_parameters_in_call
../../src/gcc/cp/constexpr.c:1072
0x466dbd cxx_eval_call_expression
../../src/gcc/cp/constexpr.c:1235
0x46bee9 cxx_eval_constant_expression
../../src/gcc/cp/constexpr.c:2835
0x46d309 cxx_eval_outermost_constant_expr
../../src/gcc/cp/constexpr.c:3314
0x46d96f maybe_constant_value(tree_node*, tree_node*)
../../src/gcc/cp/constexpr.c:3427
0x3fb8f3 finish_static_assert(tree_node*, tree_node*, unsigned int, bool)
../../src/gcc/cp/semantics.c:7046
Please submit a full bug report,
with preprocessed source if appropriate.

armhf configured with
 --with-arch=armv7-a
 --with-fpu=vfpv3-d16
 --with-float=hard
 --with-mode=thumb


[Bug target/63951] [5 Regression] bootstrap failure (ICE in adjust_temp_type) on arm-linux-gnueabi{,hf} building the libstdc++ pch file

2014-11-19 Thread doko at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63951

--- Comment #1 from Matthias Klose doko at gcc dot gnu.org ---
trunk r217719


[Bug c++/55425] constexpr does not work in many situations (both built-in and user supplied literals)

2014-11-19 Thread paolo.carlini at oracle dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55425

--- Comment #8 from Paolo Carlini paolo.carlini at oracle dot com ---
Uhm, in fact probably it should be accepted with -std=c++11 too, let's wait a
second.


[Bug target/63952] New: [5 Regression] bootstrap failure (ICE in prepare_cmp_insn) on s390x in libjava

2014-11-19 Thread doko at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63952

Bug ID: 63952
   Summary: [5 Regression] bootstrap failure (ICE in
prepare_cmp_insn) on s390x in libjava
   Product: gcc
   Version: unknown
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: target
  Assignee: unassigned at gcc dot gnu.org
  Reporter: doko at gcc dot gnu.org

trunk r217719

/«PKGBUILDDIR»/src/libjava/classpath/gnu/java/net/protocol/ftp/FTPConnection.java:659:0:
internal compiler error: in prepare_cmp_insn, at optabs.c:4170
   }
 ^
Please submit a full bug report,
with preprocessed source if appropriate.

[Bug target/63954] New: msp430 multiplication unsafe for use in interrupts

2014-11-19 Thread pab at pabigot dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63954

Bug ID: 63954
   Summary: msp430 multiplication unsafe for use in interrupts
   Product: gcc
   Version: 5.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: target
  Assignee: unassigned at gcc dot gnu.org
  Reporter: pab at pabigot dot com

The msp430-elf target currently implements integer multiplication by calls to a
function that invokes the hardware peripheral by loading peripheral registers
and reading results.  The functions that implement the multiplication are not
protected against interrupts.

A consequence is that a calculation performed in an application with interrupts
enabled will be corrupted if an interrupt handler that includes an integer
multiplication operation is invoked during the application code.

Until this is fixed users should not invoke multiplications from within
interrupt handlers, or from any code called by interrupt handlers (including
unspecified functions within the standard C library).


[Bug target/63953] New: msp430 fails to define multiplier for msp430fr5xx mcus

2014-11-19 Thread pab at pabigot dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63953

Bug ID: 63953
   Summary: msp430 fails to define multiplier for msp430fr5xx mcus
   Product: gcc
   Version: 5.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: target
  Assignee: unassigned at gcc dot gnu.org
  Reporter: pab at pabigot dot com

Code generated with -mmcu=msp430fr5969 results in calls to the default hardware
multiplier, which is not the correct solution for this MCU.  Other MCUs may
also be missing.  See https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63901#c3 for
a robust solution approach.


[Bug tree-optimization/62167] [4.8 Regression][tail-merge] dead type-unsafe load replaces type-safe load

2014-11-19 Thread vries at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62167

--- Comment #3 from vries at gcc dot gnu.org ---
Author: vries
Date: Wed Nov 19 10:44:58 2014
New Revision: 217761

URL: https://gcc.gnu.org/viewcvs?rev=217761root=gccview=rev
Log:
Fix tail-merge pass for dead type-unsafe code

2014-11-19  Tom de Vries  t...@codesourcery.com

PR tree-optimization/62167
* tree-ssa-tail-merge.c (stmt_local_def): Handle statements with vuse
conservatively.
(gimple_equal_p): Don't use vn_valueize to compare for lhs equality of
assigns.

* gcc.dg/pr51879-12.c: Add xfails.
* gcc.dg/pr62167-run.c: New test.
* gcc.dg/pr62167.c: New test.

Added:
trunk/gcc/testsuite/gcc.dg/pr62167-run.c
trunk/gcc/testsuite/gcc.dg/pr62167.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/testsuite/ChangeLog
trunk/gcc/testsuite/gcc.dg/pr51879-12.c
trunk/gcc/tree-ssa-tail-merge.c


[Bug tree-optimization/62167] [4.8 Regression][tail-merge] dead type-unsafe load replaces type-safe load

2014-11-19 Thread vries at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62167

--- Comment #4 from vries at gcc dot gnu.org ---
Author: vries
Date: Wed Nov 19 10:50:42 2014
New Revision: 217763

URL: https://gcc.gnu.org/viewcvs?rev=217763root=gccview=rev
Log:
Fix tail-merge pass for dead type-unsafe code

2014-11-19  Tom de Vries  t...@codesourcery.com

Backport from mainline
PR tree-optimization/62167
* tree-ssa-tail-merge.c (stmt_local_def): Handle statements with vuse
conservatively.
(gimple_equal_p): Don't use vn_valueize to compare for lhs equality of
assigns.

* gcc.dg/pr51879-12.c: Add xfails.
* gcc.dg/pr62167-run.c: New test.
* gcc.dg/pr62167.c: New test.

Added:
branches/gcc-4_9-branch/gcc/testsuite/gcc.dg/pr62167-run.c
branches/gcc-4_9-branch/gcc/testsuite/gcc.dg/pr62167.c
Modified:
branches/gcc-4_9-branch/gcc/ChangeLog
branches/gcc-4_9-branch/gcc/testsuite/ChangeLog
branches/gcc-4_9-branch/gcc/testsuite/gcc.dg/pr51879-12.c
branches/gcc-4_9-branch/gcc/tree-ssa-tail-merge.c


[Bug tree-optimization/62167] [4.8 Regression][tail-merge] dead type-unsafe load replaces type-safe load

2014-11-19 Thread vries at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62167

--- Comment #5 from vries at gcc dot gnu.org ---
Author: vries
Date: Wed Nov 19 11:08:02 2014
New Revision: 217764

URL: https://gcc.gnu.org/viewcvs?rev=217764root=gccview=rev
Log:
Fix tail-merge pass for dead type-unsafe code

2014-11-19  Tom de Vries  t...@codesourcery.com

Backport from mainline
PR tree-optimization/62167
* tree-ssa-tail-merge.c (stmt_local_def): Handle statements with vuse
conservatively.
(gimple_equal_p): Don't use vn_valueize to compare for lhs equality of
assigns.

* gcc.dg/pr51879-12.c: Add xfails.
* gcc.dg/pr62167-run.c: New test.
* gcc.dg/pr62167.c: New test.

Added:
branches/gcc-4_8-branch/gcc/testsuite/gcc.dg/pr62167-run.c
branches/gcc-4_8-branch/gcc/testsuite/gcc.dg/pr62167.c
Modified:
branches/gcc-4_8-branch/gcc/ChangeLog
branches/gcc-4_8-branch/gcc/testsuite/ChangeLog
branches/gcc-4_8-branch/gcc/testsuite/gcc.dg/pr51879-12.c
branches/gcc-4_8-branch/gcc/tree-ssa-tail-merge.c


[Bug web/63955] New: Remove pr51879-12.c xfail

2014-11-19 Thread vries at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63955

Bug ID: 63955
   Summary: Remove pr51879-12.c xfail
   Product: gcc
   Version: 5.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: web
  Assignee: unassigned at gcc dot gnu.org
  Reporter: vries at gcc dot gnu.org

The fix for PR 62167 - '[4.8 Regression][tail-merge] dead type-unsafe load
replaces type-safe load' adds an xfail for pr51879-12.c.

We want the test to pass again.

pr51879-12.c:
...
/* { dg-do compile } */
/* { dg-options -O2 -fdump-tree-pre } */

__attribute__((pure)) int bar (int);
__attribute__((pure)) int bar2 (int);
void baz (int);

int x, z;

void
foo (int y)
{
  int a = 0;
  if (y == 6)
{
  a += bar (7);
  a += bar2 (6);
}
  else
{
  a += bar2 (6);
  a += bar (7);
}
  baz (a);
}

/* { dg-final { scan-tree-dump-times bar \\( 1 pre { xfail *-*-* } } } */
/* { dg-final { scan-tree-dump-times bar2 \\( 1 pre { xfail *-*-* } } } */
/* { dg-final { cleanup-tree-dump pre } } */
...


[Bug sanitizer/63956] New: [5 Regression][UBSAN] ICE segfault in cxx_eval_call_expression ../../gcc/cp/constexpr.c

2014-11-19 Thread burnus at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63956

Bug ID: 63956
   Summary: [5 Regression][UBSAN] ICE segfault in
cxx_eval_call_expression ../../gcc/cp/constexpr.c
   Product: gcc
   Version: 5.0
Status: UNCONFIRMED
  Keywords: ice-on-valid-code
  Severity: normal
  Priority: P3
 Component: sanitizer
  Assignee: unassigned at gcc dot gnu.org
  Reporter: burnus at gcc dot gnu.org
CC: dodji at gcc dot gnu.org, dvyukov at gcc dot gnu.org,
jakub at gcc dot gnu.org, kcc at gcc dot gnu.org,
mpolacek at gcc dot gnu.org

Created attachment 34035
  -- https://gcc.gnu.org/bugzilla/attachment.cgi?id=34035action=edit
Test case (scan16.ii)

That's a new regression. It was working when I reduce PR63813 (i.e. on
2014-11-11) as that ICE came later. It now ICEs with todays GCC (r217759).

g++ -S -std=c++11 -fsanitize=undefined scan16.ii

scan16.ii:51:28:   in constexpr expansion of
‘std::validator.std::unique_ptrstd::Validator::unique_ptr()’
scan16.ii:51:28: internal compiler error: Segmentation fault
   unique_ptr  Validator  validator;
^
0xcba72f crash_signal
../../gcc/toplev.c:359
0x81ea9a cxx_eval_call_expression
../../gcc/cp/constexpr.c:1147
0x820b1c cxx_eval_constant_expression
../../gcc/cp/constexpr.c:2864

[Bug tree-optimization/62167] [4.8 Regression][tail-merge] dead type-unsafe load replaces type-safe load

2014-11-19 Thread vries at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62167

vries at gcc dot gnu.org changed:

   What|Removed |Added

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

--- Comment #6 from vries at gcc dot gnu.org ---
patch and testcases committed to trunk, propagated to 4.8 and 4.9

Filed followup PR (PR63955 - Remove pr51879-12.c xfail) for xfail.

Marking resolved fixed.


[Bug target/63954] msp430 multiplication unsafe for use in interrupts

2014-11-19 Thread pab at pabigot dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63954

Peter A. Bigot pab at pabigot dot com changed:

   What|Removed |Added

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

--- Comment #1 from Peter A. Bigot pab at pabigot dot com ---
Sorry, bogus: the necessary dint/conditional eint are present in the macro
wrappers.


[Bug sanitizer/63956] [5 Regression][UBSAN] ICE segfault in cxx_eval_call_expression ../../gcc/cp/constexpr.c

2014-11-19 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63956

Marek Polacek mpolacek at gcc dot gnu.org changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2014-11-19
   Target Milestone|--- |5.0
 Ever confirmed|0   |1

--- Comment #1 from Marek Polacek mpolacek at gcc dot gnu.org ---
Confirmed.


[Bug tree-optimization/63957] New: rename -fuse-caller-save to -fipa-ra

2014-11-19 Thread vries at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63957

Bug ID: 63957
   Summary: rename -fuse-caller-save to -fipa-ra
   Product: gcc
   Version: 5.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: tree-optimization
  Assignee: unassigned at gcc dot gnu.org
  Reporter: vries at gcc dot gnu.org

As discussed in gcc-patches thread ending at
https://gcc.gnu.org/ml/gcc-patches/2014-10/msg01943.html .

Should be done for 5.0.


[Bug sanitizer/63956] [5 Regression][UBSAN] ICE segfault in cxx_eval_call_expression ../../gcc/cp/constexpr.c

2014-11-19 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63956

--- Comment #2 from Marek Polacek mpolacek at gcc dot gnu.org ---
It looks like cxx_eval_call_expression just isn't prepared for internal
functions, with NULL_TREE CALL_EXPR_FN.


[Bug web/63955] Remove pr51879-12.c xfail

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63955

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2014-11-19
 Ever confirmed|0   |1

--- Comment #1 from Richard Biener rguenth at gcc dot gnu.org ---
Confirmed.


[Bug target/63952] [5 Regression] bootstrap failure (ICE in prepare_cmp_insn) on s390x in libjava

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63952

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Priority|P3  |P1
Version|unknown |5.0
   Target Milestone|--- |5.0


[Bug rtl-optimization/63957] [5 Regression] rename -fuse-caller-save to -fipa-ra

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63957

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Priority|P3  |P1
  Component|tree-optimization   |rtl-optimization
   Target Milestone|--- |5.0
Summary|rename -fuse-caller-save to |[5 Regression] rename
   |-fipa-ra|-fuse-caller-save to
   ||-fipa-ra

--- Comment #1 from Richard Biener rguenth at gcc dot gnu.org ---
Marking as P1 regression so we don't forget.


[Bug target/63951] [5 Regression] bootstrap failure (ICE in adjust_temp_type) on arm-linux-gnueabi{,hf} building the libstdc++ pch file

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63951

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Priority|P3  |P1
Version|unknown |5.0
   Target Milestone|--- |5.0


[Bug ada/63931] [5 Regression] Ada libraries use 5.0 as LIB_VERSION

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63931

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Priority|P3  |P1
   Target Milestone|--- |5.0
Summary|Ada libraries use 5.0 as|[5 Regression] Ada
   |LIB_VERSION |libraries use 5.0 as
   ||LIB_VERSION

--- Comment #4 from Richard Biener rguenth at gcc dot gnu.org ---
Marking as P1 regression so we don't forget to resolve this bug before the
release.


[Bug sanitizer/63948] Sanitizer testsuite full of failures on darwin

2014-11-19 Thread dominiq at lps dot ens.fr
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63948

Dominique d'Humieres dominiq at lps dot ens.fr changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution|--- |DUPLICATE

--- Comment #1 from Dominique d'Humieres dominiq at lps dot ens.fr ---
Duplicate of pr63939 where a patch is proposed.

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


[Bug testsuite/63939] [5 Regression] Massive asan failures (356) on x86_64-apple-darwin14

2014-11-19 Thread dominiq at lps dot ens.fr
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63939

Dominique d'Humieres dominiq at lps dot ens.fr changed:

   What|Removed |Added

 CC||fxcoudert at gcc dot gnu.org

--- Comment #3 from Dominique d'Humieres dominiq at lps dot ens.fr ---
*** Bug 63948 has been marked as a duplicate of this bug. ***


[Bug sanitizer/63958] New: [5 Regression] bootstrap failure in the sanitizer libs on sparc-linux-gnu

2014-11-19 Thread doko at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63958

Bug ID: 63958
   Summary: [5 Regression] bootstrap failure in the sanitizer libs
on sparc-linux-gnu
   Product: gcc
   Version: unknown
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: sanitizer
  Assignee: unassigned at gcc dot gnu.org
  Reporter: doko at gcc dot gnu.org
CC: dodji at gcc dot gnu.org, dvyukov at gcc dot gnu.org,
jakub at gcc dot gnu.org, kcc at gcc dot gnu.org

seen with r217751 on the trunk

libtool: compile:  /«PKGBUILDDIR»/build/./gcc/xgcc
-B/«PKGBUILDDIR»/build/./gcc/ -B/usr/lib/gcc-snapshot/sparc-linux-gnu/bin/
-B/usr/lib/gcc-snapshot/sparc-linux-gnu/lib/ -isystem
/usr/lib/gcc-snapshot/sparc-linux-gnu/include -isystem
/usr/lib/gcc-snapshot/sparc-linux-gnu/sys-include -DHAVE_CONFIG_H
-I../../../../src/libatomic/config/posix -I../../../../src/libatomic -I. -Wall
-Werror -pthread -g -O2 -m64 -MT init.lo -MD -MP -MF .deps/init.Tpo -c
../../../../src/libatomic/init.c -o init.o /dev/null 21
/«PKGBUILDDIR»/build/./gcc/xgcc -B/«PKGBUILDDIR»/build/./gcc/
-B/usr/lib/gcc-snapshot/sparc-linux-gnu/bin/
-B/usr/lib/gcc-snapshot/sparc-linux-gnu/lib/ -isystem
/usr/lib/gcc-snapshot/sparc-linux-gnu/include -isystem
/usr/lib/gcc-snapshot/sparc-linux-gnu/sys-include-c -g -O2  -fPIC  -W -Wall
-gnatpg -nostdinc   a-wwboio.adb -o a-wwboio.o
In file included from
../../../../src/libsanitizer/sanitizer_common/sanitizer_platform_limits_linux.cc:40:0:
/usr/include/sparc-linux-gnu/asm/stat.h:60:2: error: 'time_t' does not name a
type
  time_t  st_atime;
  ^
/usr/include/sparc-linux-gnu/asm/stat.h:62:2: error: 'time_t' does not name a
type
  time_t  st_mtime;
  ^
/usr/include/sparc-linux-gnu/asm/stat.h:64:2: error: 'time_t' does not name a
type
  time_t  st_ctime;
  ^
yes
In file included from
../../../../src/libsanitizer/sanitizer_common/sanitizer_platform_limits_linux.cc:20:0:
../../../../src/libsanitizer/sanitizer_common/sanitizer_platform_limits_linux.cc:64:78:
error: invalid application of 'sizeof' to incomplete type '__old_kernel_stat'
 COMPILER_CHECK(struct___old_kernel_stat_sz == sizeof(struct
__old_kernel_stat));
  ^
../../../../src/libsanitizer/sanitizer_common/sanitizer_internal_defs.h:272:65:
note: in definition of macro 'IMPL_COMPILER_ASSERT'
 typedef char IMPL_PASTE(assertion_failed_##_, line)[2*(int)(pred)-1]
 ^
../../../../src/libsanitizer/sanitizer_common/sanitizer_platform_limits_linux.cc:64:1:
note: in expansion of macro 'COMPILER_CHECK'
 COMPILER_CHECK(struct___old_kernel_stat_sz == sizeof(struct
__old_kernel_stat));
 ^
../../../../src/libsanitizer/sanitizer_common/sanitizer_platform_limits_linux.cc:67:16:
error: 'struct_kernel_stat_sz' was not declared in this scope
 COMPILER_CHECK(struct_kernel_stat_sz == sizeof(struct stat));
^
../../../../src/libsanitizer/sanitizer_common/sanitizer_internal_defs.h:272:65:
note: in definition of macro 'IMPL_COMPILER_ASSERT'
 typedef char IMPL_PASTE(assertion_failed_##_, line)[2*(int)(pred)-1]
 ^
../../../../src/libsanitizer/sanitizer_common/sanitizer_platform_limits_linux.cc:67:1:
note: in expansion of macro 'COMPILER_CHECK'
 COMPILER_CHECK(struct_kernel_stat_sz == sizeof(struct stat));
 ^
checking for getrlimit... Makefile:447: recipe for target
'sanitizer_platform_limits_linux.lo' failed
make[6]: *** [sanitizer_platform_limits_linux.lo] Error 1
make[6]: *** Waiting for unfinished jobs

[Bug libstdc++/63959] New: G++ misreports volatile int as trivially copyable

2014-11-19 Thread lh_mouse at 126 dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63959

Bug ID: 63959
   Summary: G++ misreports volatile int as trivially copyable
   Product: gcc
   Version: 5.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: libstdc++
  Assignee: unassigned at gcc dot gnu.org
  Reporter: lh_mouse at 126 dot com

The type trait std::is_trivially_copyablevolatile int::value yields true on
g++ (GCC) 5.0.0 20141119 (experimental).

ISO C++ states that volatile types are NOT trivially copyable:

N3936 3.9 Types [basic.types]
9 Arithmetic types (3.9.1), ... Cv-unqualified scalar types, trivially copyable
class types (Clause 9), arrays of such types,
** and nonvolatile const-qualified versions of these types (3.9.3) **
are collectively called trivially copyable types. ...

So this is a bug. Please fix.


[Bug middle-end/63879] [5 Regression] ICE compiling Linux Kernel fs/ext3/namei.c with -fsanitize=undefined

2014-11-19 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63879

--- Comment #9 from Marek Polacek mpolacek at gcc dot gnu.org ---
Author: mpolacek
Date: Wed Nov 19 12:03:04 2014
New Revision: 217766

URL: https://gcc.gnu.org/viewcvs?rev=217766root=gccview=rev
Log:
PR sanitizer/63879
* fold-const.c (negate_expr_p) case NEGATE_EXPR: Return
!TYPE_OVERFLOW_SANITIZED.
(fold_negate_expr) case INTEGER_CST: Fold when overflow
does not trap and when overflow wraps, or when SANITIZE_SI_OVERFLOW
is 0.

* c-c++-common/ubsan/pr63879-1.c: New test.
* c-c++-common/ubsan/pr63879-2.c: New test.

Added:
trunk/gcc/testsuite/c-c++-common/ubsan/pr63879-1.c
trunk/gcc/testsuite/c-c++-common/ubsan/pr63879-2.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/fold-const.c
trunk/gcc/testsuite/ChangeLog


[Bug middle-end/63879] [5 Regression] ICE compiling Linux Kernel fs/ext3/namei.c with -fsanitize=undefined

2014-11-19 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63879

Marek Polacek mpolacek at gcc dot gnu.org changed:

   What|Removed |Added

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

--- Comment #10 from Marek Polacek mpolacek at gcc dot gnu.org ---
Hopefully fixed...


[Bug target/63949] Aarch64 instruction combiner does not optimize subsi_sxth function as expected

2014-11-19 Thread ktkachov at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63949

ktkachov at gcc dot gnu.org changed:

   What|Removed |Added

   Keywords||missed-optimization
 Target||aarch64*
 Status|UNCONFIRMED |NEW
   Last reconfirmed||2014-11-19
 CC||ktkachov at gcc dot gnu.org
 Ever confirmed|0   |1
  Known to fail||4.8.4, 4.9.2, 5.0

--- Comment #1 from ktkachov at gcc dot gnu.org ---
Confirmed. Also, I see it failing on 4.9.2 and 4.8.4 as well. Has this ever
worked?


[Bug sanitizer/63520] ICE: in get_biv_step, at loop-iv.c:824 with -fsanitize=undefined on ppc64

2014-11-19 Thread trippels at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63520

Markus Trippelsdorf trippels at gcc dot gnu.org changed:

   What|Removed |Added

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

--- Comment #13 from Markus Trippelsdorf trippels at gcc dot gnu.org ---
Fixed. Thanks.


[Bug tree-optimization/63960] New: [meta-bug] Port tail-merge fixes to 4.8

2014-11-19 Thread vries at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63960

Bug ID: 63960
   Summary: [meta-bug] Port tail-merge fixes to 4.8
   Product: gcc
   Version: 4.8.4
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: tree-optimization
  Assignee: unassigned at gcc dot gnu.org
  Reporter: vries at gcc dot gnu.org

Candidates:
- Fix PR63380
  https://gcc.gnu.org/ml/gcc-patches/2014-10/msg00752.html
- Fix bug in tree-ssa-tail-merge.c
  https://gcc.gnu.org/ml/gcc-patches/2014-06/msg00668.html


[Bug sanitizer/63956] [5 Regression][UBSAN] ICE segfault in cxx_eval_call_expression ../../gcc/cp/constexpr.c

2014-11-19 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63956

Jakub Jelinek jakub at gcc dot gnu.org changed:

   What|Removed |Added

 CC||jason at gcc dot gnu.org

--- Comment #3 from Jakub Jelinek jakub at gcc dot gnu.org ---
Supposedly with the C++14 constexpr changes we need to be prepared to handle
all the ubsan builtins and internal calls we create during genericization.
Already in the still pending -fsanitize=vptr patch I had to deal with handling
the ubsan vptr type cache miss builtin even before the C++14 constexpr changes,
because that is created during static_cast handling, but if we now look at
DECL_SAVED_TREE, it can see all the builtins / internal calls in there.
I hope most of the ubsan stuff can be ignored for constexpr purposes.


[Bug other/63426] [meta-bug] Issues found with -fsanitize=undefined

2014-11-19 Thread trippels at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63426

--- Comment #2 from Markus Trippelsdorf trippels at gcc dot gnu.org ---
A few new ones:

config/rs6000/constraints.md:143:33: runtime error: signed integer overflow:
9223372036854775807 + 32768 cannot be represented in type 'long int'
config/rs6000/predicates.md:396:22: runtime error: signed integer overflow:
9223372036854775807 + 2147516416 cannot be represented in type 'long int'
config/rs6000/predicates.md:856:11: runtime error: negation of
-9223372036854775808 cannot be represented in type 'long int'; cast to an
unsigned type to negate this value to itself
config/rs6000/predicates.md:862:12: runtime error: negation of
-9223372036854775808 cannot be represented in type 'long int'; cast to an
unsigned type to negate this value to itself
config/rs6000/predicates.md:865:11: runtime error: negation of
-9223372036854775808 cannot be represented in type 'long int'; cast to an
unsigned type to negate this value to itself
config/rs6000/predicates.md:868:12: runtime error: negation of
-9223372036854775808 cannot be represented in type 'long int'; cast to an
unsigned type to negate this value to itself
config/rs6000/predicates.md:914:11: runtime error: negation of
-9223372036854775808 cannot be represented in type 'long int'; cast to an
unsigned type to negate this value to itself
config/rs6000/predicates.md:917:12: runtime error: negation of
-9223372036854775808 cannot be represented in type 'long int'; cast to an
unsigned type to negate this value to itself
config/rs6000/predicates.md:940:11: runtime error: negation of
-9223372036854775808 cannot be represented in type 'long int'; cast to an
unsigned type to negate this value to itself
config/rs6000/predicates.md:946:12: runtime error: negation of
-9223372036854775808 cannot be represented in type 'long int'; cast to an
unsigned type to negate this value to itself
config/rs6000/predicates.md:949:11: runtime error: negation of
-9223372036854775808 cannot be represented in type 'long int'; cast to an
unsigned type to negate this value to itself
config/rs6000/predicates.md:955:12: runtime error: negation of
-9223372036854775808 cannot be represented in type 'long int'; cast to an
unsigned type to negate this value to itself
gcc.c:1687:29: runtime error: load of misaligned address 0x101e55f9 for
type 'const char *', which requires 8 byte alignment
gcc.c:1690:25: runtime error: store to misaligned address 0x101e55f9 for
type 'const char *', which requires 8 byte alignment
gcc.c:5596:29: runtime error: load of misaligned address 0x101e55d9 for
type 'const char *', which requires 8 byte alignment
gcc.c:7251:15: runtime error: load of misaligned address 0x101e55c9 for
type 'const char *', which requires 8 byte alignment
gcc.c:8003:33: runtime error: load of misaligned address 0x101e55f9 for
type 'const char *', which requires 8 byte alignment
loop-iv.c:2314:24: runtime error: signed integer overflow: 9223372036854775807
- -9223372036854775808 cannot be represented in type 'long int'
loop-iv.c:2652:14: runtime error: signed integer overflow: 9223372036854775806
- -9223372036854775808 cannot be represented in type 'long int'
varasm.c:7191:16: runtime error: shift exponent 63 is too large for 32-bit type
'int'


[Bug sanitizer/63939] [5 Regression] Massive asan failures (356) on darwin

2014-11-19 Thread fxcoudert at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63939

Francois-Xavier Coudert fxcoudert at gcc dot gnu.org changed:

   What|Removed |Added

 CC||dodji at gcc dot gnu.org,
   ||dvyukov at gcc dot gnu.org,
   ||jakub at gcc dot gnu.org
  Component|testsuite   |sanitizer
Summary|[5 Regression] Massive asan |[5 Regression] Massive asan
   |failures (356) on   |failures (356) on darwin
   |x86_64-apple-darwin14   |

--- Comment #4 from Francois-Xavier Coudert fxcoudert at gcc dot gnu.org ---
The difference is that darwin doesn't give symbols associated with the
backtrace (the in main part). This should be ultimately fixed in libbacktrace
(see for example: https://gcc.gnu.org/ml/gcc/2012-10/msg00053.html), because as
I understand it it is libbacktrace that provides symbolization for
libsanitizer.

In the meantime, the testsuite requirements should be relaxed. The question for
the sanitizer maintainers is: is Dominique's patch acceptable to achieve this?


[Bug sanitizer/63958] [5 Regression] bootstrap failure in the sanitizer libs on sparc-linux-gnu

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63958

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

Version|unknown |5.0
   Target Milestone|--- |5.0


[Bug sanitizer/63939] [5 Regression] Massive asan failures (356) on darwin

2014-11-19 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63939

--- Comment #5 from Jakub Jelinek jakub at gcc dot gnu.org ---
I'd strongly prefer somebody interested in darwin to just add the libbacktrace
support.  And instead of obfuscating the testcase, either see why it is not
symbolized by testsuite/lib/asan-dg.exp (asan_symbolize) either and fix that,
or just disable asan.exp testing for darwin temporarily.


[Bug sanitizer/63939] [5 Regression] Massive asan failures (356) on darwin

2014-11-19 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63939

Jakub Jelinek jakub at gcc dot gnu.org changed:

   What|Removed |Added

 CC|davem at gcc dot gnu.org   |

--- Comment #6 from Jakub Jelinek jakub at gcc dot gnu.org ---
Oops, sorry, meant to add you to CC on a different PR.


[Bug sanitizer/63939] [5 Regression] Massive asan failures (356) on darwin

2014-11-19 Thread fxcoudert at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63939

--- Comment #7 from Francois-Xavier Coudert fxcoudert at gcc dot gnu.org ---
It's not only a darwin issue: as libbacktrace's README says, libbacktrace only
supports ELF executables with DWARF debugging information, so obviously there
are other object formats, Mach-O and PE-COFF at least, possibly some other
exotic object formats(?).

So a generic solution still needs to be found. Disabling testing entirely,
while a large part of the functionality is present, seems like a bad idea.


[Bug middle-end/61558] [5 Regression] ICE: Segmentation fault

2014-11-19 Thread dcb314 at hotmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61558

--- Comment #14 from David Binderman dcb314 at hotmail dot com ---

Still broken some five months after reporting it. ;-|


[Bug c++/63961] New: Use-after-free in constexpr.c

2014-11-19 Thread y.gribov at samsung dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63961

Bug ID: 63961
   Summary: Use-after-free in constexpr.c
   Product: gcc
   Version: 5.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c++
  Assignee: unassigned at gcc dot gnu.org
  Reporter: y.gribov at samsung dot com
CC: jason at redhat dot com
  Host: x86_64-unknown-linux-gnu

/home/ygribov/build/gcc-master/./gcc/xgcc -shared-libgcc
-B/home/ygribov/build/gcc-master/./gcc -nostdinc++
-L/home/ygribov/build/gcc-master/x86_64-unknown-linux-gnu/libstdc++-v3/src
-L/home/ygribov/build/gcc-master/x86_64-unknown-linux-gnu/libstdc++-v3/src/.libs
-L/home/ygribov/build/gcc-master/x86_64-unknown-linux-gnu/libstdc++-v3/libsupc++/.libs
-B/home/ygribov/install/gcc-master/x86_64-unknown-linux-gnu/bin/
-B/home/ygribov/install/gcc-master/x86_64-unknown-linux-gnu/lib/ -isystem
/home/ygribov/install/gcc-master/x86_64-unknown-linux-gnu/include -isystem
/home/ygribov/install/gcc-master/x86_64-unknown-linux-gnu/sys-include-x
c++-header -nostdinc++ -g -O2 -D_GNU_SOURCE 
-I/home/ygribov/build/gcc-master/x86_64-unknown-linux-gnu/libstdc++-v3/include/x86_64-unknown-linux-gnu
-I/home/ygribov/build/gcc-master/x86_64-unknown-linux-gnu/libstdc++-v3/include
-I/home/ygribov/src/gcc-master/libstdc++-v3/libsupc++ -O2 -g -std=gnu++0x
/home/ygribov/src/gcc-master/libstdc++-v3/include/precompiled/stdc++.h \
-o x86_64-unknown-linux-gnu/bits/stdc++.h.gch/O2ggnu++0x.gch
=
==26744==ERROR: AddressSanitizer: heap-use-after-free on address 0x611000d21788
at pc 0x00cde441 bp 0x7fffc3426c90 sp 0x7fffc3426c88
READ of size 8 at 0x611000d21788 thread T0
#0 0xcde440 in cxx_eval_store_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:2552
#1 0xcd6bcf in cxx_eval_constant_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:2942
#2 0xcd6749 in cxx_eval_constant_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:2953
#3 0xcd46ce in cxx_eval_call_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:1328
#4 0xcd6d9a in cxx_eval_constant_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:2864
#5 0xcd962a in cxx_eval_constant_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:2922
#6 0xcd6988 in cxx_eval_constant_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:2985
#7 0xcd7d9f in cxx_eval_constant_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:3173
#8 0xcd2b6b in cxx_bind_parameters_in_call
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:1071
#9 0xcd2b6b in cxx_eval_call_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:1234
#10 0xcd6d9a in cxx_eval_constant_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:2864
#11 0xcd962a in cxx_eval_constant_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:2922
#12 0xcd95e8 in cxx_eval_constant_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:3035
#13 0xcde225 in cxx_eval_store_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:2538
#14 0xcd6bcf in cxx_eval_constant_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:2942
#15 0xcd6749 in cxx_eval_constant_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:2953
#16 0xcd665d in cxx_eval_constant_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:2966
#17 0xcd46ce in cxx_eval_call_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:1328
#18 0xcd6d9a in cxx_eval_constant_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:2864
#19 0xcd962a in cxx_eval_constant_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:2922
#20 0xcd6988 in cxx_eval_constant_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:2985
#21 0xcd7d9f in cxx_eval_constant_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:3173
#22 0xcd7d9f in cxx_eval_constant_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:3173
#23 0xcd2b6b in cxx_bind_parameters_in_call
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:1071
#24 0xcd2b6b in cxx_eval_call_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:1234
#25 0xcd6d9a in cxx_eval_constant_expression
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:2864
#26 0xce5189 in cxx_eval_outermost_constant_expr
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:3340
#27 0xcec547 in maybe_constant_value(tree_node*, tree_node*)
/home/ygribov/src/gcc-master/gcc/cp/constexpr.c:3453
#28 0xb93653 in finish_static_assert(tree_node*, tree_node*, unsigned int,
bool) /home/ygribov/src/gcc-master/gcc/cp/semantics.c:7046
#29 0xa477fb in cp_parser_static_assert
/home/ygribov/src/gcc-master/gcc/cp/parser.c:12139
#30 0xa7f2ec in cp_parser_member_declaration
/home/ygribov/src/gcc-master/gcc/cp/parser.c:20673
#31 0xa1ad11 in 

[Bug tree-optimization/62053] [5 Regression] ICE: in remap_type_1, at tree-inline.c:540

2014-11-19 Thread dcb314 at hotmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62053

--- Comment #8 from David Binderman dcb314 at hotmail dot com ---
(In reply to Alexander Ivchenko from comment #7)
 The patch fixed the issue for me, thanks!

This bug has been unresolved for over three months now.

Time for some more testing of the patch ?


[Bug sanitizer/63939] [5 Regression] Massive asan failures (356) on darwin

2014-11-19 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63939

--- Comment #8 from Jakub Jelinek jakub at gcc dot gnu.org ---
(In reply to Francois-Xavier Coudert from comment #7)
 It's not only a darwin issue: as libbacktrace's README says, libbacktrace
 only supports ELF executables with DWARF debugging information, so
 obviously there are other object formats, Mach-O and PE-COFF at least,
 possibly some other exotic object formats(?).
 
 So a generic solution still needs to be found. Disabling testing entirely,
 while a large part of the functionality is present, seems like a bad idea.

No.  libsanitizer is only supported on selected *-*-linux* targets, and
(apparently prematurely so) on x86_64-*-darwin* and i?86-*-darwin*.
So no generic solution is needed, when somebody ports libsanitizer to some
other target, he should make sure symbolization also works there.


[Bug tree-optimization/63962] New: [5 Regression][x86] Code pessimization after r217213

2014-11-19 Thread izamyatin at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63962

Bug ID: 63962
   Summary: [5 Regression][x86] Code pessimization after r217213
   Product: gcc
   Version: 5.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: tree-optimization
  Assignee: unassigned at gcc dot gnu.org
  Reporter: izamyatin at gmail dot com
Target: x86

While investigating some performance regressions on 32 bits on trunk (just -O2
-m32) I noticed that after r217213 forward propagation makes code worse for
following testcase

struct TT
{
 int * c;
 int s;
} FF;

long
foo (int t1, int t2)
{
  unsigned int i, i1;
  static int *c, s;

  for (i = 0; i  t1; i++)
{
  c = FF.c + FF.s - 1;
  s = (int)(*c--);

  for (i1 = 2; i1  t2; i1++)
s += (int)(*c--);
}

  return s;
}

For r217212 I see in 068t.forwprop2

-
bb 3:
  _8 = FF.c;
  _9 = FF.s;
  _10 = (sizetype) _9;
  _11 = _10 + 1073741823;
  _12 = _11 * 4;
  c.0_13 = _8 + _12;
  c = c.0_13;
  c.3_15 = c.0_13 + 4294967292;
  c = c.3_15;
  s.4_17 = *c.0_13;
  s = s.4_17;
  # DEBUG i1 = 2
  goto bb 5;
-

while for r217213 code contains one more addition

-   |
 bb 3:|
  _8 = FF.c;|
  _9 = FF.s;|
  _10 = (sizetype) _9;  |
  _11 = _10 + 1073741823;   |
  _12 = _11 * 4;|
  c.0_13 = _8 + _12;|
  c = c.0_13;   |
  _31 = _12 + 4294967292;---
  c.3_15 = _8 + _31;
  c = c.3_15;
  s.4_17 = *c.0_13;
  s = s.4_17;
  # DEBUG i1 = 2
  goto bb 5;

-


Can try to cook runtime test if it is necessary.


[Bug tree-optimization/63955] Remove pr51879-12.c xfail

2014-11-19 Thread vries at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63955

--- Comment #2 from vries at gcc dot gnu.org ---
Created attachment 34036
  -- https://gcc.gnu.org/bugzilla/attachment.cgi?id=34036action=edit
Tentative patch


[Bug c++/63928] [5 Regression] use after free in cp/constexpr.c

2014-11-19 Thread trippels at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63928

Markus Trippelsdorf trippels at gcc dot gnu.org changed:

   What|Removed |Added

 CC||y.gribov at samsung dot com

--- Comment #2 from Markus Trippelsdorf trippels at gcc dot gnu.org ---
*** Bug 63961 has been marked as a duplicate of this bug. ***


[Bug c++/63961] Use-after-free in constexpr.c

2014-11-19 Thread trippels at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63961

Markus Trippelsdorf trippels at gcc dot gnu.org changed:

   What|Removed |Added

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

--- Comment #1 from Markus Trippelsdorf trippels at gcc dot gnu.org ---
dup.

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


[Bug target/63951] [5 Regression] bootstrap failure (ICE in adjust_temp_type) on arm-linux-gnueabi{,hf} building the libstdc++ pch file

2014-11-19 Thread hjl.tools at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63951

--- Comment #2 from H.J. Lu hjl.tools at gmail dot com ---
Dup of PR 63928?


[Bug libstdc++/60936] [4.9 Regression] Binary code bloat with std::string

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60936

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|--- |4.9.3


[Bug fortran/61831] [4.9/ 5 Regression] runtime error: pointer being freed was not allocated

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61831

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|--- |4.9.3


[Bug c++/62051] [4.9/4.10] Undefined reference to vtable with -O2 and -fdevirtualize-speculatively

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62051

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|--- |4.9.3


[Bug ada/62117] [4.9 regression] wrong code for passing small array argument'Address, in generic

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62117

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|--- |4.9.3


[Bug c++/63849] [4.9/5.0 Regression][c++11] ICE on variadic alias template with wrappers

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63849

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|--- |4.9.3


[Bug fortran/61765] [4.9/5 Regression] Rejects valid BIND(C) ENTRY

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61765

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|--- |4.9.3


[Bug target/63783] [4.9/5 Regression] [SH] Miscompilation of boolean negation on SH4 using -O2

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63783

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|--- |4.9.3


[Bug target/61622] [4.8 regression] internal compiler error: in simplify_const_unary_operation, at simplify-rtx.c:1508

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61622

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|--- |4.8.4


[Bug fortran/63733] [4.8/4.9/5 Regression] [OOP] wrong resolution for OPERATOR generics

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63733

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|--- |4.8.4


[Bug fortran/62044] [4.8/4.9/5 Regression] ICE in USE statement with RENAME for extended derived type

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62044

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|--- |4.8.4


[Bug target/63408] [4.8 regression] GCC emits incorrect fixed-fp conversion instruction on Cortex-M4 target

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63408

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|--- |4.8.4


[Bug other/62284] [4.8 Regression] AVR unable to find register to spill in the class POINTER_REGS

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62284

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|--- |4.8.4


[Bug debug/61033] [4.8/4.9 Regression] Infinite loop in variable tracking

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61033

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|--- |4.8.4


[Bug fortran/63744] [4.8/4.9/5 Regression] Duplicate use-statement causes error

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63744

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|--- |4.8.4


[Bug target/62642] [4.8/4.9 Regression] x86 rdtsc is moved through barrier

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62642

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|--- |4.8.4


[Bug fortran/60898] [4.8/4.9/5 Regression] model compile error with gfortran 4.7 and gcc 4.9

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60898

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|--- |4.8.4


[Bug other/63505] [4.8/4.9 Regression] ICE with -fdebug-types-section in should_move_die_to_comdat, at dwarf2out.c:6702

2014-11-19 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63505

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|--- |4.8.4


  1   2   3   4   >