Throwing exceptions from a .so linked with -static-lib* ?

2017-01-11 Thread Paul Smith
TL;DR: I have an issue where if I have a .so linked with -static-lib* making all STL symbols private, and if I throw an exception out of that .so to be caught by the caller, then I get a SIGABRT from a gcc_assert() down in the guts of the signal handling: #0  0x7773a428 in raise () from /l

Re: Help with integrating my test program into dejagnu

2017-01-11 Thread Daniel Santos
On 01/11/2017 12:25 PM, Joseph Myers wrote: A test [istarget x86_64-*-gnu] is wrong; i?86-* -m64 should always be handled exactly the same as x86_64-* -m64. You need to work out which ABIs (-m32, -mx32, -m64) this testing is meaningful for. Then, allow both x86_64- and i?86- targets, together w

Re: Help with integrating my test program into dejagnu

2017-01-11 Thread Joseph Myers
A test [istarget x86_64-*-gnu] is wrong; i?86-* -m64 should always be handled exactly the same as x86_64-* -m64. You need to work out which ABIs (-m32, -mx32, -m64) this testing is meaningful for. Then, allow both x86_64- and i?86- targets, together with an appropriate effective-target test ("

Re: Worse code after bbro?

2017-01-11 Thread Segher Boessenkool
On Thu, Jan 05, 2017 at 07:39:21PM +0100, Jan Hubicka wrote: > In fact cfglayout was invented to implement bb-reorder originally :) So, hrm, are there any passes we *want* to do in non-cfglayout mode? Segher

Re: k-byte memset/memcpy/strlen builtins

2017-01-11 Thread Aaron Sawdey
On Wed, 2017-01-11 at 17:16 +0100, Robin Dapp wrote: > Hi, Hi Robin, I thought I'd share some of what I've run into while doing similar things for the rs6000 target. First off, be aware that glibc does some macro expansion things to try to handle 1/2/3 byte string operations in some cases. Sec

Re: k-byte memset/memcpy/strlen builtins

2017-01-11 Thread Richard Biener
On January 11, 2017 5:16:43 PM GMT+01:00, Robin Dapp wrote: >Hi, > >When examining the performance of some test cases on s390 I realized >that we could do better for constructs like 2-byte memcpys or >2-byte/4-byte memsets. Due to some s390-specific architectural >properties, we could be faster b

Re: Help with integrating my test program into dejagnu

2017-01-11 Thread Mike Stump
On Jan 10, 2017, at 9:13 PM, Daniel Santos wrote: > I've gotten rid of the Makefile and everything is run now from msabi.exp. > I've also gotten rid of the header file, now that I know how to define a > "_noinfo" fn pointer, so it's down to just 4 files: msabi.exp, gen.cc, > msabi.c and do_tes

k-byte memset/memcpy/strlen builtins

2017-01-11 Thread Robin Dapp
Hi, When examining the performance of some test cases on s390 I realized that we could do better for constructs like 2-byte memcpys or 2-byte/4-byte memsets. Due to some s390-specific architectural properties, we could be faster by e.g. avoiding excessive unrolling and using dedicated memory instr

Re: LTO remapping/deduction of machine modes of types/decls

2017-01-11 Thread Alexander Monakov
On Wed, 11 Jan 2017, Richard Biener wrote: > > WPA re-streams packed function bodies as-is, so anything referred to > > from within just the body won't be subject to mode remapping; I think > > only modes of toplevel declarations and functions' arguments will be > > remapped. And I believe it woul

Re: LTO remapping/deduction of machine modes of types/decls

2017-01-11 Thread Richard Biener
On Tue, 10 Jan 2017, Alexander Monakov wrote: > On Tue, 10 Jan 2017, Richard Biener wrote: > > In general I think they should match. But without seeing concrete > > examples of where they do not I can't comment on whether such exceptions > > make sense. For example if you adjust a DECLs alignme