Re: [PATCH] perf test: Fix dwarf unwind for optimized builds.

2020-11-16 Thread Miguel Ojeda
On Mon, Nov 16, 2020 at 7:48 AM Ian Rogers wrote: > > GCC [0-9]+ :-) Perhaps just a reference to the GCC bug rather than a date. That would be very good. > In linux/compiler_attributes.h add: > #define __GCC4_has_attribute_disable_tail_calls 0 > to the #ifndef __has_attribute block. We can't do

Re: [PATCH] perf test: Fix dwarf unwind for optimized builds.

2020-11-15 Thread Miguel Ojeda
On Sat, Nov 14, 2020 at 9:14 PM Ian Rogers wrote: > > Unfortunately no GCC version actually has this fixed. Then we can say GCC <= 11 does not support it yet or something like that. > This seems overly complex and unnecessary. How is 1 condition more complex than 3 different ones? Cheers,

Re: [PATCH] perf test: Fix dwarf unwind for optimized builds.

2020-11-14 Thread Jiri Olsa
On Fri, Nov 13, 2020 at 04:08:03PM -0800, Ian Rogers wrote: > To ensure the stack frames are on the stack tail calls optimizations > need to be inhibited. If your compiler supports an attribute use it, > otherwise use an asm volatile barrier. > > The barrier fix was suggested here: >

Re: [PATCH] perf test: Fix dwarf unwind for optimized builds.

2020-11-14 Thread Miguel Ojeda
On Sat, Nov 14, 2020 at 1:08 AM 'Ian Rogers' via Clang Built Linux wrote: > > To ensure the stack frames are on the stack tail calls optimizations > need to be inhibited. If your compiler supports an attribute use it, > otherwise use an asm volatile barrier. > > The barrier fix was suggested

[PATCH] perf test: Fix dwarf unwind for optimized builds.

2020-11-13 Thread Ian Rogers
To ensure the stack frames are on the stack tail calls optimizations need to be inhibited. If your compiler supports an attribute use it, otherwise use an asm volatile barrier. The barrier fix was suggested here: https://lore.kernel.org/lkml/20201028081123.gt2...@hirez.programming.kicks-ass.net/