From: Dan Cross <crossd@gmail.com>
To: John Levine <johnl@taugh.com>
Cc: coff@tuhs.org
Subject: [COFF] Re: machine code translation, as mental architecture models
Date: Sat, 13 Jul 2024 15:42:24 -0400 [thread overview]
Message-ID: <CAEoi9W72ssW-Qr2g1qFTi9jrNOW__UHFHU6BwbiLYXbVQ6BMKA@mail.gmail.com> (raw)
In-Reply-To: <v6ui96$18k5$1@gal.iecc.com>
On Sat, Jul 13, 2024 at 2:50 PM John Levine <johnl@taugh.com> wrote:
> According to Ralph Corderoy <ralph@inputplus.co.uk>:
> >> Oh, no wonder the translator worked so well.
> >
> >Well, doesn't it depend on whether VAX MACRO kept the macros as
> >high-level entities when translating them, or if it processed macros in
> >the familiar way into instructions that sat at the same level as
> >hand-written ‘assembler’. I don't think this thread has made that clear
> >so far.
>
> It was a macro assembler. The macros generated assembler statements
> that got assembled the normal way. I agree with the person that every
> macro assembler I've ever seen did that. A semi-exception is the IBM
> assembler that also had a PUNCH statement that put records into the
> object file but I think that was only used to pass commands to the
> linker.
This is conflating two different things over the life of the MACRO-32
language. It certainly started out as a macro assembler, but with the
introduction of the Alpha, DEC turned it into a true compiler (where
the source language happens to be VAX assembly language) that
generated native code for whatever machine it was compiled for: VAX or
Alpha; using the GEM backends.
When Compaq started the port to Itanium, they employed the same
technique; this was maintained by HP.
VSI has shifted to using LLVM as their compiler backend for the x86_64
port, with ELF as the executable file format (and presumably for
object files as well). As I understand the current state of affairs,
there is a GEM to LLVM layer that interfaces between the still-GEM
output of compiler frontends and the LLVM backend, that performs
native code generation. Macro, in particular, bypasses most of the
LLVM optimization layer.
> The more relevant question is how they used the macros. If the macros
> were used consistently for semantically higher level things, the
> translator can use the semantics of the macros when translating.
As has been mentioned, they don't do this. The output of fully
expanded MACRO-32 is basically VAX assembly language, which is then
compiled in a manner similar to how one would compile preprocessed C.
- Dan C.
next prev parent reply other threads:[~2024-07-13 19:43 UTC|newest]
Thread overview: 41+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CAEoi9W4Nr8DyvgVKXZ+5ZQJEayFpMw=mLW_0STtZaATSZcCFYg@mail.gmail.com>
[not found] ` <20240710203422.284BA18C077@mercury.lcs.mit.edu>
[not found] ` <011a1e2a-6a73-ceaa-2b9c-9ca43daf41e7@bitsavers.org>
[not found] ` <20240710230010.D2D968F5DEE4@ary.qy>
2024-07-10 23:14 ` [COFF] Re: [TUHS] Re: machine code translation,as " segaloco via COFF
[not found] ` <20240710212641.E24548F5C32C@ary.qy>
2024-07-11 1:29 ` Dan Cross
[not found] ` <18977302-8934-ec96-9154-b3c53824e506@taugh.com>
2024-07-11 2:05 ` Dan Cross
2024-07-11 16:50 ` Paul Winalski
2024-07-11 20:32 ` Dave Horsfall
2024-07-12 16:23 ` John R Levine
2024-07-12 16:51 ` [COFF] " Paul Winalski
2024-07-12 17:02 ` John R Levine
2024-07-12 20:52 ` Dave Horsfall
2024-07-12 22:03 ` John Levine
2024-07-13 0:25 ` Aron Insinga
2024-07-13 0:27 ` Dave Horsfall
2024-07-13 1:19 ` Paul Winalski
[not found] ` <CABH=_VS8z6ayJSQab0u5Cxw--hM8px8-eFGjeFCKTXxe <alpine.BSF.2.21.9999.2407131018370.6233@aneurin.horsfall.org>
2024-07-13 2:25 ` John Levine
2024-07-13 9:57 ` [COFF] Re: machine code translation, as " Ralph Corderoy
2024-07-13 14:25 ` Dan Cross
2024-07-13 17:27 ` Aron Insinga
2024-07-12 17:03 ` [COFF] Re: machine code translation,as " Stuff Received
2024-07-12 18:01 ` Paul Winalski
2024-07-12 20:35 ` John Levine
2024-07-13 9:26 ` [COFF] Re: machine code translation, as " Ralph Corderoy
2024-07-12 18:54 ` [COFF] Re: machine code translation,as " Aron Insinga
2024-07-12 21:49 ` Dave Horsfall
[not found] ` <20240710203422.284BA18C077@mercury.lcs. <20240713095708.203D5220C9@orac.inputplus.co.uk>
2024-07-13 18:50 ` [COFF] Re: machine code translation, as " John Levine
2024-07-13 19:27 ` Paul Winalski
2024-07-13 19:42 ` Dan Cross [this message]
2024-07-14 1:09 ` Aron Insinga
2024-07-14 1:46 ` Aron Insinga
2024-07-14 16:16 ` Paul Winalski
2024-07-12 16:54 ` [COFF] Re: [TUHS] Re: history of machine code translation,as " John R Levine
[not found] ` <CAEoi9W4tNyEUcHytGFOCQRGS8C+FMWcKU3Wa3YuxVsC+4-24vw@mail.gmail.com>
[not found] ` <a85b24bb-b024-b5fe-1fc8-a8e18f732a8d@taugh.com>
2024-07-13 19:51 ` Dan Cross
2024-07-13 11:09 [COFF] " Douglas McIlroy
2024-07-13 17:36 ` Paul Winalski
2024-07-13 21:05 ` Aron Insinga
2024-07-14 15:55 ` Paul Winalski
2024-07-14 17:29 ` G. Branden Robinson
2024-07-13 22:00 Douglas McIlroy
2024-07-13 23:46 ` John Levine
2024-07-14 0:54 ` Dan Cross
2024-07-14 1:04 ` Aron Insinga
2024-07-14 0:56 ` Aron Insinga
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=CAEoi9W72ssW-Qr2g1qFTi9jrNOW__UHFHU6BwbiLYXbVQ6BMKA@mail.gmail.com \
--to=crossd@gmail.com \
--cc=coff@tuhs.org \
--cc=johnl@taugh.com \
/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).