[PATCH 3/4] test: make 32-bit version of failed test

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The test mem2reg/init-local.c succeeds on 64-bit but fails
on 32-bit.

Duplicate the test, one with -m64 and the other with -m32
and mark this one as known-to-fail.

Reported-by: Ramsay Jones <ramsay@xxxxxxxxxxxxxxxxxxxx>
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@xxxxxxxxx>
---
 validation/mem2reg/init-local32.c             | 29 +++++++++++++++++++
 .../mem2reg/{init-local.c => init-local64.c}  |  4 +--
 2 files changed, 31 insertions(+), 2 deletions(-)
 create mode 100644 validation/mem2reg/init-local32.c
 rename validation/mem2reg/{init-local.c => init-local64.c} (71%)

diff --git a/validation/mem2reg/init-local32.c b/validation/mem2reg/init-local32.c
new file mode 100644
index 000000000..c988bb6e7
--- /dev/null
+++ b/validation/mem2reg/init-local32.c
@@ -0,0 +1,29 @@
+int ssimple(void)
+{
+	struct {
+		int a;
+	} s;
+
+	s.a = 1;
+	return s.a;
+}
+
+double sdouble(void)
+{
+	struct {
+		double a;
+	} s;
+
+	s.a = 1.23;
+	return s.a;
+}
+
+/*
+ * check-name: init-local32
+ * check-command: test-linearize -Wno-decl -m32 -fdump-ir=mem2reg $file
+ * check-known-to-fail
+ *
+ * check-output-ignore
+ * check-output-excludes: load\\.
+ * check-output-excludes: store\\.
+ */
diff --git a/validation/mem2reg/init-local.c b/validation/mem2reg/init-local64.c
similarity index 71%
rename from validation/mem2reg/init-local.c
rename to validation/mem2reg/init-local64.c
index d51c9247a..72f89742b 100644
--- a/validation/mem2reg/init-local.c
+++ b/validation/mem2reg/init-local64.c
@@ -19,8 +19,8 @@ double sdouble(void)
 }
 
 /*
- * check-name: init-local
- * check-command: test-linearize -Wno-decl -fdump-ir=mem2reg $file
+ * check-name: init-local64
+ * check-command: test-linearize -Wno-decl -m64 -fdump-ir=mem2reg $file
  * check-output-ignore
  * check-output-excludes: load\\.
  * check-output-excludes: store\\.
-- 
2.18.0




[Index of Archives]     [Newbies FAQ]     [LKML]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Trinity Fuzzer Tool]

  Powered by Linux