Re: [PATCH] Emit DW_AT_const_expr for constexpr variables (take 2)

2016-10-21 Thread Jason Merrill
On Fri, Oct 21, 2016 at 10:40 AM, Jakub Jelinek wrote: > On Fri, Oct 21, 2016 at 09:58:01AM -0400, Jason Merrill wrote: >> On Thu, Oct 20, 2016 at 2:27 PM, Jakub Jelinek wrote: >> > + if ((dwarf_version >= 4 || !dwarf_strict) >> >> Why >=4? Isn't this a

Re: [PATCH] Emit DW_AT_const_expr for constexpr variables (take 2)

2016-10-21 Thread Jakub Jelinek
On Fri, Oct 21, 2016 at 09:58:01AM -0400, Jason Merrill wrote: > On Thu, Oct 20, 2016 at 2:27 PM, Jakub Jelinek wrote: > > + if ((dwarf_version >= 4 || !dwarf_strict) > > Why >=4? Isn't this a DWARF 5 feature? It is actually DWARF 4 already. Looking at DWARF4 DW_AT_*

Re: [PATCH] Emit DW_AT_const_expr for constexpr variables (take 2)

2016-10-21 Thread Jason Merrill
On Thu, Oct 20, 2016 at 2:27 PM, Jakub Jelinek wrote: > + if ((dwarf_version >= 4 || !dwarf_strict) Why >=4? Isn't this a DWARF 5 feature? OK with that change. Jason

[PATCH] Emit DW_AT_const_expr for constexpr variables (take 2)

2016-10-20 Thread Jakub Jelinek
On Fri, Oct 14, 2016 at 07:31:16PM +0200, Jakub Jelinek wrote: > This relies on the previous langhook patch (which greatly simplifies it). > > I'm only handling variables for now, DW_AT_const_expr is just weird on > functions/methods, it is supposed to appear only on > DW_TAG_inlined_subroutine?

[PATCH] Emit DW_AT_const_expr for constexpr variables

2016-10-14 Thread Jakub Jelinek
Hi! This relies on the previous langhook patch (which greatly simplifies it). I'm only handling variables for now, DW_AT_const_expr is just weird on functions/methods, it is supposed to appear only on DW_TAG_inlined_subroutine? Bootstrapped/regtested on x86_64-linux and i686-linux, ok for