]> git.rm.cloudns.org Git - xonotic/gmqcc.git/commitdiff
test for vec/float
authorWolfgang Bumiller <blub@speed.at>
Sun, 13 Jan 2013 19:49:27 +0000 (20:49 +0100)
committerWolfgang Bumiller <blub@speed.at>
Sun, 13 Jan 2013 19:49:27 +0000 (20:49 +0100)
tests/vec_ops.qc [new file with mode: 0644]
tests/vec_ops.tmpl [new file with mode: 0644]

diff --git a/tests/vec_ops.qc b/tests/vec_ops.qc
new file mode 100644 (file)
index 0000000..a5c80c9
--- /dev/null
@@ -0,0 +1,10 @@
+void print(string...) = #1;
+string vtos(vector)   = #5;
+
+void main(vector v) {
+    print(vtos(v), "\n");
+    v /= 2;
+    print(vtos(v), "\n");
+    print(vtos(v / 2), "\n");
+    print(vtos(v), "\n");
+}
diff --git a/tests/vec_ops.tmpl b/tests/vec_ops.tmpl
new file mode 100644 (file)
index 0000000..39e2750
--- /dev/null
@@ -0,0 +1,9 @@
+I: vec_ops.qc
+D: some additional vector operations
+T: -execute
+C: -std=fteqcc
+E: -vector '8 16 32'
+M: '8 16 32'
+M: '4 8 16'
+M: '2 4 8'
+M: '4 8 16'