February 07, 2002
"Roland" <rv@ronetech.com> wrote in message news:3C624108.E6F7AE4B@ronetech.com...
> Why not ?
> If stack starts aligned, just manage yourself it stays so.
> Compiler can help:
> - for parameters: if totals size of parameter is not multiple of 4 (or 8),
it
> can pushs some dummy byte
> so that stack stays aligned.
> Unaligned parameters can be slow to acces but at least, stack is aligned
at
> function entry.
> For Pascal call convention, compiler still have to remove the dummy bytes
with
> add esp
> - for local data, it is the same.
> We can imagine all parameters are aligned (push 7 dummy byte and a
significat
> byte for a char parameter)
> The problem is for compatibility with other modules linked with DMC.
> Optimizer can do so only for function in the same module as the one
currently
> compiled.

What you suggest appears to be what GCC does.

What I do is slightly different. The called function, not the caller, figures out how many parameter bytes were pushed. Then, the size of the frame for the automatics is adjusted so the grand total works out to be a multiple of 8. The beauty of this is that most of the time no extra code is generated.

There are several special cases and complications with this, but I think I took care of all of them but the case of a varargs function. I've deferred fixing that for the moment.

-Walter


February 07, 2002

Walter a écrit :

> What I do is slightly different. The called function, not the caller, figures out how many parameter bytes were pushed. Then, the size of the frame for the automatics is adjusted so the grand total works out to be a multiple of 8. The beauty of this is that most of the time no extra code is generated.

nice !

> There are several special cases and complications with this, but I think I took care of all of them but the case of a varargs function. I've deferred fixing that for the moment.

for varargs, just a warning in the manual is enough as far as i'm concerned

Roland



February 07, 2002
"Roland" <rv@ronetech.com> wrote in message news:3C627B5E.1E0D5EFF@ronetech.com...
>
>
> Walter a écrit :
>
> > What I do is slightly different. The called function, not the caller, figures out how many parameter bytes were pushed. Then, the size of the frame for the automatics is adjusted so the grand total works out to be
a
> > multiple of 8. The beauty of this is that most of the time no extra code
is
> > generated.
>
> nice !
>
> > There are several special cases and complications with this, but I think
I
> > took care of all of them but the case of a varargs function. I've
deferred
> > fixing that for the moment.
>
> for varargs, just a warning in the manual is enough as far as i'm
concerned

The only varargs functions that mean anything anyway are printf and scanf, and they don't do heavy loops with doubles. So, while for completeness it should be fixed, as a practical matter it is irrelevant.


February 08, 2002
"Walter" <walter@digitalmars.com> wrote in message news:a3tdb7$i5i$1@digitaldaemon.com...
> I'll email you the fix so you can try it out (it happens with -o
or -o+speed).

I must confess that I checked my email every 5 minutes in the last 2 days... :)  Will this fix be available in the 8.27 release?  I can hardly wait to look at the COD file that the new compiler will generate!

Laurentiu


February 08, 2002
"Laurentiu Pancescu" <lpancescu@fastmail.fm> wrote in message news:a412rr$oj7$1@digitaldaemon.com...
>
> "Walter" <walter@digitalmars.com> wrote in message news:a3tdb7$i5i$1@digitaldaemon.com...
> > I'll email you the fix so you can try it out (it happens with -o
> or -o+speed).
>
> I must confess that I checked my email every 5 minutes in the last 2
days...
> :)  Will this fix be available in the 8.27 release?  I can hardly wait to look at the COD file that the new compiler will generate!

I emailed it to you, but your email server bounced it saying it didn't like attachments. Got an email address that can handle large attachments?


February 08, 2002
"Walter" <walter@digitalmars.com> wrote in message news:a419th$2knh$1@digitaldaemon.com...
> I emailed it to you, but your email server bounced it saying it didn't
like
> attachments. Got an email address that can handle large attachments?

Fastmail claims there's no limit on the size of files I send, and that I have 100M quota... strange!  Is it possible to put it somewhere (http or ftp), and just send me the link?  Even scp is fine... :)

Thanks,
  Laurentiu



February 08, 2002
"Laurentiu Pancescu" <lpancescu@fastmail.fm> wrote in message news:a41du4$2n6m$1@digitaldaemon.com...
> "Walter" <walter@digitalmars.com> wrote in message news:a419th$2knh$1@digitaldaemon.com...
> > I emailed it to you, but your email server bounced it saying it didn't
> like
> > attachments. Got an email address that can handle large attachments?
>
> Fastmail claims there's no limit on the size of files I send, and that I have 100M quota... strange!  Is it possible to put it somewhere (http or ftp), and just send me the link?  Even scp is fine... :)
>
> Thanks,
>   Laurentiu

Here's what I get:
----------------------------------------------------------------------------
----

This is the Postfix program at host fastmail.fm.

I'm sorry to have to inform you that the message returned below could not be delivered to one or more destinations.

For further assistance, please send mail to <postmaster>

If you do so, please include this problem report. You can delete your own text from the message returned below.

The Postfix program

<lpancescu@fastmail.fm>: host localhost[127.0.0.1] said: 552 Uuencoded
    attachments not accepted
 ---------------------------------------------------------------------------
-----


February 08, 2002
Strange... could you please try sending the attachment as MIME?  I always used MIME when sending something from work to my fastmail account, and it worked (I think the largest attachment was about 500k).

Laurentiu

"Walter" <walter@digitalmars.com> wrote in message news:a41imf$2pnk$6@digitaldaemon.com...
>
> "Laurentiu Pancescu" <lpancescu@fastmail.fm> wrote in message news:a41du4$2n6m$1@digitaldaemon.com...
> > "Walter" <walter@digitalmars.com> wrote in message news:a419th$2knh$1@digitaldaemon.com...
> > > I emailed it to you, but your email server bounced it saying it didn't
> > like
> > > attachments. Got an email address that can handle large attachments?
> >
> > Fastmail claims there's no limit on the size of files I send, and that I have 100M quota... strange!  Is it possible to put it somewhere (http or ftp), and just send me the link?  Even scp is fine... :)
> >
> > Thanks,
> >   Laurentiu
>
> Here's what I get:
> --------------------------------------------------------------------------
--
> ----
>
> This is the Postfix program at host fastmail.fm.
>
> I'm sorry to have to inform you that the message returned below could not be delivered to one or more destinations.
>
> For further assistance, please send mail to <postmaster>
>
> If you do so, please include this problem report. You can delete your own text from the message returned below.
>
> The Postfix program
>
> <lpancescu@fastmail.fm>: host localhost[127.0.0.1] said: 552 Uuencoded
>     attachments not accepted
>  -------------------------------------------------------------------------
--
> -----
>
>


1 2
Next ›   Last »