All of lore.kernel.org
 help / color / mirror / Atom feed
From: Aleksandar Markovic <aleksandar.markovic@rt-rk.com>
To: qemu-devel@nongnu.org
Cc: peter.maydell@linaro.org, amarkovic@wavecomp.com
Subject: [Qemu-devel] [PULL v3 28/44] disas: nanoMIPS: Comment the decoder of 'gpr3.src.store' gpr encoding type
Date: Thu,  3 Jan 2019 18:08:01 +0100	[thread overview]
Message-ID: <1546535297-11040-29-git-send-email-aleksandar.markovic@rt-rk.com> (raw)
In-Reply-To: <1546535297-11040-1-git-send-email-aleksandar.markovic@rt-rk.com>

From: Aleksandar Markovic <amarkovic@wavecomp.com>

Comment the decoder of 'gpr3.src.store' gpr encoding type in nanoMIPS
disassembler.

Reviewed-by: Aleksandar Rikalo <arikalo@wavecomp.com>
Signed-off-by: Aleksandar Markovic <amarkovic@wavecomp.com>
---
 disas/nanomips.cpp | 32 ++++++++++++++++++++++++++++++++
 1 file changed, 32 insertions(+)

diff --git a/disas/nanomips.cpp b/disas/nanomips.cpp
index 7c56162..1c313f3 100644
--- a/disas/nanomips.cpp
+++ b/disas/nanomips.cpp
@@ -349,6 +349,38 @@ uint64 NMD::decode_gpr_gpr3(uint64 d)
 }
 
 
