* linux-2.6.18-xen.hg compilation issue with gcc 4.3
@ 2008-05-21 13:19 Guillaume Rousse
2008-05-21 13:45 ` Keir Fraser
2008-05-21 13:49 ` Jan Beulich
0 siblings, 2 replies; 6+ messages in thread
From: Guillaume Rousse @ 2008-05-21 13:19 UTC (permalink / raw)
To: xen-devel
Hello.
The linux-2.6.18-xen.hg kernel fails to build with gcc 4.3, in linking
stage:
arch/i386/kernel/built-in.o: In function `sync_xen_wallclock':
time-xen.c:(.text+0x6141): undefined reference to `__udivdi3'
time-xen.c:(.text+0x618a): undefined reference to `__udivdi3'
arch/i386/kernel/built-in.o: In function `do_settimeofday':
(.text+0x63bd): undefined reference to `__udivdi3'
arch/i386/kernel/built-in.o: In function `do_settimeofday':
(.text+0x640b): undefined reference to `__udivdi3'
arch/i386/kernel/built-in.o: In function `do_settimeofday':
(.text+0x6489): undefined reference to `__udivdi3'
arch/i386/kernel/built-in.o:(.text+0x64d2): more undefined references to
`__udivdi3' follow
According to LKM, this is a known issue:
http://www.nabble.com/undefined-reference-to-__udivdi3-(gcc-4.3)-td17045078.html
However, I couldn't find any loop susceptible to be wrongly optimised in
incriminated code (sync_xen_wallclock in arch/i386/kernel/time-xen.c).
Any hint welcome.
--
Guillaume Rousse
Moyens Informatiques - INRIA Futurs
Tel: 01 69 35 69 62
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: linux-2.6.18-xen.hg compilation issue with gcc 4.3
2008-05-21 13:19 linux-2.6.18-xen.hg compilation issue with gcc 4.3 Guillaume Rousse
@ 2008-05-21 13:45 ` Keir Fraser
2008-05-21 15:22 ` Guillaume Rousse
2008-05-21 13:49 ` Jan Beulich
1 sibling, 1 reply; 6+ messages in thread
From: Keir Fraser @ 2008-05-21 13:45 UTC (permalink / raw)
To: Guillaume Rousse, xen-devel
On 21/5/08 14:19, "Guillaume Rousse" <Guillaume.Rousse@inria.fr> wrote:
> However, I couldn't find any loop susceptible to be wrongly optimised in
> incriminated code (sync_xen_wallclock in arch/i386/kernel/time-xen.c).
> Any hint welcome.
It's hidden in the __normalize_time() macro. Could you backport Jeremy's
upstream fix to the 2.6.18 kernel?
-- Keir
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: linux-2.6.18-xen.hg compilation issue with gcc 4.3
2008-05-21 13:45 ` Keir Fraser
@ 2008-05-21 15:22 ` Guillaume Rousse
2008-05-21 15:45 ` Keir Fraser
0 siblings, 1 reply; 6+ messages in thread
From: Guillaume Rousse @ 2008-05-21 15:22 UTC (permalink / raw)
To: Keir Fraser; +Cc: xen-devel
Keir Fraser a écrit :
> On 21/5/08 14:19, "Guillaume Rousse" <Guillaume.Rousse@inria.fr> wrote:
>
>> However, I couldn't find any loop susceptible to be wrongly optimised in
>> incriminated code (sync_xen_wallclock in arch/i386/kernel/time-xen.c).
>> Any hint welcome.
>
> It's hidden in the __normalize_time() macro. Could you backport Jeremy's
> upstream fix to the 2.6.18 kernel?
Ok, it works. Thanks.
--
Guillaume Rousse
Moyens Informatiques - INRIA Futurs
Tel: 01 69 35 69 62
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: linux-2.6.18-xen.hg compilation issue with gcc 4.3
2008-05-21 15:22 ` Guillaume Rousse
@ 2008-05-21 15:45 ` Keir Fraser
2008-05-21 15:48 ` Guillaume Rousse
0 siblings, 1 reply; 6+ messages in thread
From: Keir Fraser @ 2008-05-21 15:45 UTC (permalink / raw)
To: Guillaume Rousse; +Cc: xen-devel
On 21/5/08 16:22, "Guillaume Rousse" <Guillaume.Rousse@inria.fr> wrote:
>>> However, I couldn't find any loop susceptible to be wrongly optimised in
>>> incriminated code (sync_xen_wallclock in arch/i386/kernel/time-xen.c).
>>> Any hint welcome.
>>
>> It's hidden in the __normalize_time() macro. Could you backport Jeremy's
>> upstream fix to the 2.6.18 kernel?
> Ok, it works. Thanks.
Could you post the patch so we can check it in? With a signed-off-by line?
Thanks,
Keir
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: linux-2.6.18-xen.hg compilation issue with gcc 4.3
2008-05-21 15:45 ` Keir Fraser
@ 2008-05-21 15:48 ` Guillaume Rousse
0 siblings, 0 replies; 6+ messages in thread
From: Guillaume Rousse @ 2008-05-21 15:48 UTC (permalink / raw)
To: Keir Fraser; +Cc: xen-devel
[-- Attachment #1: Type: text/plain, Size: 593 bytes --]
Keir Fraser a écrit :
>
>
> On 21/5/08 16:22, "Guillaume Rousse" <Guillaume.Rousse@inria.fr> wrote:
>
>>>> However, I couldn't find any loop susceptible to be wrongly optimised in
>>>> incriminated code (sync_xen_wallclock in arch/i386/kernel/time-xen.c).
>>>> Any hint welcome.
>>> It's hidden in the __normalize_time() macro. Could you backport Jeremy's
>>> upstream fix to the 2.6.18 kernel?
>> Ok, it works. Thanks.
>
> Could you post the patch so we can check it in? With a signed-off-by line?
here it is.
--
Guillaume Rousse
Moyens Informatiques - INRIA Futurs
Tel: 01 69 35 69 62
[-- Attachment #2: xen-3.2.0-gcc4.3.patch --]
[-- Type: text/plain, Size: 671 bytes --]
Signed-off-by: Guillaume Rousse <Guillaume.Rousse@inria.fr>
diff -Naur --exclude '*~' linux-2.6.18-xen.hg/arch/i386/kernel/time-xen.c linux-2.6.18-xen.hg-gcc.4.3/arch/i386/kernel/time-xen.c
--- linux-2.6.18-xen.hg/arch/i386/kernel/time-xen.c 2008-02-06 22:18:37.000000000 +0100
+++ linux-2.6.18-xen.hg-gcc.4.3/arch/i386/kernel/time-xen.c 2008-05-21 16:23:42.000000000 +0200
@@ -140,10 +140,12 @@
static inline void __normalize_time(time_t *sec, s64 *nsec)
{
while (*nsec >= NSEC_PER_SEC) {
+ asm("" : "+r"(*nsec));
(*nsec) -= NSEC_PER_SEC;
(*sec)++;
}
while (*nsec < 0) {
+ asm("" : "+r"(*nsec));
(*nsec) += NSEC_PER_SEC;
(*sec)--;
}
[-- Attachment #3: Type: text/plain, Size: 138 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: linux-2.6.18-xen.hg compilation issue with gcc 4.3
2008-05-21 13:19 linux-2.6.18-xen.hg compilation issue with gcc 4.3 Guillaume Rousse
2008-05-21 13:45 ` Keir Fraser
@ 2008-05-21 13:49 ` Jan Beulich
1 sibling, 0 replies; 6+ messages in thread
From: Jan Beulich @ 2008-05-21 13:49 UTC (permalink / raw)
To: Guillaume Rousse, xen-devel
>However, I couldn't find any loop susceptible to be wrongly optimised in
>incriminated code (sync_xen_wallclock in arch/i386/kernel/time-xen.c).
>Any hint welcome.
__normalize_time()?
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2008-05-21 15:48 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-05-21 13:19 linux-2.6.18-xen.hg compilation issue with gcc 4.3 Guillaume Rousse
2008-05-21 13:45 ` Keir Fraser
2008-05-21 15:22 ` Guillaume Rousse
2008-05-21 15:45 ` Keir Fraser
2008-05-21 15:48 ` Guillaume Rousse
2008-05-21 13:49 ` Jan Beulich
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.