This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[jit] Add missing tests to test-combination.c
- From: David Malcolm <dmalcolm at redhat dot com>
- To: jit at gcc dot gnu dot org, gcc-patches at gcc dot gnu dot org
- Cc: David Malcolm <dmalcolm at redhat dot com>
- Date: Tue, 18 Mar 2014 13:37:08 -0400
- Subject: [jit] Add missing tests to test-combination.c
- Authentication-results: sourceware.org; auth=none
Committed to branch dmalcolm/jit:
gcc/testsuite/
* jit.dg/test-combination.c: Add test-arrays.c and test-volatile.c.
Add comment about test-error-*.c. Remove comment about
test-failure.c, which was removed in
96b218c9a1d5f39fb649e02c0e77586b180e8516.
(create_code): Call into test-arrays.c and test-volatile.c.
(verify_code): Likewise.
---
gcc/testsuite/ChangeLog.jit | 9 +++++++++
gcc/testsuite/jit.dg/test-combination.c | 24 +++++++++++++++++++++---
2 files changed, 30 insertions(+), 3 deletions(-)
diff --git a/gcc/testsuite/ChangeLog.jit b/gcc/testsuite/ChangeLog.jit
index 1d8c11c..e07ba87 100644
--- a/gcc/testsuite/ChangeLog.jit
+++ b/gcc/testsuite/ChangeLog.jit
@@ -1,3 +1,12 @@
+2014-03-18 David Malcolm <dmalcolm@redhat.com>
+
+ * jit.dg/test-combination.c: Add test-arrays.c and test-volatile.c.
+ Add comment about test-error-*.c. Remove comment about
+ test-failure.c, which was removed in
+ 96b218c9a1d5f39fb649e02c0e77586b180e8516.
+ (create_code): Call into test-arrays.c and test-volatile.c.
+ (verify_code): Likewise.
+
2014-03-14 David Malcolm <dmalcolm@redhat.com>
* jit.dg/test-expressions.c (called_pointer_checking_function): New.
diff --git a/gcc/testsuite/jit.dg/test-combination.c b/gcc/testsuite/jit.dg/test-combination.c
index cd8a0f3..72b8602 100644
--- a/gcc/testsuite/jit.dg/test-combination.c
+++ b/gcc/testsuite/jit.dg/test-combination.c
@@ -14,6 +14,13 @@
#undef create_code
#undef verify_code
+/* test-arrays.c */
+#define create_code create_code_arrays
+#define verify_code verify_code_arrays
+#include "test-arrays.c"
+#undef create_code
+#undef verify_code
+
/* test-calling-external-function.c */
#define create_code create_code_calling_external_function
#define verify_code verify_code_calling_external_function
@@ -28,6 +35,9 @@
#undef create_code
#undef verify_code
+/* test-error-*.c: We don't use these test cases, since they deliberately
+ introduce errors, which we don't want here. */
+
/* test-expressions.c */
#define create_code create_code_expressions
#define verify_code verify_code_expressions
@@ -42,9 +52,6 @@
#undef create_code
#undef verify_code
-/* We don't use test-failure.c; we don't want its failure to affect our
- combined case. */
-
/* test-fibonacci.c */
#define create_code create_code_fibonacci
#define verify_code verify_code_fibonacci
@@ -115,6 +122,13 @@
#undef create_code
#undef verify_code
+/* test-volatile.c */
+#define create_code create_code_volatile
+#define verify_code verify_code_volatile
+#include "test-volatile.c"
+#undef create_code
+#undef verify_code
+
/* Now construct a test case from all the other test cases.
We undefine TEST_COMBINATION so that we can now include harness.h
@@ -127,6 +141,7 @@ void
create_code (gcc_jit_context *ctxt, void * user_data)
{
create_code_accessing_struct (ctxt, user_data);
+ create_code_arrays (ctxt, user_data);
create_code_calling_external_function (ctxt, user_data);
create_code_dot_product (ctxt, user_data);
create_code_expressions (ctxt, user_data);
@@ -139,12 +154,14 @@ create_code (gcc_jit_context *ctxt, void * user_data)
create_code_sum_of_squares (ctxt, user_data);
create_code_types (ctxt, user_data);
create_code_using_global (ctxt, user_data);
+ create_code_volatile (ctxt, user_data);
}
void
verify_code (gcc_jit_context *ctxt, gcc_jit_result *result)
{
verify_code_accessing_struct (ctxt, result);
+ verify_code_arrays (ctxt, result);
verify_code_calling_external_function (ctxt, result);
verify_code_dot_product (ctxt, result);
verify_code_expressions (ctxt, result);
@@ -157,4 +174,5 @@ verify_code (gcc_jit_context *ctxt, gcc_jit_result *result)
verify_code_sum_of_squares (ctxt, result);
verify_code_types (ctxt, result);
verify_code_using_global (ctxt, result);
+ verify_code_volatile (ctxt, result);
}
--
1.8.5.3