[PATCH] Fix PR rtl-optimization/pr60663

2014-03-25 Thread Zhenqiang Chen
Hi, The patch checks the number of the expected operands in ASM_OPERANDS_TEMPLATE with the same logic as it in output_asm_insn to make sure the ASM_OPERANDS are legal. Bootstrap and no make check regression on X86-64 and ARM chromebook. OK for trunk? Thanks! -Zhenqiang ChangeLog: 2014-03-26 Z

Re: [4.8, PATCH 0/26] Backport Power8 and LE support

2014-03-25 Thread Chris Johns
On 21/03/2014 1:05 pm, Bill Schmidt wrote: For convenience of those who have kindly agreed to test the patch series, here is the entire series as a single compressed patch. Note that this does not include patch 15/26, which we've agreed to submit separately. I have tested the patch with RTEMS

Re: [PATCH, doc] Mention nds32*-*-elf in the target specific installation notes.

2014-03-25 Thread Chung-Ju Wu
2014-03-24 23:47 GMT+08:00 Gerald Pfeifer : > On Mon, 24 Mar 2014, Chung-Ju Wu wrote: >> +2014-03-24 Chung-Ju Wu >> + >> + * doc/install.texi: Document nds32le-*-elf and nds32be-*-elf. > > Looks good to me. (The new patch avoids "elf" which I believe should > have been "ELF", by the way.)

Re: [PATCH, doc] Add myself as NDS32 port contributor in the documentation.

2014-03-25 Thread Chung-Ju Wu
2014-03-24 20:07 GMT+08:00 Gerald Pfeifer : > On Mon, 24 Mar 2014, Chung-Ju Wu wrote: >> I would like to add an item to describe myself as nds32 port contributor. >> The plaintext ChangeLog and patch are as below. >> Bootstrapped and the webpage can be successfully built via 'make html'. >> >> Is i

Fix PR ipa/60315 (inliner explosion)

2014-03-25 Thread Jan Hubicka
Hi, this patch fixes compile time issue in the testcase that is caused by fact that the inliner is repeatedly inlining into an call it earlier proved to be unreachable. The analysis part knows that such calls are not accounted into overall function summaries, but the transform part sees them me

Re: [PATCH] Update the overall summary after edge_summary is updated

2014-03-25 Thread Jan Hubicka
> On Sat, Mar 22, 2014 at 6:32 PM, Jan Hubicka wrote: > >> Hi, > >> > >> This patch updates node's inline summary after edge_summary is > >> updated. Otherwise it could lead to incorrect inline summary. > >> > >> Bootstrapped and gcc regression test on-going. > >> > >> OK for trunk? > >> > >> Than

Re: [PATCH] Fix --with-build-config=bootstrap-ubsan bootstrap of lto-plugin (PR sanitizer/56781)

