All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chen Gang S <gang.chen@sunrus.com.cn>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: "walt@tilera.com" <walt@tilera.com>,
	Chris Metcalf <cmetcalf@ezchip.com>,
	Riku Voipio <riku.voipio@iki.fi>,
	qemu-devel <qemu-devel@nongnu.org>,
	"rth@twiddle.net" <rth@twiddle.net>
Subject: Re: [Qemu-devel] [PATCH 1/5] target-tile: Firstly add to qemu with minimized features
Date: Sat, 14 Feb 2015 11:08:46 +0800	[thread overview]
Message-ID: <54DEBC3E.4000805@sunrus.com.cn> (raw)
In-Reply-To: <CAFEAcA-FwO_k=eAk5WGJb+vs62_sXAU=q9uEmXGYry75VAtw3w@mail.gmail.com>

On 2/14/15 08:26, Peter Maydell wrote:
> On 13 February 2015 at 23:50, Chen Gang S <gang.chen@sunrus.com.cn> wrote:
>>
>> On 2/13/15 05:15, Chen Gang S wrote:
>>> It almost likes a template for adding an architecture target.
>>>
>>> Signed-off-by: Chen Gang <gang.chen.5i5j@gmail.com>
>>> ---
>>>  configure                             |   7 ++
>>>  default-configs/tilegx-linux-user.mak |   1 +
>>>  target-tile/Makefile.objs             |   1 +
>>>  target-tile/cpu-qom.h                 |  72 +++++++++++++++
>>>  target-tile/cpu.c                     | 159 ++++++++++++++++++++++++++++++++++
>>>  target-tile/cpu.h                     |  84 ++++++++++++++++++
>>>  target-tile/helper.h                  |   0
>>>  target-tile/translate.c               |  54 ++++++++++++
>>>  8 files changed, 378 insertions(+)
>>>  create mode 100644 default-configs/tilegx-linux-user.mak
>>>  create mode 100644 target-tile/Makefile.objs
>>>  create mode 100644 target-tile/cpu-qom.h
>>>  create mode 100644 target-tile/cpu.c
>>>  create mode 100644 target-tile/cpu.h
>>>  create mode 100644 target-tile/helper.h
>>>  create mode 100644 target-tile/translate.c
>>>
>>> diff --git a/configure b/configure
>>> index 7ba4bcb..ffb4d56 100755
>>> --- a/configure
>>> +++ b/configure
>>> @@ -5191,6 +5191,9 @@ case "$target_name" in
>>>    s390x)
>>>      gdb_xml_files="s390x-core64.xml s390-acr.xml s390-fpr.xml"
>>>    ;;
>>> +  tilegx)
>>> +    TARGET_ARCH=tile
>>> +  ;;
>>
>> Oh, it needs to use "TARGET_ARCH=tilegx" instead of "TARGET_ARCH=tile",
>> or can not put "CONFIG_TILE_DIS=y" to config-all-disas.mak, below (when
>> I am adding "disas/tilegx.c", I meet it).
> 
> You need to make up your mind about what your architecture
> is called: is it "tile" or "tilegx"? Be consistent...
> 

Oh, after think of, for me, I shall follow the other architectures has
done (e.g. i386).

 - Still use target-tile directory, since 'tile' is the architecture
   name.

 - 'tilegx' is one kind of cpu of tile, so I need consider about it just
   like another architectures have done (e.g. i386).



>>
>>>    unicore32)
>>>    ;;
>>>    xtensa|xtensaeb)
>>> @@ -5363,6 +5366,10 @@ for i in $ARCH $TARGET_BASE_ARCH ; do
>>>      echo "CONFIG_SPARC_DIS=y"  >> $config_target_mak
>>>      echo "CONFIG_SPARC_DIS=y"  >> config-all-disas.mak
>>>    ;;
>>> +  tilegx*)
>>> +    echo "CONFIG_TILE_DIS=y"  >> $config_target_mak
>>> +    echo "CONFIG_TILE_DIS=y"  >> config-all-disas.mak
>>> +  ;;
> 
> You should only add this bit to configure in the patchset
> where you add a Tile disassembler.
> 

