Rocksolid Light

Welcome to Rocksolid Light

mail  files  register  newsreader  groups  login

Message-ID:  

You might have mail.


devel / comp.arch / The synergy of type tags on register file registers

SubjectAuthor
* The synergy of type tags on register file registersJimBrakefield
+* Re: The synergy of type tags on register file registersTerje Mathisen
|`- Re: The synergy of type tags on register file registersrobf...@gmail.com
`* Re: The synergy of type tags on register file registersluke.l...@gmail.com
 +* Re: The synergy of type tags on register file registersluke.l...@gmail.com
 |`- Re: The synergy of type tags on register file registersScott Lurndal
 +* Re: The synergy of type tags on register file registersNiklas Holsti
 |`- Re: The synergy of type tags on register file registersluke.l...@gmail.com
 `* Re: The synergy of type tags on register file registersMitchAlsup
  +* Re: The synergy of type tags on register file registersJimBrakefield
  |+- Re: The synergy of type tags on register file registersluke.l...@gmail.com
  |`* Re: The synergy of type tags on register file registersMitchAlsup
  | +* Re: The synergy of type tags on register file registersJimBrakefield
  | |+- Re: The synergy of type tags on register file registersMitchAlsup
  | |+* Re: The synergy of type tags on register file registersluke.l...@gmail.com
  | ||+* Re: The synergy of type tags on register file registersMitchAlsup
  | |||`* Re: The synergy of type tags on register file registersThomas Koenig
  | ||| +* Re: The synergy of type tags on register file registersluke.l...@gmail.com
  | ||| |`- Re: The synergy of type tags on register file registersMitchAlsup
  | ||| +* Re: The synergy of type tags on register file registersBGB
  | ||| |`* Re: The synergy of type tags on register file registersMitchAlsup
  | ||| | `- Re: The synergy of type tags on register file registersBGB
  | ||| `* Re: The synergy of type tags on register file registersTerje Mathisen
  | |||  +* Re: The synergy of type tags on register file registersMitchAlsup
  | |||  |`- Re: The synergy of type tags on register file registersTerje Mathisen
  | |||  `* Re: The synergy of type tags on register file registersThomas Koenig
  | |||   `* Re: The synergy of type tags on register file registersTerje Mathisen
  | |||    `* Re: The synergy of type tags on register file registersluke.l...@gmail.com
  | |||     +* Re: The synergy of type tags on register file registersScott Lurndal
  | |||     |`* Re: The synergy of type tags on register file registersluke.l...@gmail.com
  | |||     | `- Re: The synergy of type tags on register file registersMitchAlsup
  | |||     +* Re: The synergy of type tags on register file registersThomas Koenig
  | |||     |`- Re: The synergy of type tags on register file registersBGB
  | |||     +* Re: The synergy of type tags on register file registersTerje Mathisen
  | |||     |`* Re: The synergy of type tags on register file registersMitchAlsup
  | |||     | +* Re: The synergy of type tags on register file registersTerje Mathisen
  | |||     | |+- Re: The synergy of type tags on register file registersMitchAlsup
  | |||     | |`* Re: The synergy of type tags on register file registersluke.l...@gmail.com
  | |||     | | +- Re: The synergy of type tags on register file registersMitchAlsup
  | |||     | | `- Re: The synergy of type tags on register file registersJimBrakefield
  | |||     | `* Re: The synergy of type tags on register file registersScott Lurndal
  | |||     |  +- Re: The synergy of type tags on register file registersluke.l...@gmail.com
  | |||     |  +* Re: The synergy of type tags on register file registersBGB
  | |||     |  |`* Re: The synergy of type tags on register file registersAnton Ertl
  | |||     |  | `* Re: The synergy of type tags on register file registersMitchAlsup
  | |||     |  |  `* Re: The synergy of type tags on register file registersBGB
  | |||     |  |   `* Re: The synergy of type tags on register file registersAnton Ertl
  | |||     |  |    +* Re: The synergy of type tags on register file registersBGB
  | |||     |  |    |`* Re: The synergy of type tags on register file registersMitchAlsup
  | |||     |  |    | `- Re: The synergy of type tags on register file registersBGB
  | |||     |  |    `* Re: The synergy of type tags on register file registersThomas Koenig
  | |||     |  |     `- Re: The synergy of type tags on register file registersTerje Mathisen
  | |||     |  `* Re: The synergy of type tags on register file registersAnton Ertl
  | |||     |   `- Re: The synergy of type tags on register file registersMichael S
  | |||     +- Re: The synergy of type tags on register file registersBGB
  | |||     `* Re: The synergy of type tags on register file registersMitchAlsup
  | |||      +- Re: The synergy of type tags on register file registersluke.l...@gmail.com
  | |||      `* Re: The synergy of type tags on register file registersStephen Fuld
  | |||       +* Re: The synergy of type tags on register file registersMitchAlsup
  | |||       |`- Re: The synergy of type tags on register file registersStephen Fuld
  | |||       `* Re: The synergy of type tags on register file registersAnton Ertl
  | |||        +* Re: The synergy of type tags on register file registersStephen Fuld
  | |||        |+* Re: The synergy of type tags on register file registersMitchAlsup
  | |||        ||+- Re: The synergy of type tags on register file registersScott Lurndal
  | |||        ||`* Re: The synergy of type tags on register file registersStephen Fuld
  | |||        || +- Re: The synergy of type tags on register file registersThomas Koenig
  | |||        || `* Re: The synergy of type tags on register file registersJohn Dallman
  | |||        ||  `* Re: The synergy of type tags on register file registersThomas Koenig
  | |||        ||   +* Re: The synergy of type tags on register file registersJohn Dallman
  | |||        ||   |`- Re: The synergy of type tags on register file registersThomas Koenig
  | |||        ||   `* Re: The synergy of type tags on register file registersTerje Mathisen
  | |||        ||    `* Re: The synergy of type tags on register file registersMitchAlsup
  | |||        ||     `- Re: The synergy of type tags on register file registersTerje Mathisen
  | |||        |`* Re: The synergy of type tags on register file registersAnton Ertl
  | |||        | +* Re: The synergy of type tags on register file registersStephen Fuld
  | |||        | |+* Re: The synergy of type tags on register file registersBGB
  | |||        | ||`* Re: The synergy of type tags on register file registersrobf...@gmail.com
  | |||        | || +* Re: The synergy of type tags on register file registersMitchAlsup
  | |||        | || |`* Re: The synergy of type tags on register file registersMichael S
  | |||        | || | `* Re: The synergy of type tags on register file registersMitchAlsup
  | |||        | || |  `* Re: The synergy of type tags on register file registersMichael S
  | |||        | || |   `- Re: The synergy of type tags on register file registersMitchAlsup
  | |||        | || +* Re: The synergy of type tags on register file registersBGB
  | |||        | || |`- Re: The synergy of type tags on register file registersMitchAlsup
  | |||        | || `* Re: The synergy of type tags on register file registersScott Lurndal
  | |||        | ||  +- Re: The synergy of type tags on register file registersBGB
  | |||        | ||  `* Re: The synergy of type tags on register file registersMitchAlsup
  | |||        | ||   +- Re: The synergy of type tags on register file registersBGB
  | |||        | ||   +* Re: The synergy of type tags on register file registersluke.l...@gmail.com
  | |||        | ||   |`* Re: The synergy of type tags on register file registersScott Lurndal
  | |||        | ||   | `* Re: The synergy of type tags on register file registersBGB
  | |||        | ||   |  `* Re: The synergy of type tags on register file registersScott Lurndal
  | |||        | ||   |   `* Re: The synergy of type tags on register file registersBGB
  | |||        | ||   |    `* Re: The synergy of type tags on register file registersScott Lurndal
  | |||        | ||   |     +* Re: The synergy of type tags on register file registersStephen Fuld
  | |||        | ||   |     |`- Re: The synergy of type tags on register file registersScott Lurndal
  | |||        | ||   |     +* Re: The synergy of type tags on register file registersMitchAlsup
  | |||        | ||   |     |`* Re: The synergy of type tags on register file registersScott Lurndal
  | |||        | ||   |     | `* Re: The synergy of type tags on register file registersMitchAlsup
  | |||        | ||   |     |  `- Re: The synergy of type tags on register file registersScott Lurndal
  | |||        | ||   |     `* Re: The synergy of type tags on register file registersBGB
  | |||        | ||   `- Re: The synergy of type tags on register file registersIvan Godard
  | |||        | |+* Re: The synergy of type tags on register file registersAnton Ertl
  | |||        | |`* Re: The synergy of type tags on register file registersTerje Mathisen
  | |||        | +* Re: The synergy of type tags on register file registersBill Findlay
  | |||        | `- Re: The synergy of type tags on register file registersTerje Mathisen
  | |||        `- Re: The synergy of type tags on register file registersMitchAlsup
  | ||`* Re: The synergy of type tags on register file registersScott Lurndal
  | |`- Re: The synergy of type tags on register file registersNiklas Holsti
  | `- Re: The synergy of type tags on register file registersScott Lurndal
  `* Re: The synergy of type tags on register file registersPaul A. Clayton

Pages:12345678910
The synergy of type tags on register file registers

<08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32292&group=comp.arch#32292

  copy link   Newsgroups: comp.arch
X-Received: by 2002:a05:6214:8cf:b0:623:8123:3fe9 with SMTP id da15-20020a05621408cf00b0062381233fe9mr187373qvb.1.1684464516359;
Thu, 18 May 2023 19:48:36 -0700 (PDT)
X-Received: by 2002:aca:d888:0:b0:393:fd2b:a7bb with SMTP id
p130-20020acad888000000b00393fd2ba7bbmr225491oig.5.1684464515926; Thu, 18 May
2023 19:48:35 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!panix!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer03.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.arch
Date: Thu, 18 May 2023 19:48:35 -0700 (PDT)
Injection-Info: google-groups.googlegroups.com; posting-host=136.50.14.162; posting-account=AoizIQoAAADa7kQDpB0DAj2jwddxXUgl
NNTP-Posting-Host: 136.50.14.162
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
Subject: The synergy of type tags on register file registers
From: jim.brakefield@ieee.org (JimBrakefield)
Injection-Date: Fri, 19 May 2023 02:48:36 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 2593
 by: JimBrakefield - Fri, 19 May 2023 02:48 UTC

Have a habit of running out of op-code space on new ISA designs.

So, added a type tag to each register. I want four types: unsigned, signed, float and Posit. That and four data sizes requires 16 distinct memory read instructions! But it ends there. Only four store instructions, one for each data size. Only one instance of ADD SUB MUL DIV ! E.g. the R or S register determines the type of operation, automatic conversions between types at the option of the implementation, either do the implied conversion, take an exception or do an unimplemented instruction trap.

If I decide to add more types, such as a saturation flag, that goes in the type tag and requires more load instructions. At which point I go to a longer load instruction with room for additional tag bits. No additional ADD SUB MUL DIV instructions needed! If one wants more than one data item per register (MMX etc) same situation.

The down side is saving and restoring registers. For 24 and 48-bit registers no problem: save into 32 or 64-bit memory. For 32 and 64-bit registers, ugh, on an FPGA just create a small amount of wider memory. Another option is to save the load type info as a load instruction with a very long immediate?

At this time a 24 and 32-bit RISC instructions with two and three operands respectively. Showing 25% remaining op-code space on a full set of op-codes. Probably will add 40 or 48-bit load instructions with lots of instruction modifiers and additional register fields.

Re: The synergy of type tags on register file registers

<u46tnb$io0r$1@dont-email.me>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32294&group=comp.arch#32294

  copy link   Newsgroups: comp.arch