+/*
+ * NMD::decode_gpr_gpr3_src_store() - decoder for 'gpr3.src.store' gpr encoding
+ *     type
+ *
+ *   Map a 3-bit code to the 5-bit register space according to this pattern:
+ *
+ *                            7 6 5 4 3 2 1 0
+ *                            | | | | | | | |
+ *                            | | | | | | | └-----------------------┐
+ *                            | | | └-----------------------┐       |
+ *                            | | └-----------------------┐ |       |
+ *                            | └-----------------------┐ | |       |
+ *                            └-----------------------┐ | | |       |
+ *                                    | | |           | | | |       |
+ *                            ┌-------┘ | |           | | | |       |
+ *                            | ┌-------┘ |           | | | |       |
+ *                            | | ┌-------┘           | | | |       |
+ *                            | | |                   | | | |       |
+ *                            | | |                   | | | |       |
+ *    1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0
+ *      3                   2                   1                   0
+ *
+ *   This pattern is the same one used for 'gpr3' gpr encoding type, except for
+ * the input value 0, that is mapped to the output value 0 instead of 16.
+ *
+ *   Used in handling following instructions:
+ *
+ *     - SB[16]
+ *     - SH[16]
+ *     - SW[16]
+ *     - SW[GP16]
+ */
 uint64 NMD::decode_gpr_gpr3_src_store(uint64 d)
 {
     static uint64 register_list[] = {  0, 17, 18, 19,  4,  5,  6,  7 };
-- 
2.7.4

  parent reply	other threads:[~2019-01-03 17:08 UTC|newest]

Thread overview: 48+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-03 17:07 [Qemu-devel] [PULL v3 00/44] MIPS pull request for December 2018 - v3 Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 01/44] MAINTAINERS: target/mips: Add MIPS files under default-configs directory Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 02/44] MAINTAINERS: target/mips: Add filter for mips in email subjects Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 03/44] MAINTAINERS: target/mips: Reorder items alphabetically Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 04/44] MAINTAINERS: Add Aleksandar Rikalo as a reviewer for MIPS content Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 05/44] atomics: Set ATOMIC_REG_SIZE=8 for MIPS n32 Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 06/44] target/mips: MXU: Add missing opcodes/decoding for LX* instructions Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 07/44] target/mips: MXU: Add generic naming for optn2 constants Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 08/44] target/mips: MXU: Improve the comment containing MXU overview Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 09/44] target/mips: MXU: Add handlers for logic instructions Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 10/44] target/mips: MXU: Add handlers for max/min instructions Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 11/44] target/mips: MXU: Add handler for an align instruction Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 12/44] target/mips: Support R5900 three-operand MADD and MADDU instructions Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 13/44] target/mips: Support R5900 three-operand MADD1 and MADDU1 instructions Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 14/44] disas: nanoMIPS: Fix types and format strings Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 15/44] disas: nanoMIPS: Fix preamble text in nanomips.* files Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 16/44] disas: nanoMIPS: Remove functions that are not used Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 17/44] disas: nanoMIPS: Fix a function misnomer Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 18/44] disas: nanoMIPS: Fix order of some invocations Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 19/44] disas: nanoMIPS: Name some functions in a more descriptive way Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 20/44] disas: nanoMIPS: Fix an FP-related misnomer 1 Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 21/44] disas: nanoMIPS: Fix an FP-related misnomer 2 Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 22/44] disas: nanoMIPS: Fix an FP-related misnomer 3 Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 23/44] disas: nanoMIPS: Name more functions in a more descriptive way Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 24/44] disas: nanoMIPS: Fix order of more invocations Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 25/44] disas: nanoMIPS: Rename the decoder of 'gpr3' gpr encoding type Aleksandar Markovic
2019-01-03 17:07 ` [Qemu-devel] [PULL v3 26/44] disas: nanoMIPS: Comment " Aleksandar Markovic
2019-01-03 17:08 ` [Qemu-devel] [PULL v3 27/44] disas: nanoMIPS: Rename the decoder of 'gpr3.src.store' " Aleksandar Markovic
2019-01-03 17:08 ` Aleksandar Markovic [this message]
2019-01-03 17:08 ` [Qemu-devel] [PULL v3 29/44] disas: nanoMIPS: Rename the decoder of 'gpr4' " Aleksandar Markovic
2019-01-03 17:08 ` [Qemu-devel] [PULL v3 30/44] disas: nanoMIPS: Comment " Aleksandar Markovic
2019-01-03 17:08 ` [Qemu-devel] [PULL v3 31/44] disas: nanoMIPS: Rename the decoder of 'gpr4.zero' " Aleksandar Markovic
2019-01-03 17:08 ` [Qemu-devel] [PULL v3 32/44] disas: nanoMIPS: Comment " Aleksandar Markovic
2019-01-03 17:08 ` [Qemu-devel] [PULL v3 33/44] disas: nanoMIPS: Rename the decoder of 'gpr2.reg1' " Aleksandar Markovic
2019-01-03 17:08 ` [Qemu-devel] [PULL v3 34/44] disas: nanoMIPS: Comment " Aleksandar Markovic
2019-01-03 17:08 ` [Qemu-devel] [PULL v3 35/44] disas: nanoMIPS: Rename the decoder of 'gpr2.reg2' " Aleksandar Markovic
2019-01-03 17:08 ` [Qemu-devel] [PULL v3 36/44] disas: nanoMIPS: Comment " Aleksandar Markovic
2019-01-03 17:08 ` [Qemu-devel] [PULL v3 37/44] disas: nanoMIPS: Rename the decoder of 'gpr1' " Aleksandar Markovic
2019-01-03 17:08 ` [Qemu-devel] [PULL v3 38/44] disas: nanoMIPS: Comment " Aleksandar Markovic
2019-01-03 17:08 ` [Qemu-devel] [PULL v3 39/44] disas: nanoMIPS: Reorder declarations and definitions of gpr decoders Aleksandar Markovic
2019-01-03 17:08 ` [Qemu-devel] [PULL v3 40/44] disas: nanoMIPS: Add a note on documentation Aleksandar Markovic
2019-01-03 17:08 ` [Qemu-devel] [PULL v3 41/44] tests/tcg: mips: Test R5900 three-operand MADD Aleksandar Markovic
2019-01-03 17:08 ` [Qemu-devel] [PULL v3 42/44] tests/tcg: mips: Test R5900 three-operand MADD1 Aleksandar Markovic
2019-01-03 17:08 ` [Qemu-devel] [PULL v3 43/44] tests/tcg: mips: Test R5900 three-operand MADDU Aleksandar Markovic
2019-01-03 17:08 ` [Qemu-devel] [PULL v3 44/44] tests/tcg: mips: Test R5900 three-operand MADDU1 Aleksandar Markovic
2019-01-04 13:22 ` [Qemu-devel] [PULL v3 00/44] MIPS pull request for December 2018 - v3 Peter Maydell
2019-01-04 17:41   ` Aleksandar Markovic
2019-01-04 18:21     ` Peter Maydell

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=1546535297-11040-29-git-send-email-aleksandar.markovic@rt-rk.com \
    --to=aleksandar.markovic@rt-rk.com \
    --cc=amarkovic@wavecomp.com \
    --cc=peter.maydell@linaro.org \
    --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 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.