From: Mark Mitchell Date: Tue, 3 Aug 2004 21:20:36 +0000 (+0000) Subject: symbian1.c: New test. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=5357b1f9df2a6613d463096a8808f34a4ee6f60e;p=gcc.git symbian1.c: New test. * gcc.dg/symbian1.c: New test. * gcc.dg/symbian2.c: Likewise. From-SVN: r85505 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 85dd35b19fb..72e026ca131 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2004-08-03 Mark Mitchell + + * gcc.dg/symbian1.c: New test. + * gcc.dg/symbian2.c: Likewise. + 2004-08-03 H.J. Lu PR target/16570 diff --git a/gcc/testsuite/gcc.dg/symbian1.c b/gcc/testsuite/gcc.dg/symbian1.c new file mode 100644 index 00000000000..25e81281683 --- /dev/null +++ b/gcc/testsuite/gcc.dg/symbian1.c @@ -0,0 +1,11 @@ +/* { dg-do compile { target arm*-*-symbianelf* } } */ +/* Symbian OS requires that all defined symbols with external linkage + have the ELF STV_HIDDEN attribute set by default. */ +/* { dg-final { scan-assembler ".hidden.*i" } } */ +/* { dg-final { scan-assembler ".hidden.*j" } } */ +/* { dg-final { scan-assembler ".hidden.*f" } } */ + +int i; +int j = 3; +void f() {} + diff --git a/gcc/testsuite/gcc.dg/symbian2.c b/gcc/testsuite/gcc.dg/symbian2.c new file mode 100644 index 00000000000..98701636875 --- /dev/null +++ b/gcc/testsuite/gcc.dg/symbian2.c @@ -0,0 +1,10 @@ +/* { dg-do compile { target arm*-*-symbianelf* } } */ +/* { dg-options "-O2" } */ + +/* Symbian OS requires that builtins not be expanded by default. Make + sure that a reference to "strlen" is emitted. */ +/* { dg-final { scan-assembler "strlen" } } */ + +int f() { + return strlen("abc"); +}