Path: i2pn2.org!i2pn.org!eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: terje.mathisen@tmsw.no (Terje Mathisen)
Newsgroups: comp.arch
Subject: Re: The synergy of type tags on register file registers
Date: Fri, 19 May 2023 06:25:14 +0200
Organization: A noiseless patient Spider
Lines: 29
Message-ID: <u46tnb$io0r$1@dont-email.me>
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Fri, 19 May 2023 04:25:15 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="15f16c653bc03ad64ab8622bdd817890";
logging-data="614427"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1942sRTK+tpqEJmIFITWU/qj7b8+ug+yVVKrf5KugukkQ=="
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101
Firefox/91.0 SeaMonkey/2.53.16
Cancel-Lock: sha1:DsTKuqJXqsVX6KRCi4RrU2vieDE=
In-Reply-To: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
 by: Terje Mathisen - Fri, 19 May 2023 04:25 UTC

JimBrakefield wrote:
> Have a habit of running out of op-code space on new ISA designs.
>
> So, added a type tag to each register. I want four types: unsigned,
> signed, float and Posit. That and four data sizes requires 16
> distinct memory read instructions! But it ends there. Only four
> store instructions, one for each data size. Only one instance of ADD
> SUB MUL DIV ! E.g. the R or S register determines the type of
> operation, automatic conversions between types at the option of the
> implementation, either do the implied conversion, take an exception
> or do an unimplemented instruction trap.

Please take another look at how Mill is doing this exact thing!

Ivan (and a few others) have expounded on this here in c.arch for a
number of years now.

Yes, the idea is one of those that seem obvious in hindsight. :-)

The Mill founders decided on a slightly different separation between the
load tags and the instructions needed, in particular you want separate
FP and INT opcodes just so that you can do Int/logical ops on FP bit
patterns.

Terje

--
- <Terje.Mathisen at tmsw.no>
"almost all programming can be viewed as an exercise in caching"

Re: The synergy of type tags on register file registers

<0245183c-ad49-47d8-8904-bc364c4118cfn@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32295&group=comp.arch#32295

  copy link   Newsgroups: comp.arch
X-Received: by 2002:a05:620a:4082:b0:75a:cbab:fe4e with SMTP id f2-20020a05620a408200b0075acbabfe4emr194509qko.0.1684479394550;
Thu, 18 May 2023 23:56:34 -0700 (PDT)
X-Received: by 2002:a05:6830:459:b0:6a1:704d:aa08 with SMTP id
d25-20020a056830045900b006a1704daa08mr319151otc.0.1684479394250; Thu, 18 May
2023 23:56:34 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer01.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.arch
Date: Thu, 18 May 2023 23:56:33 -0700 (PDT)
In-Reply-To: <u46tnb$io0r$1@dont-email.me>
Injection-Info: google-groups.googlegroups.com; posting-host=2607:fea8:1dde:6a00:188c:8f84:3655:d270;
posting-account=QId4bgoAAABV4s50talpu-qMcPp519Eb
NNTP-Posting-Host: 2607:fea8:1dde:6a00:188c:8f84:3655:d270
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com> <u46tnb$io0r$1@dont-email.me>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <0245183c-ad49-47d8-8904-bc364c4118cfn@googlegroups.com>
Subject: Re: The synergy of type tags on register file registers
From: robfi680@gmail.com (robf...@gmail.com)
Injection-Date: Fri, 19 May 2023 06:56:34 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 3819
 by: robf...@gmail.com - Fri, 19 May 2023 06:56 UTC

On Friday, May 19, 2023 at 12:25:19 AM UTC-4, Terje Mathisen wrote:
> JimBrakefield wrote:
> > Have a habit of running out of op-code space on new ISA designs.
> >
> > So, added a type tag to each register. I want four types: unsigned,
> > signed, float and Posit. That and four data sizes requires 16
> > distinct memory read instructions! But it ends there. Only four
> > store instructions, one for each data size. Only one instance of ADD
> > SUB MUL DIV ! E.g. the R or S register determines the type of
> > operation, automatic conversions between types at the option of the
> > implementation, either do the implied conversion, take an exception
> > or do an unimplemented instruction trap.
> Please take another look at how Mill is doing this exact thing!
>
> Ivan (and a few others) have expounded on this here in c.arch for a
> number of years now.
>
> Yes, the idea is one of those that seem obvious in hindsight. :-)
>
> The Mill founders decided on a slightly different separation between the
> load tags and the instructions needed, in particular you want separate
> FP and INT opcodes just so that you can do Int/logical ops on FP bit
> patterns.
>
> Terje
>
> --
> - <Terje.Mathisen at tmsw.no>
> "almost all programming can be viewed as an exercise in caching"

Been thinking about adding a tag to the register file myself to track operand
types. Thor2024 has separate float and integer files, but the float file may
contain float, decimal-float or posits. The compiler may know what type of
data is in the register, so this may be of limited use.

For Thor four different sets of instructions are used for signed, unsigned,
float and posit. It takes a lot of opcodes, but so what? Seven bits at the
root level. This allows the decoder to decide rather than having to read a
register first. Instructions could be queued before the register file is read
or valid. Immediate constants are interpreted differently by the decoder
depending on the operand type. Decode would have to wait for a register
file read if it went by the type stored with a register.

The compare-branch instruction has a two-bit field for the compare type
which is signed, unsigned, float, and posit.

Float loads and stores in Thor2024 have opcodes separate from integer
loads and stores as do posits as well. The float loads and stores convert
data to or from different data widths for storage to a fixed size for
processing.

Re: The synergy of type tags on register file registers

<c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32307&group=comp.arch#32307

  copy link   Newsgroups: comp.arch
X-Received: by 2002:ac8:5951:0:b0:3f6:ac62:8347 with SMTP id 17-20020ac85951000000b003f6ac628347mr1320809qtz.7.1684752276259;
Mon, 22 May 2023 03:44:36 -0700 (PDT)
X-Received: by 2002:a05:6870:5ab2:b0:196:22f7:23ad with SMTP id
dt50-20020a0568705ab200b0019622f723admr3015688oab.11.1684752276001; Mon, 22
May 2023 03:44:36 -0700 (PDT)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer01.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.arch
Date: Mon, 22 May 2023 03:44:35 -0700 (PDT)
In-Reply-To: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=92.19.80.230; posting-account=soFpvwoAAADIBXOYOBcm_mixNPAaxW9p
NNTP-Posting-Host: 92.19.80.230
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com>
Subject: Re: The synergy of type tags on register file registers
From: luke.leighton@gmail.com (luke.l...@gmail.com)
Injection-Date: Mon, 22 May 2023 10:44:36 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 3777
 by: luke.l...@gmail.com - Mon, 22 May 2023 10:44 UTC

On Friday, May 19, 2023 at 3:48:37 AM UTC+1, JimBrakefield wrote:
> Have a habit of running out of op-code space on new ISA designs.
>
> So, added a type tag to each register. I want four types: unsigned,
> signed, float and Posit. That and four data sizes requires 16
> distinct memory read instructions! But it ends there. Only
> four store instructions, one for each data size.

ridiculous, isn't it? you'd think every RISC ISA would work that way.
you can also get away with a much shorter STORE instruction
because you simply take the tag's width.

as Terje mentions, the Mill has had this solved since its inception.
the tag is carried from LOAD thru ARITH right to STORE, and copied
across to any reg-to-reg intermediates for further STORE.
there are "NARROW" and "WIDEN" instructions which change the
tag-type, there *may* be some "fp<->int" conversions that also
change the tag-type but apart from that it's all there is.

so for example as hinted above if you really want a different
STORE width you perform a NARROW or WIDEN first. this you
will find greatly reduces Hazard complexity as it fire-breaks
the STORE Dependency Hazards (3-in 1-out) from the
1-in 1-out needed for N/W.

the problems come as you already suspected on context-switch
(including function calls). there you suddenly have not only
registers to save/restore but also their tags. 8-bit tags is
now 32 bytes of extra context, and with the tags being "bits"
your ISA had better have a damn good way to save/restore
individual bytes into tags.

if you go for a separate "tag regfile" you need not poison the
ISA by reducing the bit-width of GPR/FPRs to something mad
like 24-bit instead of 32-bit. this then solves the issue of
SRAM allocation in FPGAs, they're allocated separately.

one other nice thing to consider would be a "this register is in use"
tag-bit. if set to zero the contents of the register may be
assumed to be zero (or *actually* set to zero) and thus those bits
may be used as a Predicate Mask for Vector LOAD/STORE,
performing automatic VCOMPRESS and VEXPAND.

the bit would be automatically set the moment the register
is used as a destination. if used as a source and the bit
is not set, an Illegal Instruction Trap can be raised, which
would prevent the scenario where someone leaked data
from a different security context.

last time i heard about tags was an obscure Texas Instruments
DSP from the 90s. beyond that for some bizarre unfathomable
reason the idea went completely out of fashion.

l.

Re: The synergy of type tags on register file registers

<875deb94-457d-44c1-a2fc-f5f861bbb896n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32308&group=comp.arch#32308

  copy link   Newsgroups: comp.arch
X-Received: by 2002:a05:620a:469e:b0:74e:a66:30f5 with SMTP id bq30-20020a05620a469e00b0074e0a6630f5mr2820441qkb.5.1684754153935;
Mon, 22 May 2023 04:15:53 -0700 (PDT)
X-Received: by 2002:a05:6870:93d5:b0:196:743:3e57 with SMTP id
c21-20020a05687093d500b0019607433e57mr2944730oal.9.1684754153640; Mon, 22 May
2023 04:15:53 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!newsfeed.hasname.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer01.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.arch
Date: Mon, 22 May 2023 04:15:53 -0700 (PDT)
In-Reply-To: <c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=92.19.80.230; posting-account=soFpvwoAAADIBXOYOBcm_mixNPAaxW9p
NNTP-Posting-Host: 92.19.80.230
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com> <c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <875deb94-457d-44c1-a2fc-f5f861bbb896n@googlegroups.com>
Subject: Re: The synergy of type tags on register file registers
From: luke.leighton@gmail.com (luke.l...@gmail.com)
Injection-Date: Mon, 22 May 2023 11:15:53 +0000
Content-Type: text/plain; charset="UTF-8"
X-Received-Bytes: 1605
 by: luke.l...@gmail.com - Mon, 22 May 2023 11:15 UTC

https://science.lpnu.ua/sites/default/files/journal-paper/2019/jul/17084/volum3number1text-9-16_1.pdf

Burroughs, Elbrus, the historical conclusion was
(bear in mind: no L1/L2 Caches), memory is so
damn expensive it is insane to have tags.

primary focus of that paper seems to be to take
tagged registers as a "given" and to then see if
Parallelism may be achieved on top of that.

l.

Re: The synergy of type tags on register file registers

<kd141hF29uuU1@mid.individual.net>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32309&group=comp.arch#32309

  copy link   Newsgroups: comp.arch
Path: i2pn2.org!i2pn.org!news.swapon.de!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail
From: niklas.holsti@tidorum.invalid (Niklas Holsti)
Newsgroups: comp.arch
Subject: Re: The synergy of type tags on register file registers
Date: Mon, 22 May 2023 15:04:01 +0300
Organization: Tidorum Ltd
Lines: 34
Message-ID: <kd141hF29uuU1@mid.individual.net>
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
<c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
X-Trace: individual.net qRjN6QZKUOUop/pLVzlESA/Ycs3eE7/zg34uEJXwhskmz+4/hS
Cancel-Lock: sha1:RSKrBZLQmfK6s6OavcLbVWznn3s=
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:102.0)
Gecko/20100101 Thunderbird/102.6.1
Content-Language: en-US
In-Reply-To: <c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com>
 by: Niklas Holsti - Mon, 22 May 2023 12:04 UTC

