[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] testsuite: Add tests to verify map op respects current IOS
From: |
Jose E. Marchesi |
Subject: |
Re: [PATCH] testsuite: Add tests to verify map op respects current IOS |
Date: |
Fri, 17 Sep 2021 16:27:10 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
Hi Mohammad.
> 2021-09-17 Mohammad-Reza Nabipoor <mnabipoor@gnu.org>
>
> * testsuite/poke.map/ass-map-21.pk: New test.
> * testsuite/poke.map/ass-map-22.pk: Likewise.
> * testsuite/Makefile.am (EXTRA_DIST): Add new tests.
OK for master and maint/poke-1 if applicable.
Thanks!
> ---
> ChangeLog | 6 ++++++
> testsuite/Makefile.am | 2 ++
> testsuite/poke.map/ass-map-21.pk | 13 +++++++++++++
> testsuite/poke.map/ass-map-22.pk | 17 +++++++++++++++++
> 4 files changed, 38 insertions(+)
> create mode 100644 testsuite/poke.map/ass-map-21.pk
> create mode 100644 testsuite/poke.map/ass-map-22.pk
>
> diff --git a/ChangeLog b/ChangeLog
> index 4158985c..54df07f4 100644
> --- a/ChangeLog
> +++ b/ChangeLog
> @@ -1,3 +1,9 @@
> +2021-09-17 Mohammad-Reza Nabipoor <mnabipoor@gnu.org>
> +
> + * testsuite/poke.map/ass-map-21.pk: New test.
> + * testsuite/poke.map/ass-map-22.pk: Likewise.
> + * testsuite/Makefile.am (EXTRA_DIST): Add new tests.
> +
> 2021-09-16 Mohammad-Reza Nabipoor <mnabipoor@gnu.org>
>
> * libpoke/pk-val.c: Include `assert.h`.
> diff --git a/testsuite/Makefile.am b/testsuite/Makefile.am
> index f2f4b3a9..3ec58723 100644
> --- a/testsuite/Makefile.am
> +++ b/testsuite/Makefile.am
> @@ -131,6 +131,8 @@ EXTRA_DIST = \
> poke.map/ass-map-18.pk \
> poke.map/ass-map-19.pk \
> poke.map/ass-map-20.pk \
> + poke.map/ass-map-21.pk \
> + poke.map/ass-map-22.pk \
> poke.map/ass-map-struct-int-1.pk \
> poke.map/func-map-1.pk \
> poke.map/func-map-2.pk \
> diff --git a/testsuite/poke.map/ass-map-21.pk
> b/testsuite/poke.map/ass-map-21.pk
> new file mode 100644
> index 00000000..e210b3dd
> --- /dev/null
> +++ b/testsuite/poke.map/ass-map-21.pk
> @@ -0,0 +1,13 @@
> +/* { dg-do run } */
> +/* { dg-data {c*} {0x70 0x6f 0x6b 0x65 0x00} } */
> +
> +/* { dg-command {string @ 0#B} } */
> +/* { dg-output "\"poke\"" } */
> +/* { dg-command {.mem foo} } */
> +/* { dg-command {string @ 0#B} } */
> +/* { dg-output "\n\"\"" } */
> +/* { dg-command {string @ 0#B = "POKE"} } */
> +/* { dg-command {string @ 0 : 0#B} } */
> +/* { dg-output "\n\"poke\"" } */
> +/* { dg-command {string @ 1 : 0#B} } */
> +/* { dg-output "\n\"POKE\"" } */
> diff --git a/testsuite/poke.map/ass-map-22.pk
> b/testsuite/poke.map/ass-map-22.pk
> new file mode 100644
> index 00000000..d667451c
> --- /dev/null
> +++ b/testsuite/poke.map/ass-map-22.pk
> @@ -0,0 +1,17 @@
> +/* { dg-do run } */
> +/* { dg-data {c*} {0x12 0x34 0x56 0x78} ass_map_22.data } */
> +
> +/* { dg-command {.set endian big} } */
> +/* { dg-command {.set obase 16} } */
> +/* { dg-command {.mem foo} } */
> +/* { dg-command {uint32 @ 0#B} } */
> +/* { dg-output "0x0U" } */
> +/* { dg-command {.file ass_map_22.data} } */
> +/* { dg-command {.mem bar} } */
> +/* { dg-command {uint32 @ 0#B = 0xabcdef00} } */
> +/* { dg-command {.ios #1} } */
> +/* { dg-command {uint32 @ 0#B} } */
> +/* { dg-output "\n0x12345678U" } */
> +/* { dg-command {.ios #0} } */
> +/* { dg-command {uint32 @ 0#B} } */
> +/* { dg-output "\n0x0U" } */