Libre RISC-V Mailing list Archives (accessible via public-inbox)
 help / color / Atom feed
* [libre-riscv-dev] [Bug 339] create POWER9 ROTATE pipeline
From: bugzilla-daemon @ 2020-05-22 17:41 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-339-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=339

--- Comment #1 from Luke Kenneth Casson Leighton <lkcl@lkcl.net> ---
examining the shift operations, they generate CR0, and optionally the
Arithmetic ones will set CA and also read carry in.

do the Arith Shift also set the overflow flag?

microwatt does not have OV set, which tends to suggest that we can drop XER.SO
from the output regspec for this pipeline.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 305] Create Pipelined ALU similar to alu_hier.py
From: bugzilla-daemon @ 2020-05-22 17:27 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-305-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=305

Luke Kenneth Casson Leighton <lkcl@lkcl.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           See Also|                            |https://bugs.libre-soc.org/
                   |                            |show_bug.cgi?id=339

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 339] create POWER9 ROTATE pipeline
From: bugzilla-daemon @ 2020-05-22 17:27 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-339-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=339

Luke Kenneth Casson Leighton <lkcl@lkcl.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           See Also|                            |https://bugs.libre-soc.org/
                   |                            |show_bug.cgi?id=305

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 339] New: create POWER9 ROTATE pipeline
From: bugzilla-daemon @ 2020-05-22 17:27 UTC (permalink / raw)
  To: libre-riscv-dev

https://bugs.libre-soc.org/show_bug.cgi?id=339

            Bug ID: 339
           Summary: create POWER9 ROTATE pipeline
           Product: Libre-SOC's first SoC
           Version: unspecified
          Hardware: Other
                OS: Linux
            Status: CONFIRMED
          Severity: enhancement
          Priority: ---
         Component: Source Code
          Assignee: lkcl@lkcl.net
          Reporter: lkcl@lkcl.net
                CC: libre-riscv-dev@lists.libre-riscv.org
   NLnet milestone: ---

a pipeline is needed covering shift and rotate operations.
https://libre-soc.org/openpower/isa/fixedshift/

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 330] create POWER9 Logic Pipeline
From: bugzilla-daemon @ 2020-05-22 17:17 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-330-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=330

--- Comment #2 from Luke Kenneth Casson Leighton <lkcl@lkcl.net> ---
michael i am just reviewing the isatables for LOGICAL operations.  two things
struck me:

1. CR0 is apparently an input for OP_CNTZ but not an output, and we have no cr0
in LogicalInputData.

2. i am not seeing any of the LOGICAL operations listed as needing carry in nor
producing carry out.

looking here:
https://libre-soc.org/openpower/isa/fixedlogical/

it does not appear that any or them set anything other than CR0 and that is an
output only.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 305] Create Pipelined ALU similar to alu_hier.py
From: bugzilla-daemon @ 2020-05-22 16:17 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-305-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=305

Luke Kenneth Casson Leighton <lkcl@lkcl.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           See Also|                            |https://bugs.libre-soc.org/
                   |                            |show_bug.cgi?id=338

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 338] CompUnitALU needs go_die to be wired to ALU shadow mask
From: bugzilla-daemon @ 2020-05-22 16:17 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-338-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=338

Luke Kenneth Casson Leighton <lkcl@lkcl.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Blocks|                            |81
           See Also|                            |https://bugs.libre-soc.org/
                   |                            |show_bug.cgi?id=305


Referenced Bugs:

https://bugs.libre-soc.org/show_bug.cgi?id=81
[Bug 81] implement 6600-style "precise" out-of-order scoreboard
-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 338] New: CompUnitALU needs go_die to be wired to ALU shadow mask
From: bugzilla-daemon @ 2020-05-22 16:16 UTC (permalink / raw)
  To: libre-riscv-dev

