9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: Lucio De Re <lucio@proxima.alt.za>
To: 9fans@cse.psu.edu
Subject: Re: [9fans] Alef PPC code generation problem
Date: Tue,  2 Apr 2002 14:26:00 +0200	[thread overview]
Message-ID: <20020402142559.F6290@cackle.proxima.alt.za> (raw)
In-Reply-To: <20020402121506.9816C19995@mail.cse.psu.edu>; from forsyth@vitanuova.com on Tue, Apr 02, 2002 at 01:11:20PM +0100

On Tue, Apr 02, 2002 at 01:11:20PM +0100, forsyth@vitanuova.com wrote:
>
> i'm confused.  in the example you sent,
> 	t = 13*i;
> neither qal nor qc generates a type upgrade for constant 13;
> it generates an integer multiplication of 13 and i (as shifts and adds, but that's almost
> beside the point), and then converts the result, which is correct.
>
Oh, that would explain things.  So I got the wrong end of the stick
(why am I not surprised?), I read a simplistic interpretation of the
code where in fact there was additional depth.  It certainly makes
more sense, having had my nose rubbed in it.

> the code generated for the fp conversion by qc looks right to me.
> the code generated by qal (it turns out) has never been correct,
> which is consistent with the source code in qal's code.c looking
> wrong too.

Here I agree.  It is twisted, what both compilers do :-)  No Dijkstra
merit awards to the inventor of that abbreviation.  But it does work
for qc, not qal.  Shall I go ahead with a separate "instruction()"
procedure to deal with the special case(s)?  Or have you got a simpler
suggestion?

++L


  reply	other threads:[~2002-04-02 12:26 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-04-02 12:11 forsyth
2002-04-02 12:26 ` Lucio De Re [this message]
2002-04-02 12:42 ` Lucio De Re
  -- strict thread matches above, loose matches on Subject: below --
2002-04-02 12:50 forsyth
2002-04-02 13:03 ` Lucio De Re
2002-04-02 14:36 ` Lucio De Re
2002-04-02 11:41 Lucio De Re

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20020402142559.F6290@cackle.proxima.alt.za \
    --to=lucio@proxima.alt.za \
    --cc=9fans@cse.psu.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).