Skip to contentSkip to conversation

s390x: Add tests for execute-type instructions

PATCH Superseded Nina Schoetterl-Glausch 3 participants 4 messages Feb 22, 2023 – Feb 23, 2023

Subsystems (2)

v1 of 6 Superseded Latest is v6 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 s390x: Add tests for execute-type instructions

Test the instruction address used by targets of an execute instruction. When the target instruction calculates a relative address, the result is relative to the target instruction, not the execute instruction.

---

TCG does the address calculation relative to the execute instruction.

 s390x/Makefile |  1 +
 s390x/ex.c     | 92 ++++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 93 insertions(+)
 create mode 100644 s390x/ex.c
s390x/Makefile +1 -0
index 97a61611..6cf8018b 100644
@@ -39,6 +39,7 @@ tests += $(TEST_DIR)/panic-loop-extint.elf
 tests += $(TEST_DIR)/panic-loop-pgm.elf
 tests += $(TEST_DIR)/migration-sck.elf
 tests += $(TEST_DIR)/exittime.elf
+tests += $(TEST_DIR)/ex.elf
 
 pv-tests += $(TEST_DIR)/pv-diags.elf
 
s390x/ex.c new file +92 -0

92 lines not on this page · raw message

base-commit: e3c5c3ef2524c58023073c0fadde2e8ae3c04ec6

Signature · 1 line
2.36.1
Reviewed-by on v1 1/1
#1 lore raw

Quoting Nina Schoetterl-Glausch (2023-02-22 12:47:42)

Quoted 5 lines

Test the instruction address used by targets of an execute instruction. When the target instruction calculates a relative address, the result is relative to the target instruction, not the execute instruction.

[...]

s390x/Makefile tests += $(TEST_DIR)/panic-loop-extint.elf · line 42

Quoted 9 lines
s390x/Makefile +1 -0
index 97a61611..6cf8018b 100644
@@ -39,6 +39,7 @@ tests += $(TEST_DIR)/panic-loop-extint.elf
 tests += $(TEST_DIR)/panic-loop-pgm.elf
 tests += $(TEST_DIR)/migration-sck.elf
 tests += $(TEST_DIR)/exittime.elf
+tests += $(TEST_DIR)/ex.elf

You didn't add your new test to unittests.cfg, is this intentional?

Otherwise:

#2 lore raw
Quoted 7 lines · Nico Boehr

Quoting Nina Schoetterl-Glausch (2023-02-22 12:47:42)

Quoted 5 lines

Test the instruction address used by targets of an execute instruction. When the target instruction calculates a relative address, the result is relative to the target instruction, not the execute instruction.

[...]

Quoted 11 lines

s390x/Makefile tests += $(TEST_DIR)/panic-loop-extint.elf · line 42

Quoted 9 lines
s390x/Makefile +1 -0
index 97a61611..6cf8018b 100644
@@ -39,6 +39,7 @@ tests += $(TEST_DIR)/panic-loop-extint.elf
 tests += $(TEST_DIR)/panic-loop-pgm.elf
 tests += $(TEST_DIR)/migration-sck.elf
 tests += $(TEST_DIR)/exittime.elf
+tests += $(TEST_DIR)/ex.elf

You didn't add your new test to unittests.cfg, is this intentional?

Nope, I just forgot.

@Thomas, I guess I should also add it to s390x-kvm in .gitlab-ci.yml, since the test passes on KVM?

Quoted 4 lines

Otherwise:

Thanks!

#3 lore raw
Quoted 20 lines · Nina Schoetterl-Glausch
Quoted 7 lines · Nico Boehr

Quoting Nina Schoetterl-Glausch (2023-02-22 12:47:42)

Quoted 5 lines

Test the instruction address used by targets of an execute instruction. When the target instruction calculates a relative address, the result is relative to the target instruction, not the execute instruction.

[...]

Quoted 11 lines

s390x/Makefile tests += $(TEST_DIR)/panic-loop-extint.elf · line 42

Quoted 9 lines
s390x/Makefile +1 -0
index 97a61611..6cf8018b 100644
@@ -39,6 +39,7 @@ tests += $(TEST_DIR)/panic-loop-extint.elf
  tests += $(TEST_DIR)/panic-loop-pgm.elf
  tests += $(TEST_DIR)/migration-sck.elf
  tests += $(TEST_DIR)/exittime.elf
+tests += $(TEST_DIR)/ex.elf

You didn't add your new test to unittests.cfg, is this intentional?

Quoted 4 lines

Nope, I just forgot.

@Thomas, I guess I should also add it to s390x-kvm in .gitlab-ci.yml, since the test passes on KVM?

Yes, please (unless your test requires the latest and greatest shiny upstream kernel - we don't have that on the machine available yet).

Thomas