https://bugs.libre-soc.org/show_bug.cgi?id=338

            Bug ID: 338
           Summary: CompUnitALU needs go_die to be wired to ALU shadow
                    mask
           Product: Libre-SOC's first SoC
           Version: unspecified
          Hardware: PC
                OS: Mac OS
            Status: CONFIRMED
          Severity: enhancement
          Priority: ---
         Component: Source Code
          Assignee: lkcl@lkcl.net
          Reporter: lkcl@lkcl.net
                CC: libre-riscv-dev@lists.libre-riscv.org
   NLnet milestone: ---

this is for ALU cancellation.  when go_die is pulled on a Comp Unit, it
indicates
that the result - computed or in transit to *be* computed - is no longer
required
and must be dropped on the floor, immediately.

ALU pipelines are to be set up with "cancellation" capability.  this is set
from nmutil.concurrentunit.ReservationStations "maskwid" parameter, which is
set one per CompUnit.  with the cancellation mask being N bits wide,
N go_die CompUnits may be connected together on the front, one go_die signal
to each cancellation mask bit.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* Re: [libre-riscv-dev] daily kan-ban update 22may2020
From: Luke Kenneth Casson Leighton @ 2020-05-22 15:39 UTC (permalink / raw)
  To: Libre-RISCV General Development
In-Reply-To: <12784a62-e23b-1400-c16f-04e8929df354@gmail.com>

On Fri, May 22, 2020 at 4:20 PM Michael Nolan <mtnolan2640@gmail.com> wrote:

> Today I reworked the formal proof for the CR FU by adding a translation
> layer so I could use most of the existing proof on the new interface.

retrospectively this may have been the best way to do it, due to the
awkwardness of indexing dynamic bit-masked groups.

> I also ported the branch FU to use the new CR interface.

confirmed the unit tests run.

> This afternoon I
> will probably work on writing a proof for the branch unit, and work some
> on the bperm module with Cole.

excellent.

_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* Re: [libre-riscv-dev] daily kan-ban update 22may2020
From: Michael Nolan @ 2020-05-22 15:19 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <CAPweEDwtA3H9yP0JGQ2CvoR0ZbT0O2hasTbqam+tw7zQmKJ=Dg@mail.gmail.com>

Yesterday I worked on porting the CR function unit to the new CR 
interface (taking in several 4 bit CR fields instead of the full register).

Today I reworked the formal proof for the CR FU by adding a translation 
layer so I could use most of the existing proof on the new interface. I 
also ported the branch FU to use the new CR interface. This afternoon I 
will probably work on writing a proof for the branch unit, and work some 
on the bperm module with Cole.

--Michael


_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] daily kan-ban update 22may2020
From: Luke Kenneth Casson Leighton @ 2020-05-22 15:02 UTC (permalink / raw)
  To: Libre-RISCV General Development

little late.  yesterday and this morning

* helped Michael go over the Condition Register pipeline reorg.  the CR
regfile is to be split into 8 4bit registers rather than one massive 32 bit
one
* sorted new CR register allocation scheme for when we put a CompUnit in
front of it
* described to Cesar the design mod requirements to ALUCompUnit needed: to
add selection of RA being a zero immediate and to bypass RD.REQ[0] when
that happens.
* added a zero_a flag to Decode2ExecuteType to support that
* reorganised the soc.fu code a little after separating out the op subsets
CompBrOpSubset etc
* cookie cut shiftreg and logical to soc.fu.mul and soc.fu.div
respectively, and placed some stub code for replacing with ieee754fpu
pipeline stages, for Jacob
* helped Jean-Paul in understanding the FU-FU Dependency Matrix so he can
do a layout experiment in coriolis2
* attended both OpenPOWER weekly coffee calls which were nice to do,
especially learning about microwatt first boot and also what Cesar does.
both very cool.

y'know... i have to say, i am not often aware at the time because i take
breaks and binge watch series episodes (Stargate SG1 at present, but only
because i ran out of American Ninja Warrior episodes), but each day when
actually written out does seem to be one hell of a lot.  this probably
because i don't do anything else, the entire day.

anyway.

todo:

* draw out a new ALUCompUnit diagram for documentation purposes
* keep an eye out for Cole.  i couldn't work it out, either.  might need
your help, Michael.
* keep thinking through the multi comp unit data structures.
* answer issues as they come up

l.



-- 
---
crowd-funded eco-conscious hardware: https://www.crowdsupply.com/eoma68
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 313] Create Branch Pipeline for POWER9
From: bugzilla-daemon @ 2020-05-22 14:51 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-313-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=313

--- Comment #37 from Michael Nolan <mtnolan2640@gmail.com> ---
(In reply to Luke Kenneth Casson Leighton from comment #36)
> (In reply to Michael Nolan from comment #35)
> 
> > I think it'll actually be
> > 
> > CR0: bit 0 1 2 3 CR1: 4 5 6 7 CR2: 8 9 10 11
> 
> and.. um.. um... branch main_stage does crbit = cr[3-BI[0:2]] something like
> that?

Just updated it to use the new interface, and yep that's what it does.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 313] Create Branch Pipeline for POWER9
From: bugzilla-daemon @ 2020-05-22 14:33 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-313-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=313

--- Comment #36 from Luke Kenneth Casson Leighton <lkcl@lkcl.net> ---
(In reply to Michael Nolan from comment #35)

> I think it'll actually be
> 
> CR0: bit 0 1 2 3 CR1: 4 5 6 7 CR2: 8 9 10 11

and.. um.. um... branch main_stage does crbit = cr[3-BI[0:2]] something like
that?

> but it'll need some testing to be sure.

sigh :)

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 313] Create Branch Pipeline for POWER9
From: bugzilla-daemon @ 2020-05-22 14:11 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-313-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=313

--- Comment #35 from Michael Nolan <mtnolan2640@gmail.com> ---
(In reply to Luke Kenneth Casson Leighton from comment #34)

> however for the purposes of this discussion, the LSBs/MSBs i *believe*
> is as simple as hard-wiring the ordering correctly on the 32-bit path.
> 
> * all 8 4-bit read/writes *at the regfile*, to produce the full 32-bit CR,
>   will be LSB/MSB *hard-wired* correctly, right there.
> 
> 
> so with that in mind, would i be correct in thinking that the CR Regfile
> actually needs to store the data as:
> 
> CR0: bit 3 2 1 0 CR1: 7 6 5 4 CR2: 11 10 9 8
> 
> ?

I think it'll actually be

CR0: bit 0 1 2 3 CR1: 4 5 6 7 CR2: 8 9 10 11

but it'll need some testing to be sure.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 329] coriolis2 experiment layout for Dependency Matrices
From: bugzilla-daemon @ 2020-05-22 13:53 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-329-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=329

--- Comment #8 from Luke Kenneth Casson Leighton <lkcl@lkcl.net> ---
after a little thought, see the diagram in attachment "fu-fu matrix"
https://bugs.libre-soc.org/attachment.cgi?id=58

notice there is "Group1", "Group2", "Group3" at the bottom?

these are the Priority Pickers.

there are separate Register Files (and there are 5R2W ports in the original
CDC 6600)

therefore, in the original CDC 6600, they had 3x banks of Priority Pickers.

if we follow this arrangement, it means that readable_o and writable_o
definitely come out at the BOTTOM of the FU-FU Matrix.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 333] investigate why CR pipeline code took 100% CPU and locked up generating ILANG
From: bugzilla-daemon @ 2020-05-22 13:49 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-333-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=333

--- Comment #31 from Luke Kenneth Casson Leighton <lkcl@lkcl.net> ---
(In reply to Michael Nolan from comment #30)
> (In reply to Luke Kenneth Casson Leighton from comment #26)
> > ls -altr
> > 
> >       90820 May 21 20:27 cr_pipeline.il
> > 
> > WOW.  down from 600k to 90k.
> > 
> > absolutely massive difference.
> 
> Gates are down too, from 2186 to 818

superb.  i don't believe we switched one problem for another: the
Condition Regfile can be designed in a manageable fashion, not
involving accidental creation of massive crossbars.

> Finally managed to get the CR proof working by leaving the original proof
> bits intact, and adding machinery to select the cr inputs and combine it
> back into the outputs.

eek :)

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 313] Create Branch Pipeline for POWER9
From: bugzilla-daemon @ 2020-05-22 13:46 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-313-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=313

--- Comment #34 from Luke Kenneth Casson Leighton <lkcl@lkcl.net> ---
(In reply to Michael Nolan from comment #33)
> (In reply to Luke Kenneth Casson Leighton from comment #32)
> > > then in OP_BC look up the remaining 2 bits of BI to select which bit of CRn
> > > is to be used, right?
> > 
> > (2 LSBs)
> 
> Yep, that's the idea!

excccellent, muhahaha oopssorry.

> I think the register file should be designed to address the 8 crs in the
> correct bit order. If I ask for cr0, I should get cr0, whether cr0 comes
> from the 4 lsbs of the full register, or the 4 msbs.

sigh.  i will need help when it comes to that.  i will have no clue which
way round.

basically i believe it may be quite simple... but this is POWER.

* the CR regfile will be subdivided into 8 separate latch-banks (not a
  standard SRAM, at all)

* there will be 8 read-enable (and write-enable) lines.

* it will be possible to read/write *all* of those simultaneously to obtain
  the full 32-bit CR.  this on a 32-bit data path

* it will also be possible to read/write individual 4-bit CRs by a single
  read/write-enable line.  this on a 4-bit data path

the DMs take care of ensuring that 32 and 4 bit read/writes are entirely
mutually exclusively time-sliced.

however for the purposes of this discussion, the LSBs/MSBs i *believe*
is as simple as hard-wiring the ordering correctly on the 32-bit path.

* all 8 4-bit read/writes *at the regfile*, to produce the full 32-bit CR,
  will be LSB/MSB *hard-wired* correctly, right there.


so with that in mind, would i be correct in thinking that the CR Regfile
actually needs to store the data as:

CR0: bit 3 2 1 0 CR1: 7 6 5 4 CR2: 11 10 9 8

?

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 333] investigate why CR pipeline code took 100% CPU and locked up generating ILANG
From: bugzilla-daemon @ 2020-05-22 13:36 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-333-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=333

--- Comment #30 from Michael Nolan <mtnolan2640@gmail.com> ---
(In reply to Luke Kenneth Casson Leighton from comment #26)
> ls -altr
> 
>       90820 May 21 20:27 cr_pipeline.il
> 
> WOW.  down from 600k to 90k.
> 
> absolutely massive difference.

Gates are down too, from 2186 to 818



Finally managed to get the CR proof working by leaving the original proof bits
intact, and adding machinery to select the cr inputs and combine it back into
the outputs.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 329] coriolis2 experiment layout for Dependency Matrices
From: bugzilla-daemon @ 2020-05-22 13:35 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-329-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=329

--- Comment #7 from Luke Kenneth Casson Leighton <lkcl@lkcl.net> ---
(In reply to Jean-Paul.Chaput from comment #6)
> (In reply to Luke Kenneth Casson Leighton from comment #5)
> > i just also added a second one to experiment8 as an illustration, it is an
> > FU-Regs Matrix with the following parameters:
> > 
> > * Number of Regs:                          4 (to keep it small as a demo)
> > * Number of Function Units:                3 (likewise)
> > * Number of Regfile Read ports protected:  2
> > * Number of Regfile Write ports protected: 2
> > 
> > these numbers can and will vary.  we have *four* Register Files to
> > protect with these Matrices.  five when we have FP support.
> 
> Hello Luke,
> 
> I'm looking closely to the examples but I still have problem understanding
> the matrix
> nature of the design. As a first I would like to concentrate on the FU-FU
> matrix, which,
> if I understand well, manage the read/write dependencies between FUs and
> generate the
> Go_Read & Go_Write signals towards the CU (and some other signals).

that's a pretty good understanding.  it however covers a bit more scope
than is needed here.  this needs understanding of the relationship 
between readable_o and go_read_o (and writable_o and go_write_o).

first: all of those are bitvectors.  every bitvector element in *all*
of *_i and *_o refers to the same FU number.

* go_rd1[0] is for FU 0
* issue_i[0] is for FU 0
* wr_pend_i[0] is for FU 0
* readable_o[0] is ... for FU...0

etc.


the FU-FU Matrix generates the *desire* (the readiness) to be readABLE
and also writABLE.  many of these could potentially be raised simultaneously,
however we have limited numbers of Regfile read ports and write ports.

we therefore need to pick one, because Regfile ports are a limited (broadcast,
global bus) resource.

thus, these signals go through a "Priority Picker" to select *which one*
of the readable_o is to be sent to the Register File as a GO_READ, and
also to notify *one* Function Unit that the data being broadcast from
the Register File Read Ports is *specifically* for that Function Unit and
that Function Unit only.

likewise writable_o goes through a *separate* Priority Picker.

you can see that process in this diagram here:

https://libre-soc.org/3d_gpu/group_pick_rd_rel.jpg

so for the purposes of this experiment we focus on readable_o and writeable_o
only: go_read *OUT* and go_write *OUT* are out of scope.

however... and here is where it gets to be fun:

those go_read and go_write signals as **INPUTS** to the FU-FU Matrix tell
us something very important:

* they tell us that, right now, on this cycle, one FU (which is some distance
  away from the FU-FU Matrix) *IS* receiving its Read Regists

* that therefore, the FU-FU Cell's job, which is to protect and preserve
  the Directed Acyclic Graph of read-write hazards, is NO LONGER required
  to protect that Read Dependency

* that therefore, that FU-FU cell may CANCEL the Read Dependency by pulling
  the Latch low.

a similar process occurs for go_write, obviously.  in addition, note
that go_die_i also fires *all* go_writes and *all* go_reads, because
it is a cancel / reset signal for that particular bitvector-numbered FU.


therefore,

* readable_o bitvector comes out, goes through PriorityPicker (out of scope of
  this layout), go_read_o bitvector comes out of that

* go_read_i bitvector (same NETLIST as go_read_o) comes back *IN* to the FU-FU
  Matrix.


note for layout:

* go_read_i bitvector wires should definitely be laid out horizontally.
* likewise go_write_i and go_die_i bitvectors.  these on the LEFT.
* there are *multiple* go_read_i bitvectors - go_rd1_i, go_rd2_i, go_rd3_i...
* because i used bitvectors (including in the SR Latches), the Matrix is
  effectively split into a 1D array of 1D bitvector "managers".  these
  are named dm0, dm1.. etc.
* dm0, dm1, dm2 .... etc. need to be laid out *vertically* in order to
  accept the horizontal input from go_read_i and go_write_i
* issue_i, rd_pend_i and wr_pend_i are also best done i believe as
  horizontal signals.

so that is inputs.

regarding outputs:

* wr_wait_o and rd_wait_o on the other hand: these are what go into those
  GreatBigORGates (fur_x1/2/3/4) and i *believe*, because dm0..3 need to
  be laid out vertically, the readable_o and writable_o bitvectors need
  to come out at the BOTTOM.

* on the other hand, if instead fur_x1/2/3/4 are done as very very skinny
  cells, practically empty, using available free space inside dm0/1/2/3,
  readable_o and writable_o could just as easily come out at the RIGHT.

either way does not matter for outputs: the inputs do matter though.

summary:

* anything as input (*_i) comes in on the LEFT and is wired HORIZONTAL
* anything as output (*_o) should go out on the BOTTOM and be wired VERTICAL
  however it may work if it is RIGHT and HORIZONTAL.  this is up to you.


> There is two "level" of matrixes:
> 
> 1. The architectural level (that is close to what you do) and the one I
> cannot clearly
>    guess. With 3 FU, is there a 3x3 matrix or 3 FU blocks only, and in the
> later case,
>    it may not be a matrix but just a row or a column.
>      But maybe I make confusion between FU and the dependency matrix of the
> FUs.

yes.  FUs are located. nowhere near the FU-FU matrix.  an FU may be a FMAC
for example, which will be... 20,000 gates, and there will be... 4 of those.

the FU-FU Matrix is tiny by comparison, and centralised, and you absolutely
do not want the two to be amalgamated.

* FU does the job of *computing* results based on operands

* FU-FU Matrix does the job of preserving the Directed Acyclic Graph (DAG) of
  relationships *BETWEEN* FUs.


> 2. The layout (cell level) into which the cells of *one* FU (or whatever
> sub-block)
>    are also arrayed in a matrix. As we may not put all the cells of a block
> in just
>    one row.
> 
> So would it be possible to send examples where one block of the matrix (in
> the
> sense of 1.) is clearly identified (best would be that it is put in a
> sub-block) ?

yaa of course.  (it is already in a sub-block).  added to experiment8,
test_fu_fu_matrix.il.  which you can re-generated to any size you wish
to using this:
https://git.libre-soc.org/?p=soc.git;a=blob;f=src/soc/scoremulti/fu_fu_matrix.py;hb=HEAD

and altering the n_fu_cols and n_fu_rows (make sure they are the same).


> 
> Or, if it is really inconvenient due to the way the design is described at
> nMigne level,
> list me what I/O signals (which bit of vectors) are specific to one element
> of the
> matrix ?

ok.

so because of the recursive nature of a Directed Acyclic Graph, what you
ask in both (1) *and* (2) is, strictly speaking, not possible.

i may have this the wrong way round, please forgive me for that:

* a row in the FU-FU Matrix expresses that one FU has a *BLOCK* on other FUs
  (and each element in that row says which one)

  this would be "outputs" on a node in the Directed Acyclic Graph of
  read-write dependencies

* a column in the FU-FU expresses that one FU is *BLOCKED BY* another FU
  (and each element in that column says which one)

  this would be "inputs" on a node in the Directed Acyclic Graph of
  read-write dependencies

therefore, technically, it is not possible to "divide" them from each other,
from an inter-relationship perspective.

however... for convenience, what i have had to do is to *actually* divide
them into a 1D array of 1D arrays.  this because of the simulation speed
of nmigen.

a previous version, i had *actual* 2D cells.  each SR Latch was a single
bit (not a bitvector).  this was so horribly slow i could not tolerate it.


> A slow learner.

this is a complex topic.

> PS: I still not completely understand the color coding of the scoreboard
> schematic.
>     Is the size and position of the little blue/yellow/green squares inside
> the red one
>     significant?

bear in mind this is for the FU-Regs Matrix image (see attachments, here,
or see p23)

scoreboard_mechanics.1.pdf - section 10.5 p23 "A scoreboard using Dep Matrix"

In this diagram

* a red box denotes that this entry can read or write those registers.
* A blue box denotes that it is possible for an instruction in that
  Unit to write to this register.
* A yellow box indicates that an instruction in this Unit can read
  this register.
* Finally, a green box indicates that this Unit can either read
  this register for normal activities, or write to this register if a store
  is being performed.

For each of the boxes a clocked set-reset flip-flop is used to gate state
changes into the table so that subsequent instructions will see the state of
the current register data-flow dependencies.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 313] Create Branch Pipeline for POWER9
From: bugzilla-daemon @ 2020-05-22 13:10 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-313-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=313

--- Comment #33 from Michael Nolan <mtnolan2640@gmail.com> ---
(In reply to Luke Kenneth Casson Leighton from comment #32)
> (In reply to Luke Kenneth Casson Leighton from comment #31)
> 
> > the idea is to use 3 bits of BI to look up CR00 to 7
> 
> (3 MSBs)
> 
> > then in OP_BC look up the remaining 2 bits of BI to select which bit of CRn
> > is to be used, right?
> 
> (2 LSBs)

Yep, that's the idea!

> 
> except, small issue: endian-ness looks like it will be an issue.
> 
> in main_stage.py the bit-order is reversed using [31-BI]
> 
>         # The bit of CR selected by BI
>         cr_bit = Signal(reset_less=True)
>         comb += cr_bit.eq((self.i.cr & (1<<(31-BI))) != 0)
> 
> if we are to reduce self.i.cr (BranchInputData.cr) to 4 bits,
> should that not be
>         comb += cr_bit.eq((self.i.cr & (1<<(3-BI))) != 0)
> 
> but also, back in power_decoder2.py, for DecodeCRIn, what about here?
> 
>             with m.Case(CRInSel.BI):
>                 comb += self.cr_bitfield.data.eq(self.dec.BI[2:5])
>                 comb += self.cr_bitfield.ok.eq(1)

I think the register file should be designed to address the 8 crs in the
correct bit order. If I ask for cr0, I should get cr0, whether cr0 comes from
the 4 lsbs of the full register, or the 4 msbs.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 329] coriolis2 experiment layout for Dependency Matrices
From: bugzilla-daemon @ 2020-05-22 11:13 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-329-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=329

Jean-Paul.Chaput@lip6.fr changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |Jean-Paul.Chaput@lip6.fr

--- Comment #6 from Jean-Paul.Chaput@lip6.fr ---
(In reply to Luke Kenneth Casson Leighton from comment #5)
> i just also added a second one to experiment8 as an illustration, it is an
> FU-Regs Matrix with the following parameters:
> 
> * Number of Regs:                          4 (to keep it small as a demo)
> * Number of Function Units:                3 (likewise)
> * Number of Regfile Read ports protected:  2
> * Number of Regfile Write ports protected: 2
> 
> these numbers can and will vary.  we have *four* Register Files to
> protect with these Matrices.  five when we have FP support.

Hello Luke,

I'm looking closely to the examples but I still have problem understanding the
matrix
nature of the design. As a first I would like to concentrate on the FU-FU
matrix, which,
if I understand well, manage the read/write dependencies between FUs and
generate the
Go_Read & Go_Write signals towards the CU (and some other signals).

There is two "level" of matrixes:

1. The architectural level (that is close to what you do) and the one I cannot
clearly
   guess. With 3 FU, is there a 3x3 matrix or 3 FU blocks only, and in the
later case,
   it may not be a matrix but just a row or a column.
     But maybe I make confusion between FU and the dependency matrix of the
FUs.

2. The layout (cell level) into which the cells of *one* FU (or whatever
sub-block)
   are also arrayed in a matrix. As we may not put all the cells of a block in
just
   one row.

So would it be possible to send examples where one block of the matrix (in the
sense of 1.) is clearly identified (best would be that it is put in a
sub-block) ?

Or, if it is really inconvenient due to the way the design is described at
nMigne level,
list me what I/O signals (which bit of vectors) are specific to one element of
the
matrix ?

A slow learner.

PS: I still not completely understand the color coding of the scoreboard
schematic.
    Is the size and position of the little blue/yellow/green squares inside the
red one
    significant?

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 313] Create Branch Pipeline for POWER9
From: bugzilla-daemon @ 2020-05-22  8:44 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-313-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=313

--- Comment #32 from Luke Kenneth Casson Leighton <lkcl@lkcl.net> ---
(In reply to Luke Kenneth Casson Leighton from comment #31)

> the idea is to use 3 bits of BI to look up CR00 to 7

(3 MSBs)

> then in OP_BC look up the remaining 2 bits of BI to select which bit of CRn
> is to be used, right?

(2 LSBs)

except, small issue: endian-ness looks like it will be an issue.

in main_stage.py the bit-order is reversed using [31-BI]

        # The bit of CR selected by BI
        cr_bit = Signal(reset_less=True)
        comb += cr_bit.eq((self.i.cr & (1<<(31-BI))) != 0)

if we are to reduce self.i.cr (BranchInputData.cr) to 4 bits,
should that not be
        comb += cr_bit.eq((self.i.cr & (1<<(3-BI))) != 0)

but also, back in power_decoder2.py, for DecodeCRIn, what about here?

            with m.Case(CRInSel.BI):
                comb += self.cr_bitfield.data.eq(self.dec.BI[2:5])
                comb += self.cr_bitfield.ok.eq(1)

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 313] Create Branch Pipeline for POWER9
From: bugzilla-daemon @ 2020-05-22  2:39 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-313-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=313

--- Comment #31 from Luke Kenneth Casson Leighton <lkcl@lkcl.net> ---
https://git.libre-soc.org/?p=soc.git;a=blob;f=src/soc/decoder/power_decoder2.py;h=dbd87f967255f97bbec0b47a2b295780d6381033;hb=e46a1253d05ea47b9e62714ed50bcec6a7530d0f#l299

is that supposed to be a full 32 bit ranged lookup?

for branch, the full 32 bit CR is needed and BI looks up ...

oh i see.

the idea is to use 3 bits of BI to look up CR00 to 7

then in OP_BC look up the remaining 2 bits of BI to select which bit of CRn is
to be used, right?

that's neat because different branches ysing different CRs would not block on
the CR regfile.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 316] bperm TODO
From: bugzilla-daemon @ 2020-05-22  1:20 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-316-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=316

--- Comment #92 from Luke Kenneth Casson Leighton <lkcl@lkcl.net> ---
Big endianess: LSB starts at top numbered wire, MSB is in wire 0.

little: LSB is in wire 0.

to access 64 bit in BE you do this
x[63-index]
not
x[index]

to access 32 bit in BE you do this:
x[31-index]

so somewhere, that is what is needed.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

* [libre-riscv-dev] [Bug 336] ALU CompUnit needs to recognise that RA (src1) can be zero
From: bugzilla-daemon @ 2020-05-22  1:11 UTC (permalink / raw)
  To: libre-riscv-dev
In-Reply-To: <bug-336-13@https.bugs.libre-soc.org/>

https://bugs.libre-soc.org/show_bug.cgi?id=336

--- Comment #4 from Cesar Strauss <cestrauss@gmail.com> ---
(In reply to Luke Kenneth Casson Leighton from comment #3)
> (In reply to Cesar Strauss from comment #2)
> > Dear Luke,
> > 
> > Please do not bother drawing a gate level diagram for the FSM. Your
> > description is enough.
> 
> we need one for the documentation, which is an extremely important aspect of
> this project.

I agree, documentation is essencial.

But I argue that a diagram that shows too much detail, and goes all the way to
gate level, is more like source code than documentation.

> plus i find it very difficult to think of timing related designs without a
> gate level drawing.
> 
> as in i literally can't write these FSMs without one (!)

Sure, I understand. It's just practice, and realizing the convenience.

At the start, I used to input all my FPGA designs with a schematics editor. The
FPGA library actually had blocks for many of the 74XX logic family parts.

Then, as I learned about VHDL, I started translating some of my previous
designs to it.

Eventually, I got so used to it, that I started writing VHDL directly. It's so
much more compact, so less tangled wires, so less time spent arranging the
symbols around the page.

Lastly, I learned about Verilog, and switched to it for its simplicity.

> > For the dataflow (registers, ALU, muxes), yes, a diagram is useful, but do
> > represent the whole FSM as an empty box.
> > 
> > I find that I can better design an FSM by starting from a behavioral
> > description,
> 
> then comment 1 should do the trick?

Yes, it's all I need.

Regards,

Cesar

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
libre-riscv-dev mailing list
libre-riscv-dev@lists.libre-riscv.org
http://lists.libre-riscv.org/mailman/listinfo/libre-riscv-dev

^ permalink raw reply

page:   latest

Libre RISC-V Mailing list Archives (accessible via public-inbox)

Archives are clonable: git clone --mirror https://inbox.libre-soc.org/libre-riscv-dev

Example config snippet for mirrors


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git