On 2023-05-22 13:44, luke.l...@gmail.com wrote:
> On Friday, May 19, 2023 at 3:48:37 AM UTC+1, JimBrakefield wrote:
>> Have a habit of running out of op-code space on new ISA designs.
>>
>> So, added a type tag to each register. I want four types: unsigned,
>> signed, float and Posit. That and four data sizes requires 16
>> distinct memory read instructions! But it ends there. Only
>> four store instructions, one for each data size.
>
> ridiculous, isn't it? you'd think every RISC ISA would work that way.
> you can also get away with a much shorter STORE instruction
> because you simply take the tag's width.
>
> as Terje mentions, the Mill has had this solved since its inception.
> the tag is carried from LOAD thru ARITH right to STORE, and copied
> across to any reg-to-reg intermediates for further STORE.
> there are "NARROW" and "WIDEN" instructions which change the
> tag-type, there *may* be some "fp<->int" conversions that also
> change the tag-type but apart from that it's all there is.

The Mill tags ("operand metadata" in Mill terms) do not indicate the
semantic type of the operand value, only its width in bits and whether
it is a single (scalar) value or a vector (SIMD). The tags also flag
various error conditions such as values that are not available for some
reason. The operations that convert integer values to floating-point
values or vice versa do not change the tag (unless the operand width
changes).

The Mill has separate instructions (opcodes) for integer (signed or
unsigned) and floating point (binary or decimal) operations. Thanks to
the tags, the same instructions/opcodes apply uniformly to operands of
all sizes and to scalars and vectors.

Re: The synergy of type tags on register file registers

<1lKaM.3236011$iU59.2407004@fx14.iad>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32310&group=comp.arch#32310

  copy link   Newsgroups: comp.arch
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!newsfeed.hasname.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer02.iad!feed-me.highwinds-media.com!news.highwinds-media.com!fx14.iad.POSTED!not-for-mail
X-newsreader: xrn 9.03-beta-14-64bit
Sender: scott@dragon.sl.home (Scott Lurndal)
From: scott@slp53.sl.home (Scott Lurndal)
Reply-To: slp53@pacbell.net
Subject: Re: The synergy of type tags on register file registers
Newsgroups: comp.arch
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com> <c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com> <875deb94-457d-44c1-a2fc-f5f861bbb896n@googlegroups.com>
Lines: 37
Message-ID: <1lKaM.3236011$iU59.2407004@fx14.iad>
X-Complaints-To: abuse@usenetserver.com
NNTP-Posting-Date: Mon, 22 May 2023 13:44:29 UTC
Organization: UsenetServer - www.usenetserver.com
Date: Mon, 22 May 2023 13:44:29 GMT
X-Received-Bytes: 2273
 by: Scott Lurndal - Mon, 22 May 2023 13:44 UTC

"luke.l...@gmail.com" <luke.leighton@gmail.com> writes:
>https://science.lpnu.ua/sites/default/files/journal-paper/2019/jul/17084/volum3number1text-9-16_1.pdf
>
>Burroughs, Elbrus, the historical conclusion was
>(bear in mind: no L1/L2 Caches), memory is so
>damn expensive it is insane to have tags.

The burroughs large systems still use tags (albeit emulated
on Intel CPUs) to define data types.

The burroughs medium systems had a slightly different mechanism
to indicate data type independent of the instruction; rather the
address syllables (instruction operands) encoded the data type
in the most significant digit as one of four possibilities:
0b00 - Unsigned Numeric
0b01 - Signed Numeric
0b10 - Unsigned Alphanumeric
0b11 - Indirect (i.e. the syllable was a pointer to an address syllable,
which could, in turn have a data type of 0b11, und so weiter).

The other two bits of the MSD encoded an optional index register
to apply to the address calculation.

Which allowed mixed operand types on an instruction:

ADD 0505 Operand1(UN), Operand2(SN), Operand3(UA)

which would add the unsigned first operand to the second
and store the sign in the zone digit of the most significant
byte of the alpha (numeric + the EBCDIC/ASCII zone digit @F@/@3@).

ARMv9 has the MTE (Memory Tagging Extension) which defines a
separate bank of memory for the tag bits (to leverage existing
DIMM widths). This is more designed around security than reducing
the instruction set.

Re: The synergy of type tags on register file registers

<8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32311&group=comp.arch#32311

  copy link   Newsgroups: comp.arch
X-Received: by 2002:a05:6214:a69:b0:625:73eb:3a6e with SMTP id ef9-20020a0562140a6900b0062573eb3a6emr1043306qvb.1.1684777940021;
Mon, 22 May 2023 10:52:20 -0700 (PDT)
X-Received: by 2002:a9d:7ad9:0:b0:6af:7f59:45c3 with SMTP id
m25-20020a9d7ad9000000b006af7f5945c3mr987722otn.7.1684777939743; Mon, 22 May
2023 10:52:19 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!newsfeed.hasname.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer01.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.arch
Date: Mon, 22 May 2023 10:52:19 -0700 (PDT)
In-Reply-To: <c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=2600:1700:291:29f0:45f5:4ec5:64f8:1d2b;
posting-account=H_G_JQkAAADS6onOMb-dqvUozKse7mcM
NNTP-Posting-Host: 2600:1700:291:29f0:45f5:4ec5:64f8:1d2b
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com> <c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com>
Subject: Re: The synergy of type tags on register file registers
From: MitchAlsup@aol.com (MitchAlsup)
Injection-Date: Mon, 22 May 2023 17:52:20 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 4898
 by: MitchAlsup - Mon, 22 May 2023 17:52 UTC

On Monday, May 22, 2023 at 5:44:37 AM UTC-5, luke.l...@gmail.com wrote:
> On Friday, May 19, 2023 at 3:48:37 AM UTC+1, JimBrakefield wrote:
> > Have a habit of running out of op-code space on new ISA designs.
> >
> > So, added a type tag to each register. I want four types: unsigned,
> > signed, float and Posit. That and four data sizes requires 16
> > distinct memory read instructions! But it ends there. Only
> > four store instructions, one for each data size.
<
> ridiculous, isn't it? you'd think every RISC ISA would work that way.
<
What to leave in, what to leave out........
<
> you can also get away with a much shorter STORE instruction
> because you simply take the tag's width.
>
> as Terje mentions, the Mill has had this solved since its inception.
> the tag is carried from LOAD thru ARITH right to STORE, and copied
> across to any reg-to-reg intermediates for further STORE.
> there are "NARROW" and "WIDEN" instructions which change the
> tag-type, there *may* be some "fp<->int" conversions that also
> change the tag-type but apart from that it's all there is.
>
> so for example as hinted above if you really want a different
> STORE width you perform a NARROW or WIDEN first. this you
> will find greatly reduces Hazard complexity as it fire-breaks
> the STORE Dependency Hazards (3-in 1-out) from the
> 1-in 1-out needed for N/W.
>
> the problems come as you already suspected on context-switch
> (including function calls). there you suddenly have not only
> registers to save/restore but also their tags. 8-bit tags is
> now 32 bytes of extra context, and with the tags being "bits"
> your ISA had better have a damn good way to save/restore
> individual bytes into tags.
<
It is not just the context, but now you are faced with needing even
more memory reference instructions just to save and restore the
registers and associated tags--when you don't know what value
in in the tags !!??!!
>
> if you go for a separate "tag regfile" you need not poison the
> ISA by reducing the bit-width of GPR/FPRs to something mad
> like 24-bit instead of 32-bit. this then solves the issue of
> SRAM allocation in FPGAs, they're allocated separately.
>
> one other nice thing to consider would be a "this register is in use"
> tag-bit. if set to zero the contents of the register may be
> assumed to be zero (or *actually* set to zero) and thus those bits
> may be used as a Predicate Mask for Vector LOAD/STORE,
> performing automatic VCOMPRESS and VEXPAND.
<
With an 8-bit tag, you could simply define rules and just have
generic arithmetic that simply works::
<
i = f×d-f×l+u
<
Which would produce 1 multiply, and 1 mac without any conversions.
>
> the bit would be automatically set the moment the register
> is used as a destination. if used as a source and the bit
> is not set, an Illegal Instruction Trap can be raised, which
> would prevent the scenario where someone leaked data
> from a different security context.
<
When storing preserved (callee) registers you could set the tag
to empty, allowing it to be used as zero, but not allowing this
subroutine to see the value in the register it does not have
ownership of.
>
> last time i heard about tags was an obscure Texas Instruments
> DSP from the 90s. beyond that for some bizarre unfathomable
> reason the idea went completely out of fashion.
>
> l.

Re: The synergy of type tags on register file registers

<dc1b101c-22fb-42b8-a7c3-4728920d4907n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32312&group=comp.arch#32312

  copy link   Newsgroups: comp.arch
X-Received: by 2002:ad4:5a44:0:b0:625:7698:3b12 with SMTP id ej4-20020ad45a44000000b0062576983b12mr1076145qvb.3.1684786108585;
Mon, 22 May 2023 13:08:28 -0700 (PDT)
X-Received: by 2002:aca:6104:0:b0:396:1e7e:e6e0 with SMTP id
v4-20020aca6104000000b003961e7ee6e0mr2225279oib.9.1684786108298; Mon, 22 May
2023 13:08:28 -0700 (PDT)
Path: i2pn2.org!i2pn.org!news.1d4.us!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer01.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.arch
Date: Mon, 22 May 2023 13:08:27 -0700 (PDT)
In-Reply-To: <kd141hF29uuU1@mid.individual.net>
Injection-Info: google-groups.googlegroups.com; posting-host=92.19.80.230; posting-account=soFpvwoAAADIBXOYOBcm_mixNPAaxW9p
NNTP-Posting-Host: 92.19.80.230
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
<c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com> <kd141hF29uuU1@mid.individual.net>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <dc1b101c-22fb-42b8-a7c3-4728920d4907n@googlegroups.com>
Subject: Re: The synergy of type tags on register file registers
From: luke.leighton@gmail.com (luke.l...@gmail.com)
Injection-Date: Mon, 22 May 2023 20:08:28 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 2813
 by: luke.l...@gmail.com - Mon, 22 May 2023 20:08 UTC

On Monday, May 22, 2023 at 1:04:05 PM UTC+1, Niklas Holsti wrote:

> The Mill tags ("operand metadata" in Mill terms) do not indicate the
> semantic type of the operand value, only its width in bits and whether
> it is a single (scalar) value or a vector (SIMD). The tags also flag
> various error conditions such as values that are not available for some
> reason.

ahh, thank you for correcting my memory-recall which is somewhat
akin to holographic storage.

On Monday, May 22, 2023 at 6:52:21 PM UTC+1, MitchAlsup wrote:

> It is not just the context, but now you are faced with needing even
> more memory reference instructions just to save and restore the
> registers and associated tags--when you don't know what value
> in in the tags !!??!!

which would tend to suggest that swapping at least one tag
of one register into context-aware state, and replacing it with
known-good state (uint/64-bit would do) would seem to be
a good idea. that one register is then in a fit state to be used
to perform bare-minimum operations such as save/restore
of other reg-tags.

in Power ISA, the two context-swapping SPRs are SRR0 and
SRR1. normally SRR0 contains the Program Counter and
SRR1 contains the MSR (Machine Status Register), so an
entire 8-bits of SRR1 have to be taken up to store the tag
of *one* general-purpose register, which is a hell of a lot.

therefore those 8-bits would have to be in MSR itself (then
copied to SRR1), which is also a hell of a lot.

l.

Re: The synergy of type tags on register file registers

