aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/validation/mem2reg/init-local64.c
diff options
authorLuc Van Oostenryck <luc.vanoostenryck@gmail.com>2018-09-09 23:27:04 +0200
committerLuc Van Oostenryck <luc.vanoostenryck@gmail.com>2018-09-10 00:54:52 +0200
commit6c522d114cef173215686b3394ae41701ea80aa4 (patch)
treeedd6cc6c50fa75ad101ddf83f6df1461d2610800 /validation/mem2reg/init-local64.c
parent8f98b88b4594be82dd0e18449d7254026a669dcf (diff)
downloadsparse-dev-6c522d114cef173215686b3394ae41701ea80aa4.tar.gz
test: make 32-bit version of failed test
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@ramsayjones.plus.com> Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
Diffstat (limited to 'validation/mem2reg/init-local64.c')
-rw-r--r--validation/mem2reg/init-local64.c27
1 files changed, 27 insertions, 0 deletions
diff --git a/validation/mem2reg/init-local64.c b/validation/mem2reg/init-local64.c
new file mode 100644
index 00000000..72f89742
--- /dev/null
+++ b/validation/mem2reg/init-local64.c
@@ -0,0 +1,27 @@
+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-local64
+ * check-command: test-linearize -Wno-decl -m64 -fdump-ir=mem2reg $file
+ * check-output-ignore
+ * check-output-excludes: load\\.
+ * check-output-excludes: store\\.
+ */