summaryrefslogtreecommitdiff
path: root/ld/testsuite/ld-size/size-8a.c
diff options
context:
space:
mode:
Diffstat (limited to 'ld/testsuite/ld-size/size-8a.c')
-rw-r--r--ld/testsuite/ld-size/size-8a.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/ld/testsuite/ld-size/size-8a.c b/ld/testsuite/ld-size/size-8a.c
new file mode 100644
index 0000000..78c5732
--- /dev/null
+++ b/ld/testsuite/ld-size/size-8a.c
@@ -0,0 +1,15 @@
+#include <stdio.h>
+
+extern __thread char bar[];
+extern char size_of_bar asm ("bar@SIZE");
+extern void set_bar (int, int);
+
+int
+main ()
+{
+ set_bar (1, 20);
+ if (10 == (long) &size_of_bar && bar[1] == 20)
+ printf ("OK\n");
+
+ return 0;
+}