<e141ae62-68a2-43fd-ac04-9213e2dfa0b5n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32313&group=comp.arch#32313

  copy link   Newsgroups: comp.arch
X-Received: by 2002:ac8:5e4e:0:b0:3f6:b017:627e with SMTP id i14-20020ac85e4e000000b003f6b017627emr1786108qtx.12.1684794766633;
Mon, 22 May 2023 15:32:46 -0700 (PDT)
X-Received: by 2002:a05:6820:514:b0:54f:6f75:473 with SMTP id
m20-20020a056820051400b0054f6f750473mr5033873ooj.0.1684794766317; Mon, 22 May
2023 15:32:46 -0700 (PDT)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer01.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.arch
Date: Mon, 22 May 2023 15:32:46 -0700 (PDT)
In-Reply-To: <8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=136.50.14.162; posting-account=AoizIQoAAADa7kQDpB0DAj2jwddxXUgl
NNTP-Posting-Host: 136.50.14.162
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
<c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com> <8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <e141ae62-68a2-43fd-ac04-9213e2dfa0b5n@googlegroups.com>
Subject: Re: The synergy of type tags on register file registers
From: jim.brakefield@ieee.org (JimBrakefield)
Injection-Date: Mon, 22 May 2023 22:32:46 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 5884
 by: JimBrakefield - Mon, 22 May 2023 22:32 UTC

On Monday, May 22, 2023 at 12:52:21 PM UTC-5, MitchAlsup wrote:
> On Monday, May 22, 2023 at 5:44:37 AM UTC-5, luke.l...@gmail.com wrote:
> > On Friday, May 19, 2023 at 3:48:37 AM UTC+1, JimBrakefield wrote:
> > > Have a habit of running out of op-code space on new ISA designs.
> > >
> > > So, added a type tag to each register. I want four types: unsigned,
> > > signed, float and Posit. That and four data sizes requires 16
> > > distinct memory read instructions! But it ends there. Only
> > > four store instructions, one for each data size.
> <
> > ridiculous, isn't it? you'd think every RISC ISA would work that way.
> <
> What to leave in, what to leave out........
> <
> > you can also get away with a much shorter STORE instruction
> > because you simply take the tag's width.
> >
> > as Terje mentions, the Mill has had this solved since its inception.
> > the tag is carried from LOAD thru ARITH right to STORE, and copied
> > across to any reg-to-reg intermediates for further STORE.
> > there are "NARROW" and "WIDEN" instructions which change the
> > tag-type, there *may* be some "fp<->int" conversions that also
> > change the tag-type but apart from that it's all there is.
> >
> > so for example as hinted above if you really want a different
> > STORE width you perform a NARROW or WIDEN first. this you
> > will find greatly reduces Hazard complexity as it fire-breaks
> > the STORE Dependency Hazards (3-in 1-out) from the
> > 1-in 1-out needed for N/W.
> >
> > the problems come as you already suspected on context-switch
> > (including function calls). there you suddenly have not only
> > registers to save/restore but also their tags. 8-bit tags is
> > now 32 bytes of extra context, and with the tags being "bits"
> > your ISA had better have a damn good way to save/restore
> > individual bytes into tags.
> <
> It is not just the context, but now you are faced with needing even
> more memory reference instructions just to save and restore the
> registers and associated tags--when you don't know what value
> in in the tags !!??!!
> >
> > if you go for a separate "tag regfile" you need not poison the
> > ISA by reducing the bit-width of GPR/FPRs to something mad
> > like 24-bit instead of 32-bit. this then solves the issue of
> > SRAM allocation in FPGAs, they're allocated separately.
> >
> > one other nice thing to consider would be a "this register is in use"
> > tag-bit. if set to zero the contents of the register may be
> > assumed to be zero (or *actually* set to zero) and thus those bits
> > may be used as a Predicate Mask for Vector LOAD/STORE,
> > performing automatic VCOMPRESS and VEXPAND.
> <
> With an 8-bit tag, you could simply define rules and just have
> generic arithmetic that simply works::
> <
> i = f×d-f×l+u
> <
> Which would produce 1 multiply, and 1 mac without any conversions.
> >
> > the bit would be automatically set the moment the register
> > is used as a destination. if used as a source and the bit
> > is not set, an Illegal Instruction Trap can be raised, which
> > would prevent the scenario where someone leaked data
> > from a different security context.
> <
> When storing preserved (callee) registers you could set the tag
> to empty, allowing it to be used as zero, but not allowing this
> subroutine to see the value in the register it does not have
> ownership of.
> >
> > last time i heard about tags was an obscure Texas Instruments
> > DSP from the 90s. beyond that for some bizarre unfathomable
> > reason the idea went completely out of fashion.
> >
> > l.
|>
|>It is not just the context, but now you are faced with needing even
|>more memory reference instructions just to save and restore the
|>registers and associated tags--when you don't know what value
|>in in the tags !!??!!

Many/most RISC ISAs have bulk/multiple register save/restore instructions.
It is these instructions that would need to preserve register tags.
Will not claim to know how to do it for 32 & 64 bit registers?
Perhaps these instructions need to be privileged so as to prohibit tag modifications.
(particularly if "address" is a type tag?)
Unexpected type coercion traps would provide an additional protection against
mischievous actions between save and restore?

Re: The synergy of type tags on register file registers

<bb8cda86-1025-4b10-86d3-f3cf5767be47n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32314&group=comp.arch#32314

  copy link   Newsgroups: comp.arch
X-Received: by 2002:a05:6214:15d2:b0:5ef:4436:ef38 with SMTP id p18-20020a05621415d200b005ef4436ef38mr2442201qvz.4.1684796240729;
Mon, 22 May 2023 15:57:20 -0700 (PDT)
X-Received: by 2002:aca:db04:0:b0:394:66db:3374 with SMTP id
s4-20020acadb04000000b0039466db3374mr3297283oig.10.1684796240467; Mon, 22 May
2023 15:57:20 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!nntp.club.cc.cmu.edu!45.76.7.193.MISMATCH!3.us.feeder.erje.net!feeder.erje.net!border-1.nntp.ord.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.arch
Date: Mon, 22 May 2023 15:57:20 -0700 (PDT)
In-Reply-To: <e141ae62-68a2-43fd-ac04-9213e2dfa0b5n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=92.19.80.230; posting-account=soFpvwoAAADIBXOYOBcm_mixNPAaxW9p
NNTP-Posting-Host: 92.19.80.230
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
<c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com> <8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com>
<e141ae62-68a2-43fd-ac04-9213e2dfa0b5n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <bb8cda86-1025-4b10-86d3-f3cf5767be47n@googlegroups.com>
Subject: Re: The synergy of type tags on register file registers
From: luke.leighton@gmail.com (luke.l...@gmail.com)
Injection-Date: Mon, 22 May 2023 22:57:20 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Lines: 19
 by: luke.l...@gmail.com - Mon, 22 May 2023 22:57 UTC

On Monday, May 22, 2023 at 11:32:48 PM UTC+1, JimBrakefield wrote:

> Many/most RISC ISAs have bulk/multiple register save/restore instructions..

hardware architects attempting to implement high-speed designs
tend to hate them. ARM retired the bulk/multiple save/restore
instructions in favour of a "save two at a time" instruction which
is way easier on Hazard Management and fits better with OoO
Micro-Architectures.

> It is these instructions that would need to preserve register tags.
> Will not claim to know how to do it for 32 & 64 bit registers?
> Perhaps these instructions need to be privileged so as to prohibit tag modifications.

no, just the "valid and in-use" bit. or, better: if userspace sets
it, the contents of the register are zero'd at the same time.

l.

Re: The synergy of type tags on register file registers

<d79ddd12-533d-4369-b6db-e14adefcacb8n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32315&group=comp.arch#32315

  copy link   Newsgroups: comp.arch
X-Received: by 2002:a05:620a:454e:b0:759:5252:c053 with SMTP id u14-20020a05620a454e00b007595252c053mr4185322qkp.1.1684804928223;
Mon, 22 May 2023 18:22:08 -0700 (PDT)
X-Received: by 2002:a05:6871:a181:b0:19a:e93:86e4 with SMTP id
vt1-20020a056871a18100b0019a0e9386e4mr4358473oab.10.1684804927930; Mon, 22
May 2023 18:22:07 -0700 (PDT)
Path: i2pn2.org!i2pn.org!news.neodome.net!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer03.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.arch
Date: Mon, 22 May 2023 18:22:07 -0700 (PDT)
In-Reply-To: <e141ae62-68a2-43fd-ac04-9213e2dfa0b5n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=2600:1700:291:29f0:74f9:cf9e:4eed:b74d;
posting-account=H_G_JQkAAADS6onOMb-dqvUozKse7mcM
NNTP-Posting-Host: 2600:1700:291:29f0:74f9:cf9e:4eed:b74d
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
<c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com> <8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com>
<e141ae62-68a2-43fd-ac04-9213e2dfa0b5n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <d79ddd12-533d-4369-b6db-e14adefcacb8n@googlegroups.com>
Subject: Re: The synergy of type tags on register file registers
From: MitchAlsup@aol.com (MitchAlsup)
Injection-Date: Tue, 23 May 2023 01:22:08 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 6390
 by: MitchAlsup - Tue, 23 May 2023 01:22 UTC

On Monday, May 22, 2023 at 5:32:48 PM UTC-5, JimBrakefield wrote:
> On Monday, May 22, 2023 at 12:52:21 PM UTC-5, MitchAlsup wrote:
> > On Monday, May 22, 2023 at 5:44:37 AM UTC-5, luke.l...@gmail.com wrote:
> > > On Friday, May 19, 2023 at 3:48:37 AM UTC+1, JimBrakefield wrote:
> > > > Have a habit of running out of op-code space on new ISA designs.
> > > >
> > > > So, added a type tag to each register. I want four types: unsigned,
> > > > signed, float and Posit. That and four data sizes requires 16
> > > > distinct memory read instructions! But it ends there. Only
> > > > four store instructions, one for each data size.
> > <
> > > ridiculous, isn't it? you'd think every RISC ISA would work that way.
> > <
> > What to leave in, what to leave out........
> > <
> > > you can also get away with a much shorter STORE instruction
> > > because you simply take the tag's width.
> > >
> > > as Terje mentions, the Mill has had this solved since its inception.
> > > the tag is carried from LOAD thru ARITH right to STORE, and copied
> > > across to any reg-to-reg intermediates for further STORE.
> > > there are "NARROW" and "WIDEN" instructions which change the
> > > tag-type, there *may* be some "fp<->int" conversions that also
> > > change the tag-type but apart from that it's all there is.
> > >
> > > so for example as hinted above if you really want a different
> > > STORE width you perform a NARROW or WIDEN first. this you
> > > will find greatly reduces Hazard complexity as it fire-breaks
> > > the STORE Dependency Hazards (3-in 1-out) from the
> > > 1-in 1-out needed for N/W.
> > >
> > > the problems come as you already suspected on context-switch
> > > (including function calls). there you suddenly have not only
> > > registers to save/restore but also their tags. 8-bit tags is
> > > now 32 bytes of extra context, and with the tags being "bits"
> > > your ISA had better have a damn good way to save/restore
> > > individual bytes into tags.
> > <
> > It is not just the context, but now you are faced with needing even
> > more memory reference instructions just to save and restore the
> > registers and associated tags--when you don't know what value
> > in in the tags !!??!!
> > >
> > > if you go for a separate "tag regfile" you need not poison the
> > > ISA by reducing the bit-width of GPR/FPRs to something mad
> > > like 24-bit instead of 32-bit. this then solves the issue of
> > > SRAM allocation in FPGAs, they're allocated separately.
> > >
> > > one other nice thing to consider would be a "this register is in use"
> > > tag-bit. if set to zero the contents of the register may be
> > > assumed to be zero (or *actually* set to zero) and thus those bits
> > > may be used as a Predicate Mask for Vector LOAD/STORE,
> > > performing automatic VCOMPRESS and VEXPAND.
> > <
> > With an 8-bit tag, you could simply define rules and just have
> > generic arithmetic that simply works::
> > <
> > i = f×d-f×l+u
> > <
> > Which would produce 1 multiply, and 1 mac without any conversions.
> > >
> > > the bit would be automatically set the moment the register
> > > is used as a destination. if used as a source and the bit
> > > is not set, an Illegal Instruction Trap can be raised, which
> > > would prevent the scenario where someone leaked data
> > > from a different security context.
> > <
> > When storing preserved (callee) registers you could set the tag
> > to empty, allowing it to be used as zero, but not allowing this
> > subroutine to see the value in the register it does not have
> > ownership of.
> > >
> > > last time i heard about tags was an obscure Texas Instruments
> > > DSP from the 90s. beyond that for some bizarre unfathomable
> > > reason the idea went completely out of fashion.
> > >
> > > l.
> |>
> |>It is not just the context, but now you are faced with needing even
> |>more memory reference instructions just to save and restore the
> |>registers and associated tags--when you don't know what value
> |>in in the tags !!??!!
<
> Many/most RISC ISAs have bulk/multiple register save/restore instructions..
<
Where many/most does not include:: {MIPS, Mc 88K, SPARCV8 or V9, RISC-V}
<
> It is these instructions that would need to preserve register tags.
> Will not claim to know how to do it for 32 & 64 bit registers?
> Perhaps these instructions need to be privileged so as to prohibit tag modifications.
> (particularly if "address" is a type tag?)
> Unexpected type coercion traps would provide an additional protection against
> mischievous actions between save and restore?

