GCC inline bug on -current

From: Poul-Henning Kamp <phk_at_phk.freebsd.dk>
Date: Sun, 28 Jun 2009 13:37:32 +0000
While hacking up some code on "8.0-CURRENT #0 r195095M: Sat Jun 27
12:24:33 UTC 2009", I have run into a GCC bug with inlining:

Download the three files in this directory:

	http://phk.freebsd.dk/misc/P

Run "make test"

The #if in line 183 controls if the function FindLoops() is inlined.

If it is not inlined, the program runs to completion with the message
	347 loops

If it is inlined, the program enters an infinite loop.

Enjoy...

-- 
Poul-Henning Kamp       | UNIX since Zilog Zeus 3.20
phk_at_FreeBSD.ORG         | TCP/IP since RFC 956
FreeBSD committer       | BSD since 4.3-tahoe
Never attribute to malice what can adequately be explained by incompetence.
Received on Sun Jun 28 2009 - 11:56:28 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:50 UTC