Yeah, I shall add disassembler firstly, before generate tcg code:

 - binutils tilegx disassembler is easy to be integrated into qemu.

 - I shall reuse part of the tilegx disassembler code for generating tcg
   code.

 - For me, dumping disassemble code in qemu is much helpful for testing.

At present, I have integrated binutils tilegx disassembler into qemu, it
is passed building, and I shall give a test for it tonight. If no any
issues, I plan to send related patch too.

Welcome any ideas, suggestions, and completions.

Thanks.
-- 
Chen Gang

Open, share, and attitude like air, water, and life which God blessed

  parent reply	other threads:[~2015-02-14  3:01 UTC|newest]

Thread overview: 40+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-02-12 21:14 [Qemu-devel] [PATCH 0/5] tile: Can load elf64 tilegx binary successfully for linux-user Chen Gang S
2015-02-12 21:15 ` [Qemu-devel] [PATCH 1/5] target-tile: Firstly add to qemu with minimized features Chen Gang S
2015-02-13 23:50   ` Chen Gang S
2015-02-14  0:26     ` Peter Maydell
2015-02-14  2:40       ` Richard Henderson
2015-02-14  3:14         ` Chen Gang S
2015-02-14  3:08       ` Chen Gang S [this message]
2015-02-14  3:08         ` Peter Maydell
2015-02-14  3:37         ` Chris Metcalf
2015-02-14  5:47           ` Peter Maydell
2015-02-14 15:53             ` Chen Gang S
2015-02-16  3:40               ` Chen Gang S
2015-02-16 14:44                 ` Chen Gang S
2015-02-16 15:00                   ` Chris Metcalf
2015-02-16 23:40                     ` Chen Gang S
2015-02-16 15:24                   ` Max Filippov
2015-02-16 23:08                     ` Chen Gang S
2015-02-16 23:46                       ` Peter Maydell
2015-02-17  0:11                         ` Chris Metcalf
2015-02-17  2:48                           ` Chen Gang S
2015-02-17  3:11                             ` Chen Gang S
2015-02-17  3:18                               ` Chen Gang S
2015-02-17  0:29                 ` Chris Metcalf
2015-02-17  2:03                   ` Chen Gang S
2015-04-27 21:12                   ` [Qemu-devel] [Consult] About SPRs information Chen Gang
2015-04-27 22:04                     ` Richard Henderson
2015-04-28 20:19                       ` Chen Gang
2015-04-28 21:32                         ` Chen Gang
2015-04-28 21:43                           ` Peter Maydell
2015-04-29 13:32                             ` Chen Gang
2015-05-02  2:42                               ` Chen Gang
2015-05-02  4:09                                 ` Chen Gang
2015-05-03 14:30                                   ` Chen Gang
2015-05-07 21:05                                     ` Chen Gang
2015-05-08  3:14                                       ` Peter Maydell
2015-05-08 23:18                                         ` Chen Gang
2015-02-14 15:43           ` [Qemu-devel] [PATCH 1/5] target-tile: Firstly add to qemu with minimized features Chen Gang S
2015-02-12 21:17 ` [Qemu-devel] [PATCH 3/5] linux-user: tile: Add target features support within qemu Chen Gang S
2015-02-12 21:18 ` [Qemu-devel] [PATCH 4/5] linux-user: Support tile architecture in syscall Chen Gang S
2015-02-12 21:20 ` [Qemu-devel] [PATCH 5/5] linux-user: Support tile architecture in linux-user Chen Gang S

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=54DEBC3E.4000805@sunrus.com.cn \
    --to=gang.chen@sunrus.com.cn \
    --cc=cmetcalf@ezchip.com \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-devel@nongnu.org \
    --cc=riku.voipio@iki.fi \
    --cc=rth@twiddle.net \
    --cc=walt@tilera.com \
    /path/to/YOUR_REPLY

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

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.