Re: The synergy of type tags on register file registers

<4f54444c-673d-48c7-a9b9-383233b0b608n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32316&group=comp.arch#32316

  copy link   Newsgroups: comp.arch
X-Received: by 2002:a05:6214:14a3:b0:623:8cfa:b570 with SMTP id bo3-20020a05621414a300b006238cfab570mr2158749qvb.9.1684808082352;
Mon, 22 May 2023 19:14:42 -0700 (PDT)
X-Received: by 2002:aca:3308:0:b0:393:fbd7:79e8 with SMTP id
z8-20020aca3308000000b00393fbd779e8mr3443029oiz.1.1684808081961; Mon, 22 May
2023 19:14:41 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer03.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.arch
Date: Mon, 22 May 2023 19:14:41 -0700 (PDT)
In-Reply-To: <d79ddd12-533d-4369-b6db-e14adefcacb8n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=136.50.14.162; posting-account=AoizIQoAAADa7kQDpB0DAj2jwddxXUgl
NNTP-Posting-Host: 136.50.14.162
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
<c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com> <8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com>
<e141ae62-68a2-43fd-ac04-9213e2dfa0b5n@googlegroups.com> <d79ddd12-533d-4369-b6db-e14adefcacb8n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <4f54444c-673d-48c7-a9b9-383233b0b608n@googlegroups.com>
Subject: Re: The synergy of type tags on register file registers
From: jim.brakefield@ieee.org (JimBrakefield)
Injection-Date: Tue, 23 May 2023 02:14:42 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 7113
 by: JimBrakefield - Tue, 23 May 2023 02:14 UTC

On Monday, May 22, 2023 at 8:22:09 PM UTC-5, MitchAlsup wrote:
> On Monday, May 22, 2023 at 5:32:48 PM UTC-5, JimBrakefield wrote:
> > On Monday, May 22, 2023 at 12:52:21 PM UTC-5, MitchAlsup wrote:
> > > On Monday, May 22, 2023 at 5:44:37 AM UTC-5, luke.l...@gmail.com wrote:
> > > > On Friday, May 19, 2023 at 3:48:37 AM UTC+1, JimBrakefield wrote:
> > > > > Have a habit of running out of op-code space on new ISA designs.
> > > > >
> > > > > So, added a type tag to each register. I want four types: unsigned,
> > > > > signed, float and Posit. That and four data sizes requires 16
> > > > > distinct memory read instructions! But it ends there. Only
> > > > > four store instructions, one for each data size.
> > > <
> > > > ridiculous, isn't it? you'd think every RISC ISA would work that way.
> > > <
> > > What to leave in, what to leave out........
> > > <
> > > > you can also get away with a much shorter STORE instruction
> > > > because you simply take the tag's width.
> > > >
> > > > as Terje mentions, the Mill has had this solved since its inception..
> > > > the tag is carried from LOAD thru ARITH right to STORE, and copied
> > > > across to any reg-to-reg intermediates for further STORE.
> > > > there are "NARROW" and "WIDEN" instructions which change the
> > > > tag-type, there *may* be some "fp<->int" conversions that also
> > > > change the tag-type but apart from that it's all there is.
> > > >
> > > > so for example as hinted above if you really want a different
> > > > STORE width you perform a NARROW or WIDEN first. this you
> > > > will find greatly reduces Hazard complexity as it fire-breaks
> > > > the STORE Dependency Hazards (3-in 1-out) from the
> > > > 1-in 1-out needed for N/W.
> > > >
> > > > the problems come as you already suspected on context-switch
> > > > (including function calls). there you suddenly have not only
> > > > registers to save/restore but also their tags. 8-bit tags is
> > > > now 32 bytes of extra context, and with the tags being "bits"
> > > > your ISA had better have a damn good way to save/restore
> > > > individual bytes into tags.
> > > <
> > > It is not just the context, but now you are faced with needing even
> > > more memory reference instructions just to save and restore the
> > > registers and associated tags--when you don't know what value
> > > in in the tags !!??!!
> > > >
> > > > if you go for a separate "tag regfile" you need not poison the
> > > > ISA by reducing the bit-width of GPR/FPRs to something mad
> > > > like 24-bit instead of 32-bit. this then solves the issue of
> > > > SRAM allocation in FPGAs, they're allocated separately.
> > > >
> > > > one other nice thing to consider would be a "this register is in use"
> > > > tag-bit. if set to zero the contents of the register may be
> > > > assumed to be zero (or *actually* set to zero) and thus those bits
> > > > may be used as a Predicate Mask for Vector LOAD/STORE,
> > > > performing automatic VCOMPRESS and VEXPAND.
> > > <
> > > With an 8-bit tag, you could simply define rules and just have
> > > generic arithmetic that simply works::
> > > <
> > > i = f×d-f×l+u
> > > <
> > > Which would produce 1 multiply, and 1 mac without any conversions.
> > > >
> > > > the bit would be automatically set the moment the register
> > > > is used as a destination. if used as a source and the bit
> > > > is not set, an Illegal Instruction Trap can be raised, which
> > > > would prevent the scenario where someone leaked data
> > > > from a different security context.
> > > <
> > > When storing preserved (callee) registers you could set the tag
> > > to empty, allowing it to be used as zero, but not allowing this
> > > subroutine to see the value in the register it does not have
> > > ownership of.
> > > >
> > > > last time i heard about tags was an obscure Texas Instruments
> > > > DSP from the 90s. beyond that for some bizarre unfathomable
> > > > reason the idea went completely out of fashion.
> > > >
> > > > l.
> > |>
> > |>It is not just the context, but now you are faced with needing even
> > |>more memory reference instructions just to save and restore the
> > |>registers and associated tags--when you don't know what value
> > |>in in the tags !!??!!
> <
> > Many/most RISC ISAs have bulk/multiple register save/restore instructions.
> <
> Where many/most does not include:: {MIPS, Mc 88K, SPARCV8 or V9, RISC-V}
> <
> > It is these instructions that would need to preserve register tags.
> > Will not claim to know how to do it for 32 & 64 bit registers?
> > Perhaps these instructions need to be privileged so as to prohibit tag modifications.
> > (particularly if "address" is a type tag?)
> > Unexpected type coercion traps would provide an additional protection against
> > mischievous actions between save and restore?

|>> Where many/most does not include:: {MIPS, Mc 88K, SPARCV8 or V9, RISC-V}
Does include Power PC integer registers, M68000, AMD29000, SPARC call/return (eight registers implied), VAX (four registers at a time) and MY 66000?
Context switches (thread, process) not considered in the same class as load/store multiple?
Ugh, so off the hook on "many", definitely not "most", could say move multiple is common?

Re: The synergy of type tags on register file registers

<dCVaM.3249139$iU59.1404199@fx14.iad>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32317&group=comp.arch#32317

  copy link   Newsgroups: comp.arch
Path: i2pn2.org!i2pn.org!weretis.net!feeder8.news.weretis.net!feeder1.feed.usenet.farm!feed.usenet.farm!peer01.ams4!peer.am4.highwinds-media.com!peer01.iad!feed-me.highwinds-media.com!news.highwinds-media.com!fx14.iad.POSTED!not-for-mail
X-newsreader: xrn 9.03-beta-14-64bit
Sender: scott@dragon.sl.home (Scott Lurndal)
From: scott@slp53.sl.home (Scott Lurndal)
Reply-To: slp53@pacbell.net
Subject: Re: The synergy of type tags on register file registers
Newsgroups: comp.arch
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com> <c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com> <8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com> <e141ae62-68a2-43fd-ac04-9213e2dfa0b5n@googlegroups.com> <d79ddd12-533d-4369-b6db-e14adefcacb8n@googlegroups.com>
Lines: 20
Message-ID: <dCVaM.3249139$iU59.1404199@fx14.iad>
X-Complaints-To: abuse@usenetserver.com
NNTP-Posting-Date: Tue, 23 May 2023 02:33:45 UTC
Organization: UsenetServer - www.usenetserver.com
Date: Tue, 23 May 2023 02:33:45 GMT
X-Received-Bytes: 1808
 by: Scott Lurndal - Tue, 23 May 2023 02:33 UTC

MitchAlsup <MitchAlsup@aol.com> writes:
>On Monday, May 22, 2023 at 5:32:48=E2=80=AFPM UTC-5, JimBrakefield wrote:
>> On Monday, May 22, 2023 at 12:52:21=E2=80=AFPM UTC-5, MitchAlsup wrote:=

>> Many/most RISC ISAs have bulk/multiple register save/restore instructions=
>.=20
><
>Where many/most does not include:: {MIPS, Mc 88K, SPARCV8 or V9, RISC-V}
><

ARMv8 only supports load pair and store pair. And when system
bus widths allow, LDP/SDP will use single-copy atomic 128-bit bus transactions
when loading or storing a pair of registers.

A new feature FEAT_LS64 provides two new instructions issue single-copy
atomic loads and stores of 64 bytes. These use 8 consecutive 64-bit
general purpose registers.

I don't believe any extant cores implement this feature yet. It's designed
to pass data to on-board coprocessors (like a hardware network stack).

Re: The synergy of type tags on register file registers

<u4h95l$2ee3a$1@dont-email.me>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32318&group=comp.arch#32318

  copy link   Newsgroups: comp.arch
Path: i2pn2.org!i2pn.org!eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: paaronclayton@gmail.com (Paul A. Clayton)
Newsgroups: comp.arch
Subject: Re: The synergy of type tags on register file registers
Date: Mon, 22 May 2023 22:41:55 -0400
Organization: A noiseless patient Spider
Lines: 43
Message-ID: <u4h95l$2ee3a$1@dont-email.me>
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
<c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com>
<8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Date: Tue, 23 May 2023 02:41:57 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="cd12c2f7db736e830e1b1e8a121c30a4";
logging-data="2570346"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/rlKHSAc2WeAZV+XAFkeXBRddB4suaeps="
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101
Thunderbird/91.0
Cancel-Lock: sha1:ZemgFuIIrsWx/EXKQ+kqvBd5lWY=
In-Reply-To: <8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com>
 by: Paul A. Clayton - Tue, 23 May 2023 02:41 UTC

