summaryrefslogtreecommitdiffstats
path: root/tests/default-integers
diff options
context:
space:
mode:
authorMattias Andrée <maandree@kth.se>2023-12-07 20:35:16 +0100
committerMattias Andrée <maandree@kth.se>2023-12-07 20:35:16 +0100
commit225f1408e03f2e66198f3da20c42a746e2729ab0 (patch)
treeebd6bd4b576c85159e852103ce21d4515484d853 /tests/default-integers
parentThird commit (diff)
downloadlibsyscalls-225f1408e03f2e66198f3da20c42a746e2729ab0.tar.gz
libsyscalls-225f1408e03f2e66198f3da20c42a746e2729ab0.tar.bz2
libsyscalls-225f1408e03f2e66198f3da20c42a746e2729ab0.tar.xz
Fourth commit
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to '')
-rw-r--r--tests/default-integers21
1 files changed, 21 insertions, 0 deletions
diff --git a/tests/default-integers b/tests/default-integers
new file mode 100644
index 0000000..12faa5a
--- /dev/null
+++ b/tests/default-integers
@@ -0,0 +1,21 @@
+# -*- sh -*-
+# See LICENSE file for copyright and license details.
+
+for arch in $(getnamelist ARCH); do
+ archn=$(getnum ARCH $arch)
+ if ! issupported $os $arch; then
+ continue
+ fi
+
+ if test $arch = M68K; then
+ maxalign=16
+ elif test $arch = I386; then
+ maxalign=32
+ else
+ maxalign=64
+ fi
+
+ for width in 8 16 32 64; do
+ test "$(get-integer-alignment.tu $osn $archn $width $os $arch)" = $(min $maxalign $width)
+ done
+done