2014-03-25 Thread H.J. Lu
On Tue, Mar 25, 2014 at 3:11 PM, Jakub Jelinek wrote: > On Tue, Mar 25, 2014 at 03:01:26PM -0700, H.J. Lu wrote: >> I got >> >> /export/gnu/import/git/gcc/libiberty/configure: line 4977: syntax >> error near unexpected token `-fsanitize=address' >> /export/gnu/import/git/gcc/libiberty/configure: l

Re: [PATCH] Update the overall summary after edge_summary is updated

2014-03-25 Thread Dehao Chen
On Sat, Mar 22, 2014 at 6:32 PM, Jan Hubicka wrote: >> Hi, >> >> This patch updates node's inline summary after edge_summary is >> updated. Otherwise it could lead to incorrect inline summary. >> >> Bootstrapped and gcc regression test on-going. >> >> OK for trunk? >> >> Thanks, >> Dehao >> >> gcc

Re: [Build, Driver] Add -lcilkrts for -fcilkplus

2014-03-25 Thread Tobias Burnus
Paolo Bonzini wrote: Il 11/03/2014 07:42, Tobias Burnus ha scritto: +XPCFLAGS="" +CFLAGS="$CFLAGS -pthread" +AC_LINK_IFELSE( ... + [XPCFLAGS=" -Wc,-pthread"], XPCFLAGS is dead, I think? Yes - contrary to libgomp, from which I have taken that code block. I have now removed it. Also, should

Re: Please revert the patches in bug #54040 and #59346 and special case x32

2014-03-25 Thread Eric Botcazou
> Should I file a bug to get feedback on this issue? I know Ada is not the > most prioritized language for gcc, but anyway. The current > implementation is not POSIX-compliant. Can you post a complete patch doing the reversion? Breaking POSIX and every Unix for the sake of x32 is definitely too

Re: [Fortran][PATCH][gomp4]: Transform OpenACC loop directive

2014-03-25 Thread Tobias Burnus
Hi Ilmir, Ilmir Usmanov wrote: For DO CONCURRENT, it is not. I always forget about this kind of loops. And I tend to forget about the issues with mask as I don't use do concurrent with mask. * And do concurrent also supports masks: logical :: my_mask(3) integer :: i, b(3) b(i) = [5, 5, 2

Re: [GOOGLE] Refactor the LIPO fixup

2014-03-25 Thread Xinliang David Li
Add comment to the new function. init_node_map is better invoked after the link step to avoid creating entries with for dead nodes. Ok if large perf testing is fine. David On Tue, Mar 25, 2014 at 3:38 PM, Dehao Chen wrote: > This patch refactors LIPO fixup related code to move it into a > stand

Re: [PATCH] Fix undefined behavior in IRA

2014-03-25 Thread Vladimir Makarov
On 2014-03-25, 12:14 PM, Marek Polacek wrote: This is a temporary fix for UB in IRA, where ubsan complains because there's signed iteger overflow in the multiplication. To shut this error up, we can perform the multiplication in unsigned and only then cast the result of the multiplication to int

[GOOGLE] Refactor the LIPO fixup

2014-03-25 Thread Dehao Chen
This patch refactors LIPO fixup related code to move it into a standalone function. This makes sure that symtab_remove_unreachable_nodes is called right after the fixup so that there is not dangling cgraph nodes any time. Bootstrapped and regression test on-going. OK for google-4_8? Thanks, Deha

Re: [DOC PATCH] Amend designated inits doc (PR c/39525)

2014-03-25 Thread Joseph S. Myers
On Tue, 25 Mar 2014, Marek Polacek wrote: > Apparently some users would like to see what happens to omitted field > members when initializing a structure in GCC docs. > > Ok for trunk? > > 2014-03-25 Marek Polacek > > PR c/39525 > * doc/extend.texi (Designated Inits): Describe wh

Re: [DOC PATCH] Describe VLAs in struct/union (PR c/37428)

2014-03-25 Thread Joseph S. Myers
On Tue, 25 Mar 2014, Marek Polacek wrote: > We should mention this GNU C extension in the manual. > > Ok? > > 2014-03-25 Marek Polacek > > PR c/37428 > * doc/extend.texi (C Extensions): Mention variable-length arrays in > a structure/union. OK. -- Joseph S. Myers jos...@

Re: [PATCH] Fix --with-build-config=bootstrap-ubsan bootstrap of lto-plugin (PR sanitizer/56781)

2014-03-25 Thread H.J. Lu
On Tue, Mar 25, 2014 at 2:32 PM, Jakub Jelinek wrote: > On Tue, Mar 25, 2014 at 09:17:07PM +0100, Jakub Jelinek wrote: >> On Tue, Mar 25, 2014 at 08:57:21PM +0100, Jakub Jelinek wrote: >> > It works fine for ubsan, and your fix is not the right thing to do, >> > e.g. bootstrap-ubsan reveals some b

[DOC PATCH] Amend designated inits doc (PR c/39525)

2014-03-25 Thread Marek Polacek
Apparently some users would like to see what happens to omitted field members when initializing a structure in GCC docs. Ok for trunk? 2014-03-25 Marek Polacek PR c/39525 * doc/extend.texi (Designated Inits): Describe what happens to omitted field members. diff --git

Fix wrong code issue in ipa-pure-const

2014-03-25 Thread Jan Hubicka
Hi, this patch fixes issue I run into while working on other fix. ipa-pure-const is happy to make inline clone pure when it proves it is, but because decls are shared with master clone, it actually makes offline copy and the master clone pure, too. This may lead to wrong code issues if function c

[PATCH] Perform ubsan instrumentation for x >= 0 ? x : -x (take 2)

2014-03-25 Thread Jakub Jelinek
On Tue, Mar 25, 2014 at 10:43:02AM +0100, Richard Biener wrote: > Yes, all transforms in fold-const would be invalid if the result doesn't > behave in the same way wrt overflow. Thus you really should instrument > ABS_EXPR - you can treat it as A > 0 ? A : -A if that simplifies it. > > I don't li

[DOC PATCH] Fix up __builtin_ffs* args (PR c/50347)

2014-03-25 Thread Marek Polacek
ffs builtins had wrong type of parameters. 2014-03-25 Marek Polacek PR c/50347 * doc/extend.texi (ffs Builtins): Change unsigned types to signed types. diff --git gcc/doc/extend.texi gcc/doc/extend.texi index c0da713..cb28bc9 100644 --- gcc/doc/extend.texi +++ gcc/doc/

Re: [PATCH] Fix --with-build-config=bootstrap-ubsan bootstrap of lto-plugin (PR sanitizer/56781)

2014-03-25 Thread Jakub Jelinek
On Tue, Mar 25, 2014 at 08:57:21PM +0100, Jakub Jelinek wrote: > It works fine for ubsan, and your fix is not the right thing to do, > e.g. bootstrap-ubsan reveals some bugs in libiberty which would be otherwise > unnoticed if you always filter away the sanitizing options from libiberty. > > So, I

Re: [PATCH] Fix folding of UBSAN_CHECK_SUB (x, 0) etc.

2014-03-25 Thread Jakub Jelinek
On Tue, Mar 25, 2014 at 10:15:37AM +0100, Richard Biener wrote: > On Tue, 25 Mar 2014, Richard Biener wrote: > > > On Tue, 25 Mar 2014, Jakub Jelinek wrote: > > > > > Hi! > > > > > > While working on previous patch, I've noticed a severe omission in the > > > -fsanitize=signed-integer-overflow s

Re: [PATCH] Fix ubsan i?86 {add,sub,mul}v4 patterns

2014-03-25 Thread Uros Bizjak
On Tue, Mar 25, 2014 at 8:18 PM, Jakub Jelinek wrote: > On Tue, Mar 25, 2014 at 04:06:40PM +0100, Jakub Jelinek wrote: >> On Tue, Mar 25, 2014 at 12:39:18PM +0100, Uros Bizjak wrote: >> > The patch is OK in principle, but we could follow established practice >> > and use separate predicates - plea

Re: [PATCH] Fix --with-build-config=bootstrap-ubsan bootstrap of lto-plugin (PR sanitizer/56781)

2014-03-25 Thread Jakub Jelinek
On Tue, Mar 25, 2014 at 12:44:58PM -0700, H.J. Lu wrote: > On Tue, Mar 25, 2014 at 12:28 PM, Jakub Jelinek wrote: > > lto-plugin is another problematic directory in asan/ubsan bootstraps. > > > > Unlike fixincludes, it is bootstrapped, and like fixincludes it is also > > linked against host libibe

Re: [PATCH] Fix PR c++/60573

2014-03-25 Thread Adam Butcher
On 2014-03-25 15:48, Jason Merrill wrote: On 03/18/2014 10:46 PM, Adam Butcher wrote: + if (TYPE_BEING_DEFINED (scope->this_entity)) + if (scope->level_chain == 0 + || scope->this_entity != scope->level_chain->this_entity) + break; I

Re: [PATCH] Fix --with-build-config=bootstrap-ubsan bootstrap of lto-plugin (PR sanitizer/56781)

2014-03-25 Thread H.J. Lu
On Tue, Mar 25, 2014 at 12:28 PM, Jakub Jelinek wrote: > Hi! > > lto-plugin is another problematic directory in asan/ubsan bootstraps. > > Unlike fixincludes, it is bootstrapped, and like fixincludes it is also > linked against host libiberty. The problem for lto-plugin is that the > -static-libu

[patch] fix libstdc++/60658

2014-03-25 Thread Jonathan Wakely
This fixes a simple thinko in the atomic partial specialization that uses sizeof(T) instead of sizeof(T*). It's a regression since 4.6 so I'm committing it to trunk and the 4.7 and 4.8 branches. Tested x86_64-linux. commit cb68113312d9702bd17af760c775697d2d57f94a Author: Jonathan Wakely Date:

Re: [PATCH] Fix ubsan i?86 {add,sub,mul}v4 patterns

2014-03-25 Thread Jakub Jelinek
On Tue, Mar 25, 2014 at 12:39:18PM +0100, Uros Bizjak wrote: > The patch is OK in principle, but we could follow established practice > and use separate predicates - please see general_szext_operand mode > attribute definition. So like this? I've tried to use non-VOIDmode of the predicates that w

[PATCH] Fix --with-build-config=bootstrap-ubsan bootstrap of lto-plugin (PR sanitizer/56781)

2014-03-25 Thread Jakub Jelinek
Hi! lto-plugin is another problematic directory in asan/ubsan bootstraps. Unlike fixincludes, it is bootstrapped, and like fixincludes it is also linked against host libiberty. The problem for lto-plugin is that the -static-libubsan -fsanitize=undefined -B/some/path/to/libsanitizer/ -B/some/pat

Re: [PATCH] x86: _mm512_set1_p[sd]

2014-03-25 Thread Ulrich Drepper
On Mon, Mar 24, 2014 at 9:09 AM, Jakub Jelinek wrote: > The following is recognized well: > > typedef char v32qi __attribute__((vector_size (32))); > v32qi foo (char a) > { > return (v32qi) { a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, > a, a, a, a, a, a, a, a, a, a, a, a, a }; > }

[PATCH] Fix --with-build-config=bootstrap-ubsan bootstrap of fixincludes (PR sanitizer/56781)

2014-03-25 Thread Jakub Jelinek
Hi! This patch fixes a problem where build of host fixincludes fails with --with-build-config=bootstrap-ubsan (and bootstrap-asan). The problem is that fixincludes is linked against host libiberty that is bootstrapped, but fixincludes is not bootstrapped. Thus, libiberty uses post stage1 cflags/ld

Re: [PATCH] Fix ubsan i?86 {add,sub,mul}v4 patterns

2014-03-25 Thread Jakub Jelinek
On Tue, Mar 25, 2014 at 04:06:40PM +0100, Jakub Jelinek wrote: > On Tue, Mar 25, 2014 at 12:39:18PM +0100, Uros Bizjak wrote: > > The patch is OK in principle, but we could follow established practice > > and use separate predicates - please see general_szext_operand mode > > attribute definition.

Re: [PATCH] Don't bootstrap libsanitizer or libvtv unless needed

2014-03-25 Thread Jakub Jelinek
On Tue, Mar 25, 2014 at 05:36:54PM +0100, Paolo Bonzini wrote: > Il 20/03/2014 13:24, Jakub Jelinek ha scritto: > >We currently bootstrap both libsanitizer and libvtv, the former > >just in case somebody decides to --with-build-config=bootstrap-asan > >(or --with-build-config=bootstrap-ubsan), the

Re: [PATCH] Fix PR59626, _FORTIFY_SOURCE wrappers and LTO

2014-03-25 Thread Jan Hubicka
> > > PR lto/59626 > > > * passes.c (ipa_write_summaries): Drop function bodies of > > > extern always-inline functions. > > > > > > * gcc.dg/lto/pr59626_0.c: New testcase. > > > * gcc.dg/lto/pr59626_1.c: Likewise. > > > > > Hi, > > do you see some problem with this approach? Unlike in

[committed][DOC PATCH] Fix typo in example (PR c/35449)

2014-03-25 Thread Marek Polacek
I'm applying this as obvious. 2014-03-25 Marek Polacek PR c/35449 * doc/extend.texi (Example of asm with clobbered asm reg): Fix typo. diff --git gcc/doc/extend.texi gcc/doc/extend.texi index 986cc94..c0da713 100644 --- gcc/doc/extend.texi +++ gcc/doc/extend.texi @@ -6343,7 +6

[PATCH, PR 60600] Handle inconsistent devirtualizations gracefully

2014-03-25 Thread Martin Jambor
Hi, the following patch converting an assert to a test fixes PR 60600. If we determine that a devirtualization cannot happen, we can now convert the call to builtin_unreachable. Bootstrapped and tested on x86_64-linux. I have also sucessfully LTO built Firefox with the change. Pre-approved by

C++ PATCH for c++/60375 (unevaluated lambda)

2014-03-25 Thread Jason Merrill
The parser was getting confused by trying to process the body of the lambda in an unevaluated context, so let's just skip the body. The second patch avoids repeated errors about the issue, but isn't necessary to fix the ICE, so I'm saving it for after 4.9. Tested x86_64-pc-linux-gnu, applying

C++ PATCH for c++/60628 (auto array)

2014-03-25 Thread Jason Merrill
We got confused tsubsting the VLA type because tsubst doesn't expect to see a SAVE_EXPR. Simple to fix by enforcing the rule against auto arrays. Tested x86_64-pc-linux-gnu, applying to trunk. commit f2fbd4a8a0152e2d9d6c0b9d6ccfb1639183ed0c Author: Jason Merrill Date: Mon Mar 24 14:58:58 201

Re: std::rethrow_exception is broken

2014-03-25 Thread Jonathan Wakely
On 24/03/14 19:19 +, Jonathan Wakely wrote: There is a lot of code in libsupc++/eh_* that relies on __cxa_exception and __cxa_dependent_exception having similar layouts, so tricks like this work: static inline void* __gxx_caught_object(_Unwind_Exception* eo) { // Bad as it looks, this actua

Re: C++ PATCHes to run testsuite in C++14 mode

2014-03-25 Thread Jason Merrill
On 03/25/2014 12:32 PM, Smith-Rowland, Edward M wrote: I noticed while converting some of my test cases to use the new targets that gnu targets don't seem to work. Right. To get -std=gnu* you specify the standard level and then use dg-options "". Jason

Re: [Patch, AArch64] Fix shuffle for big-endian.

2014-03-25 Thread Tejas Belagod
Richard Henderson wrote: On 02/21/2014 08:30 AM, Tejas Belagod wrote: + /* If two vectors, we end up with a wierd mixed-endian mode on NEON. */ + if (BYTES_BIG_ENDIAN) + { + if (!d->one_vector_p && d->perm[i] & nunits) + { + /* Extract the offset.

Re: [Patch, AArch64] Fix shuffle for big-endian.

2014-03-25 Thread Tejas Belagod
Alan Lawrence wrote: Further to that - all looks good after one-liner http://gcc.gnu.org/ml/gcc-patches/2014-03/msg01142.html has gone in. (Without that, enabling the code in Tejas' patch causes a regression in gcc.dg/torture/vshuf-v4hi.c as loading a vector constant goes wrong). Thanks for

Re: [PATCH] Don't bootstrap libsanitizer or libvtv unless needed

2014-03-25 Thread Paolo Bonzini
Il 20/03/2014 13:24, Jakub Jelinek ha scritto: Hi! We currently bootstrap both libsanitizer and libvtv, the former just in case somebody decides to --with-build-config=bootstrap-asan (or --with-build-config=bootstrap-ubsan), the latter if somebody decides to --enable-vtable-verify. This patch c

Re: C++ PATCHes to run testsuite in C++14 mode

2014-03-25 Thread Smith-Rowland, Edward M
Jason, I noticed while converting some of my test cases to use the new targets that gnu targets don't seem to work. It doesn't matter for the test cases at hand but we might want to consider target gnu++11 target gnu++11_only target gnu++1y target gnu++1y_only

[PATCH, rs6000] Improve atomic_load/store code gen for Power8 TI mode

2014-03-25 Thread Pat Haugen
Power8 can use lq/stq instructions for TI mode atomic_load/store. Bootstrap/regtest with no new failures. Ok for trunk and 4.8 (once bootstrap/regtest finishes)? -Pat 2014-03-25 Pat Haugen * config/rs6000/sync.md (AINT mode_iterator): Move definition. (loadsync_): Change m

[PATCH] Fix undefined behavior in IRA

2014-03-25 Thread Marek Polacek
This is a temporary fix for UB in IRA, where ubsan complains because there's signed iteger overflow in the multiplication. To shut this error up, we can perform the multiplication in unsigned and only then cast the result of the multiplication to int. Regtested/bootstrapped on x86_64-linux, ok f

[DOC PATCH] Describe VLAs in struct/union (PR c/37428)

2014-03-25 Thread Marek Polacek
We should mention this GNU C extension in the manual. Ok? 2014-03-25 Marek Polacek PR c/37428 * doc/extend.texi (C Extensions): Mention variable-length arrays in a structure/union. diff --git gcc/doc/extend.texi gcc/doc/extend.texi index 986cc94..b564ade 100644 --- gc

RFA: Fix PR rtl-optimization/60651

2014-03-25 Thread Joern Rennecke
As described in the PR, this patch fixes a wrong-code bug by making the order of emitted mode switching instructions more consistet & predictable. Bootstrapped / regtested on i686-pc-linux-gnu. tmp Description: Binary data

Re: [PATCH AArch64] Fix aarch64_simd_valid_immediate for Bigendian

2014-03-25 Thread James Greenhalgh
On Mon, Mar 24, 2014 at 11:32:39AM +, Marcus Shawcroft wrote: > On 21 March 2014 14:55, Alan Lawrence wrote: > > This patch fixes a bug whereby a vector like V8QImode {1,0,1,0,1,0,1,0} can > > result in an instruction like > > > > movi v1.4h, 0x1 > > > > whereas on bigendian this should be > >

Re: [Build, Driver] Add -lcilkrts for -fcilkplus

2014-03-25 Thread Paolo Bonzini
Il 11/03/2014 07:42, Tobias Burnus ha scritto: +# Check to see if -pthread or -lpthread is needed. Prefer the former. +# In case the pthread.h system header is not found, this test will fail. +XPCFLAGS="" +CFLAGS="$CFLAGS -pthread" +AC_LINK_IFELSE( + [AC_LANG_PROGRAM( + [#include + void *g(

[PATCH][ARM/AArch64][1/2] Crypto intrinsics tuning for Cortex-A53 - "type" Attribute restructuring

2014-03-25 Thread Kyrill Tkachov
Hi all, This two-patch series adds scheduling information for the ARMv8-A Crypto instructions on the Cortex-A53. This first patch does some preliminary restructuring to allow the arm and aarch64 backends to share the is_neon_type attribute. It also splits the crypto_aes type into crypto_aese

[PATCH][ARM/AArch64][2/2] Crypto intrinsics tuning for Cortex-A53 - pipeline description

2014-03-25 Thread Kyrill Tkachov
Hi all, In ARMv8-A there's a general expectation that AESE/AESMC and AESD/AESIMC sequences of the form: AESE Vn, _ AESMC Vn, Vn will issue both instructions in a single cycle on super-scalar implementations. It would be nice to model that in our pipeline descriptions. This patch defines a f

Re: [PATCH][ARM] Handle FMA code in rtx costs.

2014-03-25 Thread Richard Earnshaw
On 24/03/14 17:15, Kyrill Tkachov wrote: > Hi all, > > This patch adds proper rtx costing logic for floating point fma operations on > arm. It also handles the fma+neg combinations that can be expressed with > vfms,vfnma or vfnms instructions. > Not much else to say here... > > Tested and boost

Re: [PATCH, ARM] Enable tail call optimization for long call

2014-03-25 Thread Marcus Shawcroft
On 24 March 2014 11:26, Jiong Wang wrote: > gcc/ > * config/arm/predicates.md (call_insn_operand): Add long_call check. > * config/arm/arm.md (sibcall, sibcall_value): Force the address to reg for > long_call. > * config/aarch64/aarch64.c (arm_function_ok_for_sibcall): Remove long_call > re

Re: [PATCH] Fix PR c++/60573

2014-03-25 Thread Jason Merrill
On 03/18/2014 10:46 PM, Adam Butcher wrote: + if (TYPE_BEING_DEFINED (scope->this_entity)) + if (scope->level_chain == 0 + || scope->this_entity != scope->level_chain->this_entity) + break; I don't think this is an adequate test; if yo

Re: [PATCH][ARM] Cortex-A8 rtx cost table

2014-03-25 Thread Richard Earnshaw
On 25/03/14 11:36, Kyrill Tkachov wrote: > Hi all, > > This patch adds the rtx cost table for the Cortex-A8 core. It's an ARMv7 > core, > so it goes into arm.c instead of aarch-cost-tables.h. > > Bootstrapped and tested on a Cortex-A8 Linux system and benchmarked to make > sure > no performan

Re: [PATCH, ARM] Enable tail call optimization for long call

2014-03-25 Thread Richard Earnshaw
On 24/03/14 11:26, Jiong Wang wrote: > This patch enables tail call optimization for long call on arm. > > Previously we have too strict check on arm_function_ok_for_sibcall and > be lack of the support on sibcall/sibcall_value expand that long call tail > oppportunities are lost. > > OK for nex

Re: Please revert the patches in bug #54040 and #59346 and special case x32

2014-03-25 Thread Svante Signell
Hi, Should I file a bug to get feedback on this issue? I know Ada is not the most prioritized language for gcc, but anyway. The current implementation is not POSIX-compliant. On Mon, 2014-03-24 at 14:37 +0100, Svante Signell wrote: > In reply to the thread ending with: > http://gcc.gnu.org/ml/gc

Re: [PATCH] Fix %K for LTO

2014-03-25 Thread Richard Biener
On Tue, 25 Mar 2014, Jakub Jelinek wrote: > On Tue, Mar 25, 2014 at 03:35:29PM +0100, Richard Biener wrote: > > The following implements a special-case for LTO when doing %K > > formatting. LTO currently only keeps FUNCTION_DECL abstract > > origins (for BLOCKs satisfying inlined_function_outer_s

[PATCH] Fix %K for LTO

2014-03-25 Thread Richard Biener
The following implements a special-case for LTO when doing %K formatting. LTO currently only keeps FUNCTION_DECL abstract origins (for BLOCKs satisfying inlined_function_outer_scope_p) which means the existing %K formatting usually bails out immediately. This severely complicates the search for w

Re: [PATCH] Environment variables forwarding

2014-03-25 Thread Yury Gribov
Cc-ing Jakub cause he's the author of original set-target-env-var support in GCC testsuite. On 03/24/2014 01:46 PM, Maxim Ostapenko wrote: Adding Dejagnu list this time. On 03/24/2014 12:28 PM, Maxim Ostapenko wrote: Hi all, When porting Lsan on arm, I ran into problem with testing, because

Re: [PATCH] Fix %K for LTO

2014-03-25 Thread Jakub Jelinek
On Tue, Mar 25, 2014 at 03:35:29PM +0100, Richard Biener wrote: > The following implements a special-case for LTO when doing %K > formatting. LTO currently only keeps FUNCTION_DECL abstract > origins (for BLOCKs satisfying inlined_function_outer_scope_p) > which means the existing %K formatting us

Re: [RFC] Remove PUSH_ARGS_REVERSED from the RTL expander.

2014-03-25 Thread Michael Matz
Hi, On Mon, 24 Mar 2014, Richard Henderson wrote: > See > > http://en.wikipedia.org/wiki/X86_calling_conventions#pascal > > Since we don't actually support this anymore, we can certainly tidy this > up. Yeah, I thought about that, but I couldn't see how that could have used PUSH_ARGS_REVER

Re: [patch] Shorten Windows path

2014-03-25 Thread Ian Lance Taylor
On Tue, Mar 25, 2014 at 1:58 AM, Joey Ye wrote: > Ping This code looks different on mainline. Writing "if ( do_canonical )" is not GCC style. This patch does not respect the configure option --disable-canonical-system-headers. Also I personally don't actually know what the consequences would b

Re: [PATCH] [C++ RFC] Support named type capture for generic lambdas and generic functions as proposed by N3878

2014-03-25 Thread Andrew Sutton
It's not clear that this feature will be part of concepts. It will not be included in the initial working paper, so the proposal will need to be re-evaluated. Andrew On Tue, Mar 25, 2014 at 3:03 AM, Adam Butcher wrote: > * parser.c (cp_parser_simple_type_specifier): Lookahead for a brac

[ARM] Fix PR target/60504

2014-03-25 Thread Eric Botcazou
Hi, because of popular demand we switched the Ada compiler to ZCX, i.e. table- driven EH scheme, on ARM/Linux, only to discover that GCC doesn't generate correct EH tables, which means that the Ada compiler cannot catch exceptions. See also the earlier message posted by Tristan: http://gcc.gnu

[PATCH] PR debug/57519 - Emit DW_TAG_imported_declaration under the right class for 'using' statements in a class

2014-03-25 Thread Siva Chandra
Hello, This is a re-posting of the patch I had posted 2 weeks back. I could locate a PR for it, hence I am posting it now with the PR annotations. Though the bug is in the 'debug' component, because of the nature of the fix, I think it should be treated as a bug in the 'c++' component. The patch i

Re: [PATCH] Fix ubsan i?86 {add,sub,mul}v4 patterns

2014-03-25 Thread Uros Bizjak
On Tue, Mar 25, 2014 at 11:17 AM, Jakub Jelinek wrote: > On Tue, Mar 25, 2014 at 09:12:14AM +0100, Uros Bizjak wrote: >> > The bootstrap-ubsan bootstrap revealed a problem with the >> > {add,sub,mul}v4 patterns. The problem is that they >> > accept CONST_INT operands (because the instructions do

[PATCH][ARM] Cortex-A8 rtx cost table

2014-03-25 Thread Kyrill Tkachov
Hi all, This patch adds the rtx cost table for the Cortex-A8 core. It's an ARMv7 core, so it goes into arm.c instead of aarch-cost-tables.h. Bootstrapped and tested on a Cortex-A8 Linux system and benchmarked to make sure no performance regressions. There are various small improvements here a

[PATCH] Fix PR60635

2014-03-25 Thread Richard Biener
The following fixes PR60635 - we fail to update re-gimplified stmts in gimple_regimplify_operands (or anywhere near its callers AFAIK). It seems coverage is quite low as this must otherwise have been noticed earlier ... Bootstrapped on x86_64-unknown-linux-gnu, testing in progress. Richard. 201

Re: [PATCH] PR debug/16063. Add DW_AT_type to DW_TAG_enumeration.

2014-03-25 Thread Mark Wielaard
On Mon, 2014-03-24 at 09:57 -0700, Cary Coutant wrote: > > gcc/cp/ > > * dwarf2out.c (gen_enumeration_type_die): Add DW_AT_type if > > enum_underlying_base_type defined and DWARF version > 3. > > * langhooks.h (struct lang_hooks_for_types): Add > > enum_underlying_ba

Re: [PATCH] Fix ubsan i?86 {add,sub,mul}v4 patterns

2014-03-25 Thread Jakub Jelinek
On Tue, Mar 25, 2014 at 09:12:14AM +0100, Uros Bizjak wrote: > > The bootstrap-ubsan bootstrap revealed a problem with the > > {add,sub,mul}v4 patterns. The problem is that they > > accept CONST_INT operands (because the instructions do accept immediates), > > but to model what the instruction act

Re: [PATCH, ARM] Enable tail call optimization for long call

2014-03-25 Thread Ramana Radhakrishnan
> > > gcc/ > * config/arm/predicates.md (call_insn_operand): Add long_call check. > * config/arm/arm.md (sibcall, sibcall_value): Force the address to reg for > long_call. > * config/aarch64/aarch64.c (arm_function_ok_for_sibcall): Remove long_call > restriction. config/arm/arm.c :) The ARM

[PATCH] Fix -fPIE non-handling in lto-wrapper

2014-03-25 Thread Richard Biener
We handle -fpie but not -fPIE - obviously an oversight. Committed as obvious. Richard. 2014-03-25 Richard Biener * lto-wrapper.c (merge_and_complain): Handle OPT_fPIE like OPT_fpie. (run_gcc): Likewise. Index: gcc/lto-wrapper.c ==

Re: [PATCH] Fix folding of UBSAN_CHECK_SUB (x, 0) etc.

2014-03-25 Thread Jakub Jelinek
On Tue, Mar 25, 2014 at 10:15:37AM +0100, Richard Biener wrote: > On Tue, 25 Mar 2014, Richard Biener wrote: > > > While working on previous patch, I've noticed a severe omission in the > > > -fsanitize=signed-integer-overflow support. Nothing ever > > > folds addition/subtraction of 0 and multipl

Re: [PATCH] Perform ubsan instrumentation for x >= 0 ? x : -x

2014-03-25 Thread Richard Biener
On Tue, 25 Mar 2014, Jakub Jelinek wrote: > On Tue, Mar 25, 2014 at 10:09:26AM +0100, Richard Biener wrote: > > On Tue, 25 Mar 2014, Jakub Jelinek wrote: > > > > > Hi! > > > > > > While Marek has been debugging while some perl test fails when perl is > > > built > > > with GCC 4.9, we've discov

Re: [PATCH] Perform ubsan instrumentation for x >= 0 ? x : -x

2014-03-25 Thread Jakub Jelinek
On Tue, Mar 25, 2014 at 10:09:26AM +0100, Richard Biener wrote: > On Tue, 25 Mar 2014, Jakub Jelinek wrote: > > > Hi! > > > > While Marek has been debugging while some perl test fails when perl is built > > with GCC 4.9, we've discovered that it is because of undefined behavior in > > it: > > ...

Re: [C++ PATCH] Fix -std=c++11 OpenMP UDR handling (PR c++/60331)

2014-03-25 Thread Jakub Jelinek
On Mon, Mar 24, 2014 at 02:02:27PM -0400, Jason Merrill wrote: > On 03/18/2014 11:16 AM, Jakub Jelinek wrote: > >Jason, do you have better ideas how to fix this? > > Better would be to return false from potential_constant_expression_1 > for DECL_EXPR; just add another case to the various _STMT tre

Re: [PATCH] Fix folding of UBSAN_CHECK_SUB (x, 0) etc.

2014-03-25 Thread Richard Biener
On Tue, 25 Mar 2014, Richard Biener wrote: > On Tue, 25 Mar 2014, Jakub Jelinek wrote: > > > Hi! > > > > While working on previous patch, I've noticed a severe omission in the > > -fsanitize=signed-integer-overflow support. Nothing ever > > folds addition/subtraction of 0 and multiplication by

Re: [PATCH] Correct typos in gccint.texi.

2014-03-25 Thread Andreas Krebbel
On Thu, Mar 20, 2014 at 06:52:13AM +0100, Dominik Vogt wrote: > 2014-03-20 Dominik Vogt > > * doc/generic.texi: Correct typos. Applied. Thanks! -Andreas-

Re: [PATCH][AARCH64]PR60034

2014-03-25 Thread Marcus Shawcroft
On 25 March 2014 04:55, Kugan wrote: > gcc/ > > 2014-03-25 Kugan Vivekanandarajah > > PR target/60034 > * aarch64/aarch64.c (aarch64_classify_address): Fix alignment for > section anchor. > > gcc/testsuite/ > > 2014-03-25 Kugan Vivekanandarajah > > PR target/

Re: [PATCH] Fix folding of UBSAN_CHECK_SUB (x, 0) etc.

2014-03-25 Thread Richard Biener
On Tue, 25 Mar 2014, Jakub Jelinek wrote: > Hi! > > While working on previous patch, I've noticed a severe omission in the > -fsanitize=signed-integer-overflow support. Nothing ever > folds addition/subtraction of 0 and multiplication by [0,1], none of these > may ever overflow and thus we can f

Re: [PATCH] Perform ubsan instrumentation for x >= 0 ? x : -x

2014-03-25 Thread Richard Biener
On Tue, 25 Mar 2014, Jakub Jelinek wrote: > Hi! > > While Marek has been debugging while some perl test fails when perl is built > with GCC 4.9, we've discovered that it is because of undefined behavior in > it: > ... > && (((UV)1 << NV_PRESERVES_UV_BITS) > > (UV)(SvIVX(sv) > 0 ? SvIVX(sv

Re: [PATCH] Fix undefined behavior in the combiner

2014-03-25 Thread Richard Biener
On Tue, 25 Mar 2014, Jakub Jelinek wrote: > Hi! > > simplify_compare_const is sometimes called with two CONST_INTs, > which means mode is VOIDmode and mode_width is 0, but then it > happily verifies that mode_width is <= HOST_BITS_PER_WIDE_INT > and shits stuff by mode_width - 1 (i.e. -1). > From

Re: [PATCH] Fix two spots with undefined behavior

2014-03-25 Thread Richard Biener
On Tue, 25 Mar 2014, Jakub Jelinek wrote: > Hi! > > These two spots were determined by --with-build-config=bootstrap-ubsan > as having undefined signed integer overflow. > > Fixed thusly, bootstrapped/regtested on x86_64-linux and i686-linux, > ok for trunk? Ok. Thanks, Richard. > 2014-03-25

RE: [patch] Shorten Windows path

2014-03-25 Thread Joey Ye
Ping > -Original Message- > From: Joey Ye [mailto:joey...@arm.com] > Sent: 19 February 2014 15:45 > To: gcc-patches@gcc.gnu.org; Ian Lance Taylor (i...@google.com) > Subject: [patch] Shorten Windows path > > Max length of path on Windows is 255, which is easy to exceed in a > complicated

Re: [PATCH] Fix PR59626, _FORTIFY_SOURCE wrappers and LTO

2014-03-25 Thread Richard Biener
On Tue, 25 Mar 2014, Jan Hubicka wrote: > > > > Currently a _lot_ of packages fail to build with LTO because LTO > > messes up fortify wrappers by replacing the call to the alias with > > the symbol itself, making the wrapper look like infinitely > > recursing. > > > > The following patch fixes

[PATCH, PR 60580, AArch64] Fix __attribute__ ((optimize("no-omit-frame-pointer")))

2014-03-25 Thread Marcus Shawcroft
Hi, The implementation of -m[no-]omit-leaf-frame-pointer and -f[no-]omit-frame-pointer in the AArch64 target does not behave correctly in the presence of __attribute__ optimize. This patch adjusts the implementation to work in a similar fashion to the same functionality in the i386 target.

Re: [PATCH] Fix PR59626, _FORTIFY_SOURCE wrappers and LTO

2014-03-25 Thread Richard Biener
On Mon, 24 Mar 2014, Jan Hubicka wrote: > > > > Currently a _lot_ of packages fail to build with LTO because LTO > > messes up fortify wrappers by replacing the call to the alias with > > the symbol itself, making the wrapper look like infinitely > > recursing. > > > > The following patch fixes

[PATCH, ARM] Enable shrink-wrap for apcs frame

2014-03-25 Thread Zhenqiang Chen
Hi The patch enables shrink-wrap for apcs frame. Bootstrap and no make check regression in ARM, THUMB1 and THUMB2 modes. No make check regression with "-g/-mapcs/-marm". Build linux-3.14-rc7 without error. Is it OK for next stage1? Thanks! -Zhenqiang ChangeLog: 2014-03-25 Zhenqiang Chen

Re: [PATCH] Fix ubsan i?86 {add,sub,mul}v4 patterns

2014-03-25 Thread Uros Bizjak
On Tue, Mar 25, 2014 at 8:24 AM, Jakub Jelinek wrote: > Hi! > > The bootstrap-ubsan bootstrap revealed a problem with the > {add,sub,mul}v4 patterns. The problem is that they > accept CONST_INT operands (because the instructions do accept immediates), > but to model what the instruction actually

[patch, Fortran] Fix PR 60522

2014-03-25 Thread Thomas Koenig
Hello world, the attached patch fixes the regression (after some thought of what might still be optimized, which isn't much :-) Regression-tested. OK for trunk? Thomas 2014-04-25 Thomas Koenig PR fortran/60522 * frontend-passes.c (cfe_code): Do not walk subtrees

Re: [RFC] Do not consider volatile asms as optimization barriers #1

2014-03-25 Thread Yury Gribov
Jakub Jelinek wrote: Richard Sandiford wrote: OK, how about this? It looks like the builtins.c and stmt.c stuff wasn't merged until 4.9, and at this stage it seemed safer to just add the same use/clobber sequence to both places. Please wait a little bit, the patch has been committed to the tr

[PATCH] Fix folding of UBSAN_CHECK_SUB (x, 0) etc.

2014-03-25 Thread Jakub Jelinek
Hi! While working on previous patch, I've noticed a severe omission in the -fsanitize=signed-integer-overflow support. Nothing ever folds addition/subtraction of 0 and multiplication by [0,1], none of these may ever overflow and thus we can fold them to normal operations and let those be folded a

[PATCH] Fix ubsan i?86 {add,sub,mul}v4 patterns

2014-03-25 Thread Jakub Jelinek
Hi! The bootstrap-ubsan bootstrap revealed a problem with the {add,sub,mul}v4 patterns. The problem is that they accept CONST_INT operands (because the instructions do accept immediates), but to model what the instruction actually does, we need to have both the value of the operand itself and it'

[PATCH] Perform ubsan instrumentation for x >= 0 ? x : -x

2014-03-25 Thread Jakub Jelinek
Hi! While Marek has been debugging while some perl test fails when perl is built with GCC 4.9, we've discovered that it is because of undefined behavior in it: ... && (((UV)1 << NV_PRESERVES_UV_BITS) > (UV)(SvIVX(sv) > 0 ? SvIVX(sv) : -SvIVX(sv))) where SvIVX(sv) can be LONG_MIN, at which

[PATCH] Fix undefined behavior in the combiner

2014-03-25 Thread Jakub Jelinek
Hi! simplify_compare_const is sometimes called with two CONST_INTs, which means mode is VOIDmode and mode_width is 0, but then it happily verifies that mode_width is <= HOST_BITS_PER_WIDE_INT and shits stuff by mode_width - 1 (i.e. -1). >From what I can understand, some optimizations can be still

[PATCH] Fix two spots with undefined behavior

2014-03-25 Thread Jakub Jelinek
Hi! These two spots were determined by --with-build-config=bootstrap-ubsan as having undefined signed integer overflow. Fixed thusly, bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk? 2014-03-25 Jakub Jelinek * cselib.c (cselib_hash_rtx): Perform addition in unsign

[PATCH] [C++ RFC] Support named type capture for generic lambdas and generic functions as proposed by N3878

2014-03-25 Thread Adam Butcher
* parser.c (cp_parser_simple_type_specifier): Lookahead for a braced identifier after a generic type ('auto') parameter and, if present, use that as the type identifier name. Otherwise generate one with make_generic_type_name. Pass the resulting identifier as the n

  1   2   >