From 869c7d3d325f23ce0202baefb53d2c87cc4d5ca2 Mon Sep 17 00:00:00 2001 From: Denis Drakhnia Date: Thu, 15 Feb 2024 08:43:02 +0200 Subject: [PATCH] asm/v7: add qpack* tests --- tests/asm/meson.build | 3 +++ tests/asm/v7/qpack-1.S | 51 ++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 54 insertions(+) create mode 100644 tests/asm/v7/qpack-1.S diff --git a/tests/asm/meson.build b/tests/asm/meson.build index 69d1fd7..3ad0d27 100644 --- a/tests/asm/meson.build +++ b/tests/asm/meson.build @@ -223,6 +223,9 @@ asm_tests = { 'stmqp-page-3': { 'src': 'stmqp-page-1', 'c_args': ['-DMIN_VER=6'] }, 'stmqp-page-4': { 'src': 'stmqp-page-2', 'c_args': ['-DMIN_VER=6'] }, }, + 'v7': { + 'qpack-1': {}, + }, } foreach suite, tests : asm_tests diff --git a/tests/asm/v7/qpack-1.S b/tests/asm/v7/qpack-1.S new file mode 100644 index 0000000..5cd5610 --- /dev/null +++ b/tests/asm/v7/qpack-1.S @@ -0,0 +1,51 @@ +#include "test_start.S" + + setwd wsz=4, nfx=1 + { + addd,0 0, 0x0706050403020100, %g16 + addd,1 0, 0x0f0e0d0c0b0a0908, %g17 + } + { + addd,0 0, 0x7060504030201000, %g18 + addd,1 0, 0xf0e0d0c0b0a09080, %g19 + } + { + qppackdl,0 %g17, %g16, %g16 + qppackdl,1 %g19, %g18, %g17 + } + { + qpackhbss,0 %g16, %g17, %r0 + qpackhbus,1 %g16, %g17, %r1 + qpackwhss,3 %g16, %g17, %r2 + qpackwhus,4 %g16, %g17, %r3 + } + { + qpacksshb,1 %g16, %g17, %r4 + qpackushb,4 %g16, %g17, %r5 + } + { + qpacksswh,1 %g16, %g17, %r6 + qpackuswh,4 %g16, %g17, %r7 + } + assert_eq_i64(%r0, %r4) + assert_eq_i64(%r1, %r5) + assert_eq_i64(%r2, %r6) + assert_eq_i64(%r3, %r7) + { + qpswitchd,0 %r0, %r0 + qpswitchd,1 %r1, %r1 + qpswitchd,3 %r2, %r2 + qpswitchd,4 %r3, %r3 + } + { + qpswitchd,0 %r4, %r4 + qpswitchd,1 %r5, %r5 + qpswitchd,3 %r6, %r6 + qpswitchd,4 %r7, %r7 + } + assert_eq_i64(%r0, %r4) + assert_eq_i64(%r1, %r5) + assert_eq_i64(%r2, %r6) + assert_eq_i64(%r3, %r7) + +#include "test_end.S"