MitchAlsup wrote:
> On Monday, May 22, 2023 at 5:44:37 AM UTC-5, luke.l...@gmail.com wrote:
[snip]
>> the problems come as you already suspected on context-switch
>> (including function calls). there you suddenly have not only
>> registers to save/restore but also their tags. 8-bit tags is
>> now 32 bytes of extra context, and with the tags being "bits"
>> your ISA had better have a damn good way to save/restore
>> individual bytes into tags.
>
> It is not just the context, but now you are faced with needing even
> more memory reference instructions just to save and restore the
> registers and associated tags--when you don't know what value
> in in the tags !!??!!

This assumes that the save/restore is done by instructions. For
context switching, My 66000 does this without instructions but
would still require special support for function interfaces (only
for caller-save registers? though architecting the ABI for that
case may be ill-advised).

The Mill saves the entire valid Belt on function calls without
special instructions. (The Mill requires additional instructions
for widening [and narrowing] when a traditional RISC automatically
widens on a load and truncates [possibly unsafely] on a store.)

Something like Itanium's Register Stack Engine combined with
hardware context switching might also avoid adding spill/fill
instructions that preserve the metadata.

I could also imagine a load multiple instruction that used a
register to provide the metadata and the store multiple
instruction that accumulated the metadata into a register that is
then stored (with an ordinary store instruction as its type is
known). If the ISA has a zero register, including the zero
register in the store list might save the metadata in the zero
register's spot.

Something like My 66000's ENTER/EXIT could probably be extended to
save the metadata.

I suspect there are other ways of avoiding more instructions if
that is seen as sufficiently important.

Re: The synergy of type tags on register file registers

<5b9e8b73-9d80-46f1-9d2c-1e4c8f6ece69n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32319&group=comp.arch#32319

  copy link   Newsgroups: comp.arch
X-Received: by 2002:a05:620a:2586:b0:757:7357:ad7f with SMTP id x6-20020a05620a258600b007577357ad7fmr2725458qko.6.1684809991226;
Mon, 22 May 2023 19:46:31 -0700 (PDT)
X-Received: by 2002:a05:6830:2448:b0:6af:8cca:bfe3 with SMTP id
x8-20020a056830244800b006af8ccabfe3mr382015otr.0.1684809990893; Mon, 22 May
2023 19:46:30 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!news.misty.com!border-2.nntp.ord.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.arch
Date: Mon, 22 May 2023 19:46:30 -0700 (PDT)
In-Reply-To: <4f54444c-673d-48c7-a9b9-383233b0b608n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=2600:1700:291:29f0:74f9:cf9e:4eed:b74d;
posting-account=H_G_JQkAAADS6onOMb-dqvUozKse7mcM
NNTP-Posting-Host: 2600:1700:291:29f0:74f9:cf9e:4eed:b74d
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
<c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com> <8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com>
<e141ae62-68a2-43fd-ac04-9213e2dfa0b5n@googlegroups.com> <d79ddd12-533d-4369-b6db-e14adefcacb8n@googlegroups.com>
<4f54444c-673d-48c7-a9b9-383233b0b608n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <5b9e8b73-9d80-46f1-9d2c-1e4c8f6ece69n@googlegroups.com>
Subject: Re: The synergy of type tags on register file registers
From: MitchAlsup@aol.com (MitchAlsup)
Injection-Date: Tue, 23 May 2023 02:46:31 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Lines: 46
 by: MitchAlsup - Tue, 23 May 2023 02:46 UTC

On Monday, May 22, 2023 at 9:14:43 PM UTC-5, JimBrakefield wrote:
> On Monday, May 22, 2023 at 8:22:09 PM UTC-5, MitchAlsup wrote:
> > On Monday, May 22, 2023 at 5:32:48 PM UTC-5, JimBrakefield wrote:
> > > Many/most RISC ISAs have bulk/multiple register save/restore instructions.
> > <
> > Where many/most does not include:: {MIPS, Mc 88K, SPARCV8 or V9, RISC-V}
> > <
> > > It is these instructions that would need to preserve register tags.
> > > Will not claim to know how to do it for 32 & 64 bit registers?
> > > Perhaps these instructions need to be privileged so as to prohibit tag modifications.
> > > (particularly if "address" is a type tag?)
> > > Unexpected type coercion traps would provide an additional protection against
> > > mischievous actions between save and restore?
>
> |>> Where many/most does not include:: {MIPS, Mc 88K, SPARCV8 or V9, RISC-V}
> Does include Power PC integer registers, M68000, AMD29000, SPARC call/return (eight registers implied), VAX (four registers at a time) and MY 66000?
68K is not RISC,
SPARC call/ret did not HAVE to ST/LD registers,
My 66000 is arguable as to whether it is a RISC--granted it is near RISC--but is it really--
Well in the context of actually having a Reduced ISA, it is, in what is in that ISA; maybe not.
<
> Context switches (thread, process) not considered in the same class as load/store multiple?
<
No not really, you are manipulating not only register files, but thread and system queues,
manipulating control registers in 2 states, All at once.
<
LDM/STM are purely reg<->mem.
<
> Ugh, so off the hook on "many", definitely not "most", could say move multiple is common?
<
If you count the number of RISC chips selling more than 1,000,000 per month,
then the distinction is moot anyway.

Re: The synergy of type tags on register file registers

<513b154b-b093-4653-9575-b3983b9eb998n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32320&group=comp.arch#32320

  copy link   Newsgroups: comp.arch
X-Received: by 2002:a05:620a:4413:b0:759:5803:3481 with SMTP id v19-20020a05620a441300b0075958033481mr3606706qkp.9.1684810279720;
Mon, 22 May 2023 19:51:19 -0700 (PDT)
X-Received: by 2002:aca:f143:0:b0:397:cc5f:589a with SMTP id
p64-20020acaf143000000b00397cc5f589amr2308880oih.8.1684810279471; Mon, 22 May
2023 19:51:19 -0700 (PDT)
Path: i2pn2.org!i2pn.org!news.1d4.us!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer03.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.arch
Date: Mon, 22 May 2023 19:51:19 -0700 (PDT)
In-Reply-To: <u4h95l$2ee3a$1@dont-email.me>
Injection-Info: google-groups.googlegroups.com; posting-host=2600:1700:291:29f0:74f9:cf9e:4eed:b74d;
posting-account=H_G_JQkAAADS6onOMb-dqvUozKse7mcM
NNTP-Posting-Host: 2600:1700:291:29f0:74f9:cf9e:4eed:b74d
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
<c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com> <8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com>
<u4h95l$2ee3a$1@dont-email.me>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <513b154b-b093-4653-9575-b3983b9eb998n@googlegroups.com>
Subject: Re: The synergy of type tags on register file registers
From: MitchAlsup@aol.com (MitchAlsup)
Injection-Date: Tue, 23 May 2023 02:51:19 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 3925
 by: MitchAlsup - Tue, 23 May 2023 02:51 UTC

On Monday, May 22, 2023 at 9:43:22 PM UTC-5, Paul A. Clayton wrote:
> MitchAlsup wrote:
> > On Monday, May 22, 2023 at 5:44:37 AM UTC-5, luke.l...@gmail.com wrote:
> [snip]
> >> the problems come as you already suspected on context-switch
> >> (including function calls). there you suddenly have not only
> >> registers to save/restore but also their tags. 8-bit tags is
> >> now 32 bytes of extra context, and with the tags being "bits"
> >> your ISA had better have a damn good way to save/restore
> >> individual bytes into tags.
> >
> > It is not just the context, but now you are faced with needing even
> > more memory reference instructions just to save and restore the
> > registers and associated tags--when you don't know what value
> > in in the tags !!??!!
<
> This assumes that the save/restore is done by instructions. For
> context switching, My 66000 does this without instructions but
> would still require special support for function interfaces (only
> for caller-save registers? though architecting the ABI for that
> case may be ill-advised).
<
Doing it without instructions is how it gets done transparently.
Doing it without instructions is how you get shot down in flames, too.
>
> The Mill saves the entire valid Belt on function calls without
> special instructions. (The Mill requires additional instructions
> for widening [and narrowing] when a traditional RISC automatically
> widens on a load and truncates [possibly unsafely] on a store.)
>
> Something like Itanium's Register Stack Engine combined with
> hardware context switching might also avoid adding spill/fill
> instructions that preserve the metadata.
>
> I could also imagine a load multiple instruction that used a
> register to provide the metadata and the store multiple
> instruction that accumulated the metadata into a register that is
> then stored (with an ordinary store instruction as its type is
> known). If the ISA has a zero register, including the zero
> register in the store list might save the metadata in the zero
> register's spot.
>
> Something like My 66000's ENTER/EXIT could probably be extended to
> save the metadata.
<
No extension needed. ENTER and EXIT do not expose the saved
register data (locations, fomats,...) to software (when SafeStack
is in use.)
>
> I suspect there are other ways of avoiding more instructions if
> that is seen as sufficiently important.

Re: The synergy of type tags on register file registers

<05c50c9e-122a-4e12-b762-abf56ecaf5ben@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32321&group=comp.arch#32321

  copy link   Newsgroups: comp.arch
X-Received: by 2002:a05:620a:8399:b0:75b:17fa:cb62 with SMTP id pb25-20020a05620a839900b0075b17facb62mr1018159qkn.7.1684812058991;
Mon, 22 May 2023 20:20:58 -0700 (PDT)
X-Received: by 2002:a9d:6182:0:b0:6a3:e43a:c707 with SMTP id
g2-20020a9d6182000000b006a3e43ac707mr3629196otk.7.1684812058631; Mon, 22 May
2023 20:20:58 -0700 (PDT)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer03.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.arch
Date: Mon, 22 May 2023 20:20:58 -0700 (PDT)
In-Reply-To: <4f54444c-673d-48c7-a9b9-383233b0b608n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=92.19.80.230; posting-account=soFpvwoAAADIBXOYOBcm_mixNPAaxW9p
NNTP-Posting-Host: 92.19.80.230
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
<c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com> <8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com>
<e141ae62-68a2-43fd-ac04-9213e2dfa0b5n@googlegroups.com> <d79ddd12-533d-4369-b6db-e14adefcacb8n@googlegroups.com>
<4f54444c-673d-48c7-a9b9-383233b0b608n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <05c50c9e-122a-4e12-b762-abf56ecaf5ben@googlegroups.com>
Subject: Re: The synergy of type tags on register file registers
From: luke.leighton@gmail.com (luke.l...@gmail.com)
Injection-Date: Tue, 23 May 2023 03:20:58 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 4114
 by: luke.l...@gmail.com - Tue, 23 May 2023 03:20 UTC

On Tuesday, May 23, 2023 at 3:14:43 AM UTC+1, JimBrakefield wrote:

> Does include Power PC [...]

[minor niggle for future reference: "PowerPC(tm)" was a joint initiative between
IBM, Motorola, Apple and I think Sony(?), i am still learning the details but you
likely meant to use "Power ISA" here not "Power PC". the "Power PC" initiative
ended around 15 years ago. Power ISA - the instruction set *behind* the "Power PC"
initiative - is very much still active.]
> Ugh, so off the hook on "many", definitely not "most", could say move multiple is common?

