lkml.org 
[lkml]   [1998]   [Aug]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: FASTCALL in egcs was Re: Kernel 2.1.117 OOPS bug report
Andrea Arcangeli wrote:
>I fixed gcc this way:
> TIMEVAR (combine_time, combine_instructions (insns, max_reg_num ()));

The patch basically is correct.
Actually, the patch could be made more specific. The remaining problem
with regparm indeed is in the combine-instructions phase, there's actually
a very specific loop in this phase that, if skipped, eliminates the problem
(also weakens the optimisation a bit, obviously).

>The _only_ problem seems to be that sometimes gcc uses %%eax to recall a
>function with the regparm() attribute set.

Yep. Gcc is basically panicing then, since it already has some registers
preloaded with arguments, then needs to load a register with the address
to jump to. It *can* be done, obviously, but since gcc is not so good
in very low register situations (this is about as bad as it can get),
this is where it panics and grabs something it shouldn't have.
--
Sincerely, srb@cuci.nl
Stephen R. van den Berg (AKA BuGless).

Skiing beyond this point may result in death and/or loss of skiing privileges.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.altern.org/andrebalsa/doc/lkml-faq.html

\
 
 \ /
  Last update: 2005-03-22 13:44    [W:0.054 / U:3.248 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site