git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH 1/2] Remove noreturn function pointers in usage.c

From
Erik Faye-Lund <kusmabite@gmail.com>
Date
Jun 9, 2011, 21:13 UTC
Message-ID
<BANLkTimxA9yRHFt8jX2kEM8JvNoO5AOcYA@mail.gmail.com>
In-Reply-To
<20110609063145.GC15448@one.firstfloor.org>
On Thu, Jun 9, 2011 at 8:31 AM, Andi Kleen <andi@firstfloor.org> wrote:
Show 21 quoted lines
> On Thu, Jun 09, 2011 at 01:52:24AM -0400, Jeff King wrote:
>> On Thu, Jun 09, 2011 at 06:59:15AM +0200, Andi Kleen wrote:
>>
>> > >  - Potential impact to people who do not use Gcc 4.6 with profile feedback
>> > >    is not explained away well, except for "Doesn't seem to make any
>> > >    difference."
>> >
>> > I merely went by "there are no new warnings" (I assume that's the main
>> > motivation)
>>
>> On your compiler and settings, perhaps. With your patch I get:
>>
>>   usage.c: In function ‘die’:
>>   usage.c:70:1: error: ‘noreturn’ function does return [-Werror]
>
> Ok.  Hmm, all I can say it compiled here.
>
> Ok then we have to remove it. I didn't really like Junio's approach
> to only do it for a single file because that would break with LTO / link
> time optimization which requires declarations to match between
> translation units.

Junio's approach didn't do it for a single file, it disabled the NORETURN mechanism all together, by having a Makefile-switch.

> BTW 4.6.2 or so will have the problem fixed.

If it's only in 4.6 through 4.6.2, then we probably don't even need a Makefile-switch for junio's approach at all; just checking the GCC version should be reliable enough, no?

Previous: Andi Kleen
Message 7 of 7 in “Remove noreturn function pointers in usage.c”
  1. 1/2 Remove noreturn function pointers in usage.cAndi Kleen, Jun 8, 2011
  2. 2/2 Add profile feedback build to gitAndi Kleen, Jun 8, 2011
  3. Junio C HamanoJun 9, 2011
  4. Andi KleenJun 9, 2011
  5. Jeff KingJun 9, 2011
  6. Andi KleenJun 9, 2011
  7. Erik Faye-LundJun 9, 2011

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.