2.4.35.1 and panic at boot with arch=c3 and gcc-4.x

From: Willy Tarreau
Date: Wed Sep 05 2007 - 18:00:51 EST


Axel, Richard,

you both reported a very similar problem to me (panic at boot on VIA c3
with 2.4.35.1 when built with gcc-4.1). I could reproduce the problem
with your configs here and compare the code with your working builds.

I finally tracked the problem down to a dirty trick used to prevent
do_test_wp_bit() from being inlined (Axel, you identified the right
file). Unfortunately, this trick does not work anymore when gcc-4.x
is used without -fno-unit-at-a-time, so let's use the correct method
instead. I really hope that this trick is not used anywhere else!

The following patch fixes the issue for me. Could you please give it a
try before I merge it?

Thanks in advance,
Willy

--