even the SVP64 Extension for Power ISA can only handle up to 127 (registers)
VCOMPRESS/VEXPAND operations and only then by using CR Fields as Predicate
Masks, and that's pushing your luck. 64 would be safer then an INT can
be used as the Predicate Mask. bear in mind that there are 128 GPRs 128 FPRs
128 CR Fields all of which need context-switching so two instructions each
(1: 0-63, 2: 64-127) is still "many".

(127 is down to a limitation of 7 bits for element-offsets)

----------------------

On Tuesday, May 23, 2023 at 3:33:49 AM UTC+1, Scott Lurndal wrote:

> ARMv8 only supports load pair and store pair.

that's the ones i referred to, yes. LD/ST-multi being deprecated.

> A new feature FEAT_LS64 provides two new instructions issue single-copy
> atomic loads and stores of 64 bytes. These use 8 consecutive 64-bit
> general purpose registers.

sigh just when one Hardware Engineer says "oh god no please no
more LD/ST-Multi", another Hardware Engineer says "oh god yes,
please we need LD/ST-Multi"?

a case of left hand not knowing what the right hand did?

-----------------------

On Monday, May 22, 2023 at 6:52:21 PM UTC+1, MitchAlsup wrote:

> With an 8-bit tag, you could simply define rules and just have
> generic arithmetic that simply works::
> i = f×d-f×l+u
> Which would produce 1 multiply, and 1 mac without any conversions.

hang on hang on... this flew by so my brain is catching up. are you
suggesting that by implicit-zeroing it becomes possible to use a
single pipeline that basically does everything? "mul-add, mul-sub,
mul, add, sub" - all in one?

if like in Microwatt (which does micro-coding mentioned last week)
including Carry-in / 0 / 1 as an additional option:

c = runtime-selected Carry-in, 0 or 1
i = f×d-f×l+u + c

then that would be pretty neat. question: would it introduce latency?
how many cycles to complete, compared to a "vanilla" add pipeline?

l.

Re: The synergy of type tags on register file registers

<kd375pFbqm4U1@mid.individual.net>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32322&group=comp.arch#32322

  copy link   Newsgroups: comp.arch
Path: i2pn2.org!i2pn.org!news.swapon.de!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail
From: niklas.holsti@tidorum.invalid (Niklas Holsti)
Newsgroups: comp.arch
Subject: Re: The synergy of type tags on register file registers
Date: Tue, 23 May 2023 10:09:45 +0300
Organization: Tidorum Ltd
Lines: 30
Message-ID: <kd375pFbqm4U1@mid.individual.net>
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
<c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com>
<8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com>
<e141ae62-68a2-43fd-ac04-9213e2dfa0b5n@googlegroups.com>
<d79ddd12-533d-4369-b6db-e14adefcacb8n@googlegroups.com>
<4f54444c-673d-48c7-a9b9-383233b0b608n@googlegroups.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
X-Trace: individual.net qXlwfRPPjzTHhGydAfXU6wkRM0oKFLlxdDL00NTZNrhM6CUOb0
Cancel-Lock: sha1:rLtnuihmWNs7Hm5Kzbf/C8Z93Kg=
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:102.0)
Gecko/20100101 Thunderbird/102.6.1
Content-Language: en-US
In-Reply-To: <4f54444c-673d-48c7-a9b9-383233b0b608n@googlegroups.com>
 by: Niklas Holsti - Tue, 23 May 2023 07:09 UTC

On 2023-05-23 5:14, JimBrakefield wrote:
> On Monday, May 22, 2023 at 8:22:09 PM UTC-5, MitchAlsup wrote:
>> On Monday, May 22, 2023 at 5:32:48 PM UTC-5, JimBrakefield wrote:

[...]

>>> Many/most RISC ISAs have bulk/multiple register save/restore instructions.
>> <
>> Where many/most does not include:: {MIPS, Mc 88K, SPARCV8 or V9, RISC-V}

[...]

> Does include Power PC integer registers, M68000, AMD29000, SPARC
> call/return (eight registers implied), [...]

SPARC call/return do not save multiple registers. You are probably
thinking of the SAVE and RESTORE instructions which rotate the register
ring, but do not perform any reads or writes to memory, unless the
register ring overflows or underflows in which case there is a trap to a
handler that does read or write memory, but not with multiple-register
operations.

SAVE and RESTORE in SPARC are a form of program-controlled register
renaming. They change the mapping of the ISA register numbers to the HW
registers in the register ring.

Granted, SAVE/RESTORE are often used in conjunction with call/return,
but can also be omitted in some cases (say, when calling a leaf routine
that does not need a frame pointer).

Re: The synergy of type tags on register file registers

<b26dc80b-afbf-426e-ad34-ea82f8600d18n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32323&group=comp.arch#32323

  copy link   Newsgroups: comp.arch
X-Received: by 2002:a05:620a:2a03:b0:759:247d:74fa with SMTP id o3-20020a05620a2a0300b00759247d74famr3994783qkp.3.1684850597593;
Tue, 23 May 2023 07:03:17 -0700 (PDT)
X-Received: by 2002:aca:6283:0:b0:396:1b21:f566 with SMTP id
w125-20020aca6283000000b003961b21f566mr3897702oib.1.1684850597363; Tue, 23
May 2023 07:03:17 -0700 (PDT)
Path: i2pn2.org!i2pn.org!news.neodome.net!feeder1.feed.usenet.farm!feed.usenet.farm!peer01.ams4!peer.am4.highwinds-media.com!peer01.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.arch
Date: Tue, 23 May 2023 07:03:17 -0700 (PDT)
In-Reply-To: <05c50c9e-122a-4e12-b762-abf56ecaf5ben@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=2600:1700:291:29f0:39fa:749f:99ce:f7d4;
posting-account=H_G_JQkAAADS6onOMb-dqvUozKse7mcM
NNTP-Posting-Host: 2600:1700:291:29f0:39fa:749f:99ce:f7d4
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
<c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com> <8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com>
<e141ae62-68a2-43fd-ac04-9213e2dfa0b5n@googlegroups.com> <d79ddd12-533d-4369-b6db-e14adefcacb8n@googlegroups.com>
<4f54444c-673d-48c7-a9b9-383233b0b608n@googlegroups.com> <05c50c9e-122a-4e12-b762-abf56ecaf5ben@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <b26dc80b-afbf-426e-ad34-ea82f8600d18n@googlegroups.com>
Subject: Re: The synergy of type tags on register file registers
From: MitchAlsup@aol.com (MitchAlsup)
Injection-Date: Tue, 23 May 2023 14:03:17 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 3260
 by: MitchAlsup - Tue, 23 May 2023 14:03 UTC

On Monday, May 22, 2023 at 10:21:00 PM UTC-5, luke.l...@gmail.com wrote:

> -----------------------
> On Monday, May 22, 2023 at 6:52:21 PM UTC+1, MitchAlsup wrote:
> > With an 8-bit tag, you could simply define rules and just have
> > generic arithmetic that simply works::
> > i = f×d-f×l+u
> > Which would produce 1 multiply, and 1 mac without any conversions.
<
> hang on hang on... this flew by so my brain is catching up. are you
> suggesting that by implicit-zeroing it becomes possible to use a
> single pipeline that basically does everything? "mul-add, mul-sub,
> mul, add, sub" - all in one?
<
I am suggesting that once you tag registers with the data-type,
you are in a position to build calculation units that can perform
cross-type calculations.
>
> if like in Microwatt (which does micro-coding mentioned last week)
> including Carry-in / 0 / 1 as an additional option:
>
> c = runtime-selected Carry-in, 0 or 1
> i = f×d-f×l+u + c
>
> then that would be pretty neat. question: would it introduce latency?
<
Probably, but not much. And you can avoid numeric problems along
the way. For example, say we have an integer with significance bigger
than 1<<52. When converted to FP64 it will get rounded, but when
auto-converted with tagged-registers it does NOT have to be rounded--
it can be used directly with more significance than fits in FP64 !!
<
> how many cycles to complete, compared to a "vanilla" add pipeline?
<
probably 1 cycle.
>
> l.

Re: The synergy of type tags on register file registers

<s54bM.3274280$iU59.2486188@fx14.iad>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32324&group=comp.arch#32324

  copy link   Newsgroups: comp.arch
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer03.iad!feed-me.highwinds-media.com!news.highwinds-media.com!fx14.iad.POSTED!not-for-mail
X-newsreader: xrn 9.03-beta-14-64bit
Sender: scott@dragon.sl.home (Scott Lurndal)
From: scott@slp53.sl.home (Scott Lurndal)
Reply-To: slp53@pacbell.net
Subject: Re: The synergy of type tags on register file registers
Newsgroups: comp.arch
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com> <c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com> <8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com> <e141ae62-68a2-43fd-ac04-9213e2dfa0b5n@googlegroups.com> <d79ddd12-533d-4369-b6db-e14adefcacb8n@googlegroups.com> <4f54444c-673d-48c7-a9b9-383233b0b608n@googlegroups.com> <05c50c9e-122a-4e12-b762-abf56ecaf5ben@googlegroups.com>
Lines: 21
Message-ID: <s54bM.3274280$iU59.2486188@fx14.iad>
X-Complaints-To: abuse@usenetserver.com
NNTP-Posting-Date: Tue, 23 May 2023 14:29:44 UTC
Organization: UsenetServer - www.usenetserver.com
Date: Tue, 23 May 2023 14:29:44 GMT
X-Received-Bytes: 1737
 by: Scott Lurndal - Tue, 23 May 2023 14:29 UTC

"luke.l...@gmail.com" <luke.leighton@gmail.com> writes:
>On Tuesday, May 23, 2023 at 3:14:43=E2=80=AFAM UTC+1, JimBrakefield wrote:
>
>> Does include Power PC [...]
>

>> A new feature FEAT_LS64 provides two new instructions issue single-copy=
>=20
>> atomic loads and stores of 64 bytes. These use 8 consecutive 64-bit=20
>> general purpose registers.=20
>
>sigh just when one Hardware Engineer says "oh god no please no
>more LD/ST-Multi", another Hardware Engineer says "oh god yes,
>please we need LD/ST-Multi"?
>
>a case of left hand not knowing what the right hand did?

In this case, the assumption is that an implementation of FEAT_LS64 will have
a 512-bit-wide bus from the processor to the coprocessor
and the transfer will be a single bus transaction.

Re: The synergy of type tags on register file registers

<c1906b8e-172f-4969-be37-b216c9e42a9bn@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32325&group=comp.arch#32325

  copy link   Newsgroups: comp.arch
X-Received: by 2002:a05:622a:1f07:b0:3f6:b16a:34bb with SMTP id ca7-20020a05622a1f0700b003f6b16a34bbmr1341631qtb.3.1684856337891;
Tue, 23 May 2023 08:38:57 -0700 (PDT)
X-Received: by 2002:aca:c28b:0:b0:396:1512:6fd5 with SMTP id
s133-20020acac28b000000b0039615126fd5mr3998666oif.10.1684856337633; Tue, 23
May 2023 08:38:57 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder8.news.weretis.net!feeder1.feed.usenet.farm!feed.usenet.farm!peer01.ams4!peer.am4.highwinds-media.com!peer01.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.arch
Date: Tue, 23 May 2023 08:38:57 -0700 (PDT)
In-Reply-To: <s54bM.3274280$iU59.2486188@fx14.iad>
Injection-Info: google-groups.googlegroups.com; posting-host=2600:1700:291:29f0:39fa:749f:99ce:f7d4;
posting-account=H_G_JQkAAADS6onOMb-dqvUozKse7mcM
NNTP-Posting-Host: 2600:1700:291:29f0:39fa:749f:99ce:f7d4
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
<c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com> <8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com>
<e141ae62-68a2-43fd-ac04-9213e2dfa0b5n@googlegroups.com> <d79ddd12-533d-4369-b6db-e14adefcacb8n@googlegroups.com>
<4f54444c-673d-48c7-a9b9-383233b0b608n@googlegroups.com> <05c50c9e-122a-4e12-b762-abf56ecaf5ben@googlegroups.com>
<s54bM.3274280$iU59.2486188@fx14.iad>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <c1906b8e-172f-4969-be37-b216c9e42a9bn@googlegroups.com>
Subject: Re: The synergy of type tags on register file registers
From: MitchAlsup@aol.com (MitchAlsup)
Injection-Date: Tue, 23 May 2023 15:38:57 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 3005
 by: MitchAlsup - Tue, 23 May 2023 15:38 UTC

