[M3devel] assembly goes to C compiler?

Olaf Wagner wagner at elegosoft.com
Mon Aug 3 13:21:58 CEST 2009


Quoting Jay K <jay.krell at cornell.edu>:

> Does this surprising anyone else:
>
> PROCEDURE CompileS (s: State;  u: M3Unit.T) =
> ...
>     ELSIF (u.kind = UK.S) THEN
>       RunCC (s, UnitPath (u), u.object, u.debug, u.optimize);

Indeed! I must say that I was not aware of it.
Im not sure if it is an oversight, a hack, or an intended feature.
In the last case we should eliminate the assembly methods from the
config files.

What happens if we run the quake assembly method instead?
Does that break lots of systems?

> I kept modifying SYSTEM_ASM thinking it would affect how   
> RTMachineASM.s is assembled,
> but it doesn't. I actually was thinking it might be nice to have two  
>  assembly functions,
> one for the output of m3cg, one for user written code. So, we do in fact have
> two functions, but one is the function for compiling C!. I'd want a   
> third function, ideally.
>
> I'll leave this alone and just special case RTMachineASM.s in the   
> config file, if that works out.
>
> That is, I'll try a very targeted slighly inelegant change, goal being
> to assemble this particular file with /usr/ccs/bin/as instead of the  
>  C compiler,
> on SOLgnu only.

That doesn't sound very nice. We should really investigate why
RunCC is used even for assembly code.

Olaf
-- 
Olaf Wagner -- elego Software Solutions GmbH
                Gustav-Meyer-Allee 25 / Gebäude 12, 13355 Berlin, Germany
phone: +49 30 23 45 86 96  mobile: +49 177 2345 869  fax: +49 30 23 45 86 95
    http://www.elegosoft.com | Geschäftsführer: Olaf Wagner | Sitz: Berlin
Handelregister: Amtsgericht Charlottenburg HRB 77719 | USt-IdNr: DE163214194




More information about the M3devel mailing list