qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: =?gb18030?B?TGlibyBaaG91?= <zhlb29@foxmail.com>
To: =?gb18030?B?QWxla3NhbmRhciBNYXJrb3ZpYw==?= <aleksandar.m.mail@gmail.com>
Cc: =?gb18030?B?cWVtdS1kZXZlbA==?= <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] QEMU as ISS (Instruction Set Simulator)
Date: Wed, 28 Aug 2019 11:54:37 +0800	[thread overview]
Message-ID: <tencent_1D2ACC9711B86DEA5633A4F0@qq.com> (raw)
In-Reply-To: <CAL1e-=gtL6AxsRYPTO5bztH_F-gJDXixEEif3QRKQYo7d4XcUA@mail.gmail.com>

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="gb18030", Size: 3505 bytes --]

Hi Aleksandar,


Thank you for the link to Loongson2F documentation. It has been very useful:)


I have spent several days immersing myself in the source code, now I think I have a more solid understanding about it. Just like Loongson Multimedia Instructions, I need to implement some sort of complex vector instructions, and I need to write some helper functions (e.g. my_helper.c).


The QEMU wiki website has very thorough explanation on TCG, but I haven't found any explanation on the port-specific helpers. Is there any documentation on how the helper functions are generated? I think now I *might* know how to write a working helper function, but I just don't know how it works.


Cheers,
Libo









------------------ Original message ------------------
From: "Aleksandar Markovic"; 
Sendtime: Thursday, Aug 22, 2019 6:53 PM
To: "Libo Zhou"; 
Cc: "qemu-devel"; 
Subject: Re: [Qemu-devel] QEMU as ISS (Instruction Set Simulator)



On Thu, Aug 22, 2019 at 12:24 PM Á¢ <zhlb29@foxmail.com> wrote:

> Hi Aleksandar,
>
> Thank you very much for your patient explanation in the previous post. And
> thank you for checking.
> Your and Peter's replies in the previous post certainly helped a lot. I am
> now looking at a git commit 7 years ago (
> bd277fa1966bc400f1b411f868f39125cda0c403), it was a Loongson Multimedia
> Instruction implementation done my Richard Henderson.
>

Cool, that commit is a very good staring point - it is definitely not too
simple, and it is not too complex either. And you can discover several
different concepts in the process of exploring the change.

Documentation on instruction set extension related to the commit (found by
Google):
https://files.somniafabularum.com/loongson/docs/Loongson2FUserGuide.pdf

Be persistent, take your time, study the details and handling of individual
instructions, and, of course, let us know if you encounter some major
obstacles or thorny dilemmas.

Yours,
Aleksandar


> I think what he did is exactly what I want to do now. I got a vague view
> of the big picture, but I need more time to figure out the details. I will
> certainly ask more questions about this later, but before that I need to
> look at some other parts of the source code:) Again thank you for checking!
>
> Cheers,
> Libo
>
>
> ------------------ Original message ------------------
> *From:* "Aleksandar Markovic";
> *Sendtime:* Thursday, Aug 22, 2019 4:23 PM
> *To:* "Á¢";
> *Cc:* "qemu-devel";
> *Subject:* Re: [Qemu-devel] QEMU as ISS (Instruction Set Simulator)
>
> On Tue, Aug 20, 2019 at 12:12 PM Á¢ <zhlb29@foxmail.com> wrote:
>
> > I am working on a project that requires me to modify the ISA of the MIPS
> > target.
>
>
> L.,
>
> How is it going?
>
> Aleksandar
>
>
>
> > I have been staring at the source code for about a week, but found it
> > really difficult due to me being a young rookie and the sparse comments.
> > Specifically, I need to extend MIPS, by adding some new instructions and
> > new CPU registers to the current architecture, and that sounds really
> easy.
> > I think the place for me to look at should be at the directory
> > ${qemu_root}/target/mips/. With a MIPS Instruction Set Manual Release 6
> > handy, I have difficulty finding the source code where the ISA resides.
> Is
> > it in op_helper.c? Or translate.c? Any guidance would be really
> > appreciated. Thank you very much in advance.
> >
> >
> > Cheers,
> > L.
>

  reply	other threads:[~2019-08-28  3:55 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-20 10:11 [Qemu-devel] QEMU as ISS (Instruction Set Simulator) =?gb18030?B?waI=?=
2019-08-20 10:20 ` Peter Maydell
2019-08-20 10:42 ` Aleksandar Markovic
2019-08-22  8:23 ` Aleksandar Markovic
2019-08-22 10:24   ` =?gb18030?B?waI=?=
2019-08-22 10:53     ` Aleksandar Markovic
2019-08-28  3:54       ` =?gb18030?B?TGlibyBaaG91?= [this message]
2019-08-29 14:22         ` Aleksandar Markovic
2019-08-30  9:14 =?gb18030?B?TGlibyBaaG91?=
2019-09-03  7:07 ` Aleksandar Markovic
2019-09-04  3:23 Libo Zhou
2019-09-05 10:54 ` Aleksandar Markovic
2019-09-05 11:57   ` Libo Zhou
2019-09-05 12:58     ` Alex Bennée
     [not found]       ` <tencent_541F04AB1A100DF25C334D8C@qq.com>
2019-09-06  9:19         ` Alex Bennée
     [not found]           ` <tencent_479D109A5BEC536D64AE43BF@qq.com>
2019-09-10 12:10             ` Alex Bennée
2019-09-10 17:27             ` Aleksandar Markovic
2019-09-10 17:50               ` Aleksandar Markovic
2019-09-11  8:48                 ` Libo Zhou
2019-09-11 13:09                 ` Aleksandar Markovic
2019-09-12 10:28       ` Libo Zhou
2019-09-12 11:41         ` Alex Bennée
2019-09-18  4:08           ` Libo Zhou

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=tencent_1D2ACC9711B86DEA5633A4F0@qq.com \
    --to=zhlb29@foxmail.com \
    --cc=aleksandar.m.mail@gmail.com \
    --cc=qemu-devel@nongnu.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
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).