On Tuesday, May 23, 2023 at 9:31:25 AM UTC-5, Scott Lurndal wrote:
> "luke.l...@gmail.com" <luke.l...@gmail.com> writes:
> >On Tuesday, May 23, 2023 at 3:14:43=E2=80=AFAM UTC+1, JimBrakefield wrote:
> >
> >> Does include Power PC [...]
> >
> >> A new feature FEAT_LS64 provides two new instructions issue single-copy=
> >=20
> >> atomic loads and stores of 64 bytes. These use 8 consecutive 64-bit=20
> >> general purpose registers.=20
> >
> >sigh just when one Hardware Engineer says "oh god no please no
> >more LD/ST-Multi", another Hardware Engineer says "oh god yes,
> >please we need LD/ST-Multi"?
> >
> >a case of left hand not knowing what the right hand did?
<
> In this case, the assumption is that an implementation of FEAT_LS64 will have
> a 512-bit-wide bus from the processor to the coprocessor
> and the transfer will be a single bus transaction.
<
Technology is at the point where 512-bit wide bus (line size) should be standard.
Then bus transactions are single beat--which makes the protocol(s) easier.
<
As to the assertion that LDM/STM are "hard" on the renamer--I found that a
simple mask addition at the renamer is adequate for dealing with all the
standard call/return interlocking.

Re: The synergy of type tags on register file registers

<u4vonr$25ppt$1@newsreader4.netcologne.de>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32385&group=comp.arch#32385

  copy link   Newsgroups: comp.arch
Path: i2pn2.org!i2pn.org!weretis.net!feeder8.news.weretis.net!newsreader4.netcologne.de!news.netcologne.de!.POSTED.2001-4dd4-fddc-0-7285-c2ff-fe6c-992d.ipv6dyn.netcologne.de!not-for-mail
From: tkoenig@netcologne.de (Thomas Koenig)
Newsgroups: comp.arch
Subject: Re: The synergy of type tags on register file registers
Date: Sun, 28 May 2023 14:33:31 -0000 (UTC)
Organization: news.netcologne.de
Distribution: world
Message-ID: <u4vonr$25ppt$1@newsreader4.netcologne.de>
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
<c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com>
<8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com>
<e141ae62-68a2-43fd-ac04-9213e2dfa0b5n@googlegroups.com>
<d79ddd12-533d-4369-b6db-e14adefcacb8n@googlegroups.com>
<4f54444c-673d-48c7-a9b9-383233b0b608n@googlegroups.com>
<05c50c9e-122a-4e12-b762-abf56ecaf5ben@googlegroups.com>
<b26dc80b-afbf-426e-ad34-ea82f8600d18n@googlegroups.com>
Injection-Date: Sun, 28 May 2023 14:33:31 -0000 (UTC)
Injection-Info: newsreader4.netcologne.de; posting-host="2001-4dd4-fddc-0-7285-c2ff-fe6c-992d.ipv6dyn.netcologne.de:2001:4dd4:fddc:0:7285:c2ff:fe6c:992d";
logging-data="2287421"; mail-complaints-to="abuse@netcologne.de"
User-Agent: slrn/1.0.3 (Linux)
 by: Thomas Koenig - Sun, 28 May 2023 14:33 UTC

MitchAlsup <MitchAlsup@aol.com> schrieb:

> Probably, but not much. And you can avoid numeric problems along
> the way. For example, say we have an integer with significance bigger
> than 1<<52. When converted to FP64 it will get rounded, but when
> auto-converted with tagged-registers it does NOT have to be rounded--
> it can be used directly with more significance than fits in FP64 !!

While true, this would go against the rules of many, if not all
programming langues. These prescribe conversion of integer to
floating point before doing a calculation with a floating point.

Re: The synergy of type tags on register file registers

<28d44ec5-350d-4fcf-bb05-baf38e913db4n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32397&group=comp.arch#32397

  copy link   Newsgroups: comp.arch
X-Received: by 2002:a0c:f8d2:0:b0:626:12a7:1a7a with SMTP id h18-20020a0cf8d2000000b0062612a71a7amr447800qvo.6.1685297971418;
Sun, 28 May 2023 11:19:31 -0700 (PDT)
X-Received: by 2002:a05:6870:b1d1:b0:19f:325:6e45 with SMTP id
x17-20020a056870b1d100b0019f03256e45mr2201013oak.3.1685297971196; Sun, 28 May
2023 11:19:31 -0700 (PDT)
Path: i2pn2.org!i2pn.org!eternal-september.org!news.eternal-september.org!border-1.nntp.ord.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.arch
Date: Sun, 28 May 2023 11:19:30 -0700 (PDT)
In-Reply-To: <u4vonr$25ppt$1@newsreader4.netcologne.de>
Injection-Info: google-groups.googlegroups.com; posting-host=92.19.80.230; posting-account=soFpvwoAAADIBXOYOBcm_mixNPAaxW9p
NNTP-Posting-Host: 92.19.80.230
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
<c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com> <8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com>
<e141ae62-68a2-43fd-ac04-9213e2dfa0b5n@googlegroups.com> <d79ddd12-533d-4369-b6db-e14adefcacb8n@googlegroups.com>
<4f54444c-673d-48c7-a9b9-383233b0b608n@googlegroups.com> <05c50c9e-122a-4e12-b762-abf56ecaf5ben@googlegroups.com>
<b26dc80b-afbf-426e-ad34-ea82f8600d18n@googlegroups.com> <u4vonr$25ppt$1@newsreader4.netcologne.de>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <28d44ec5-350d-4fcf-bb05-baf38e913db4n@googlegroups.com>
Subject: Re: The synergy of type tags on register file registers
From: luke.leighton@gmail.com (luke.l...@gmail.com)
Injection-Date: Sun, 28 May 2023 18:19:31 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Lines: 47
 by: luke.l...@gmail.com - Sun, 28 May 2023 18:19 UTC

On Sunday, May 28, 2023 at 3:35:20 PM UTC+1, Thomas Koenig wrote:
> MitchAlsup <Mitch...@aol.com> schrieb:
> > Probably, but not much. And you can avoid numeric problems along
> > the way. For example, say we have an integer with significance bigger
> > than 1<<52. When converted to FP64 it will get rounded, but when
> > auto-converted with tagged-registers it does NOT have to be rounded--
> > it can be used directly with more significance than fits in FP64 !!
> While true, this would go against the rules of many, if not all
> programming langues. These prescribe conversion of integer to
> floating point before doing a calculation with a floating point.

also stops you from being able to service an Interrupt during
the time that the instruction is issued until there is no longer
a time it could be used. as that could be tens of millions of
instructions later, you are hosed.

* reg1: 9999<<52 (int)
* instruction issued reg2 = BIGINT_to_FP64(reg1)
* instruction(s) issued: reg3 = reg2 * 2.5
* ...
* ...
* millions more instructions none overwritign reg2
* another use of reg2: reg4 = reg2 + 0.0000001

if reg2 is *NOT* exactly the same accuracy as what
went into reg3 and reg4, where are the extraneous bits
stored during the millions of instructions executed?

the only possibility would be an overwrite macro-op
fusion:

reg2 = BIGINT_to_FP64(reg1)
reg2 = reg2 * 2.5

and then it becomes vital to not allow interrupts
between those two instructions, you also just made
a mess of Multi-Issue Decode (because that's now
a double-normal-length *ACTUAL* instruction and
you just unintentionally introduced Variable-Length
Encoding by the back door), and generally gotten
into ISA hell from that point onward.

sounds as Mitch suggests much better to do what
everyone else does.

l.

Re: The synergy of type tags on register file registers

<u509r9$1062s$1@dont-email.me>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=32398&group=comp.arch#32398

  copy link   Newsgroups: comp.arch
Path: i2pn2.org!i2pn.org!eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: cr88192@gmail.com (BGB)
Newsgroups: comp.arch
Subject: Re: The synergy of type tags on register file registers
Date: Sun, 28 May 2023 14:25:23 -0500
Organization: A noiseless patient Spider
Lines: 45
Message-ID: <u509r9$1062s$1@dont-email.me>
References: <08f739ac-2200-408c-a578-79e93f9cb272n@googlegroups.com>
<c2bde3aa-0851-4d6a-853c-4d86e0f6d932n@googlegroups.com>
<8592c1d6-237d-4700-92df-e80768deb54bn@googlegroups.com>
<e141ae62-68a2-43fd-ac04-9213e2dfa0b5n@googlegroups.com>
<d79ddd12-533d-4369-b6db-e14adefcacb8n@googlegroups.com>
<4f54444c-673d-48c7-a9b9-383233b0b608n@googlegroups.com>
<05c50c9e-122a-4e12-b762-abf56ecaf5ben@googlegroups.com>
<b26dc80b-afbf-426e-ad34-ea82f8600d18n@googlegroups.com>
<u4vonr$25ppt$1@newsreader4.netcologne.de>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Sun, 28 May 2023 19:25:30 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="e56593e5a9e5d581f41eba438773153c";
logging-data="1054812"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+WvsDwzM9FQFIjrEaCMy0P"
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101
Thunderbird/102.11.0
Cancel-Lock: sha1:DyL8swym2fhsGyj0hojOCUndbhQ=
In-Reply-To: <u4vonr$25ppt$1@newsreader4.netcologne.de>
Content-Language: en-US
 by: BGB - Sun, 28 May 2023 19:25 UTC

On 5/28/2023 9:33 AM, Thomas Koenig wrote:
> MitchAlsup <MitchAlsup@aol.com> schrieb:
>
>> Probably, but not much. And you can avoid numeric problems along
>> the way. For example, say we have an integer with significance bigger
>> than 1<<52. When converted to FP64 it will get rounded, but when
>> auto-converted with tagged-registers it does NOT have to be rounded--
>> it can be used directly with more significance than fits in FP64 !!
>
> While true, this would go against the rules of many, if not all
> programming langues. These prescribe conversion of integer to
> floating point before doing a calculation with a floating point.

Agreed.

Also it seems like it could lead to problems.

What if an interrupt happens, does the precision of the calculation
depend on the presence or absence of an interrupt?... Or, does the ISR
now need to save and restore, say, 96-bit registers? ...

For many problems, it seems more like repeatability matters more than
absolute precision. Say, that the same calculation with the same inputs
always produces the same result, even if this answer is "wrong" in a
more strict interpretation.

Say, with the amount of "implicit" architectural state being kept to a
minimum.

Ironically, in my case this led to things like emulator fun of needing
to fake my CPU's arguably "bad" handling of floating-point in some
cases, rather than using the "better" native FPU operations, since this
led to behavioral divergence in some cases.

Kinda similar ends up applying to things like RGB555 or block-texture
decoding, where the "bad" definitions often end up being preferable to
the "better" definitions for one reason or another.

....

Pages:12345678910
server_pubkey.txt

rocksolid light 0.9.8
clearnet tor