Libre RISC-V Mailing list Archives (accessible via public-inbox)
 help / color / Atom feed
From: bugzilla-daemon@libre-riscv.org
To: libre-riscv-dev@lists.libre-riscv.org
Subject: [libre-riscv-dev] [Bug 272] functions needed in POWER simulator which match 3.0B spec
Date: Mon, 30 Mar 2020 19:24:31 +0000
Message-ID: <bug-272-13-N7m9cXdEcp@http.bugs.libre-riscv.org/> (raw)
In-Reply-To: <bug-272-13@http.bugs.libre-riscv.org/>

http://bugs.libre-riscv.org/show_bug.cgi?id=272

--- Comment #2 from Luke Kenneth Casson Leighton <lkcl@lkcl.net> ---
(In reply to Michael Nolan from comment #1)
> Would this be in power_pseudo.py? Or the POC simulator I wrote?

in the simulator, as a base "convenience" class of some kind.

basically, right now, code like this (which is extswsli)

    n  <- sh[5] || sh[0:4]
    r  <- ROTL64(EXTS64(RS[32:63]), n)
    m  <- MASK(0, 63-n)
    RA <- r & m

currently gets turned into this:

    n  = sh[5] + sh[0:5] # these are lists so they get concatenated
    r  = ROTL64(EXTS64(RS[32:64]), n)
    m  = MASK(0, 63-n)
    RA = r & m

however what is *actually* needed is:

    n  = sh[5] + sh[0:5] # these are lists so they get concatenated
    r  = self.helperfns.ROTL64(self.helperfns.EXTS64(RS[32:64]), n)
    m  = self.helperfns.MASK(0, 63-n)
    RA = r & m

and some other small changes.

remember, the code that's being executed will be *in* the simulator.
it's only generated *by* the compiler (power_pseudo.py).

welcome to compilers, they're a bit of a mind-bender :)

-- 
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

  parent reply index

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-30 17:27 [libre-riscv-dev] [Bug 272] New: " bugzilla-daemon
2020-03-30 19:04 ` [libre-riscv-dev] [Bug 272] " bugzilla-daemon
2020-03-30 19:24 ` bugzilla-daemon [this message]
2020-03-31 12:57 ` bugzilla-daemon
2020-03-31 13:06 ` bugzilla-daemon
2020-03-31 14:24 ` bugzilla-daemon
2020-03-31 14:31 ` bugzilla-daemon
2020-03-31 18:35 ` bugzilla-daemon
2020-03-31 18:47 ` bugzilla-daemon
2020-03-31 20:06 ` bugzilla-daemon
2020-03-31 22:02 ` bugzilla-daemon
2020-03-31 23:07 ` bugzilla-daemon
2020-04-01 15:35 ` bugzilla-daemon
2020-04-01 18:40 ` bugzilla-daemon
2020-04-01 19:06 ` bugzilla-daemon
2020-04-01 21:55 ` bugzilla-daemon
2020-04-01 23:05 ` bugzilla-daemon
2020-04-01 23:44 ` bugzilla-daemon
2020-04-02 10:41 ` bugzilla-daemon
2020-04-05 18:37 ` bugzilla-daemon
     [not found] <bug-272-13@https.bugs.libre-soc.org/>
2020-04-27 20:25 ` bugzilla-daemon

Reply instructions:

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

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

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

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

  git send-email \
    --in-reply-to=bug-272-13-N7m9cXdEcp@http.bugs.libre-riscv.org/ \
    --to=bugzilla-daemon@libre-riscv.org \
    --cc=libre-riscv-dev@lists.libre-riscv.org \
    /path/to/YOUR_REPLY

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

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

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