aboutsummaryrefslogtreecommitdiff
path: root/libsframe/testsuite/libsframe.unwind/solib-lib1.c
diff options
context:
space:
mode:
authorWeimin Pan <weimin.pan@oracle.com>2022-09-27 15:24:47 -0700
committerIndu Bhagat <indu.bhagat@oracle.com>2024-04-25 15:03:50 -0700
commit171324cb0325c6c54a1d98d3564a4da5ca2dc1a5 (patch)
tree7fc69957cc74e9b2f60d93246fd32f8efbc308cc /libsframe/testsuite/libsframe.unwind/solib-lib1.c
parent6d551065a7add22cef04864d850400443cdd065b (diff)
downloadbinutils-171324cb0325c6c54a1d98d3564a4da5ca2dc1a5.zip
binutils-171324cb0325c6c54a1d98d3564a4da5ca2dc1a5.tar.gz
binutils-171324cb0325c6c54a1d98d3564a4da5ca2dc1a5.tar.bz2
unwinder: Add SFrame unwinder tests
[Changes in V4] - Addressed Mike's review comments. - Be careful with the use of # and dnl in configure.ac - Add AC_CANONICAL_TARGET as we check for target. - Remove the LC_ALL=C bits. - Minor code fixups in the testcases - Removed unnecessary unistd.h. - use ATTRIBUTE_NOCLONE consistently. - Other minor cleanups. [End of changes in V4] [Changes in V3] - Added two new tests with attributes -f(no-)omit-frame-pointer. - Minor adjustments due to buildsystem changes in libsframe. [End of changes in V3] [Changes in V2] - minor changes in filenames in the testsuite. [End of changes in V2] Add tests for backtracing using SFrame section. ChangeLog: * libsframe/Makefile.in: Regenerated. * libsframe/configure: Regenerated. * libsframe/configure.ac: Check for cross compilation. * libsframe/testsuite/Makefile.in: Regenerated. * libsframe/testsuite/config/default.exp: Load sframe-lib.exp. * libsframe/testsuite/libsframe.decode/Makefile.in: Regenerated. * libsframe/testsuite/libsframe.encode/Makefile.in: Regenerated. * libsframe/testsuite/lib/sframe-lib.exp: New file. Add procedures for handling unwinder tests. * libsframe/testsuite/libsframe.unwind/backtrace.c: New test. * libsframe/testsuite/libsframe.unwind/backtrace.lk: New test. * libsframe/testsuite/libsframe.unwind/inline-cmds.c: New test. * libsframe/testsuite/libsframe.unwind/inline-cmds.lk: New test. * libsframe/testsuite/libsframe.unwind/inline.c: New test. * libsframe/testsuite/libsframe.unwind/inline.lk: New test. * libsframe/testsuite/libsframe.unwind/solib-lib1.c: New test. * libsframe/testsuite/libsframe.unwind/solib-lib2.c: New test. * libsframe/testsuite/libsframe.unwind/solib-main.c: New test. * libsframe/testsuite/libsframe.unwind/solib-main.d: New test. * libsframe/testsuite/libsframe.unwind/solib.exp: New file. * libsframe/testsuite/libsframe.unwind/solib-lib1.h: New test. * libsframe/testsuite/libsframe.unwind/solib-lib2.h: New test. * libsframe/testsuite/libsframe.unwind/tailcall.c: New test. * libsframe/testsuite/libsframe.unwind/tailcall.lk: New test. * libsframe/testsuite/libsframe.unwind/ttest.c: New test. * libsframe/testsuite/libsframe.unwind/ttest.lk: New test. * libsframe/testsuite/libsframe.unwind/unwind.exp: New file. * libsframe/testsuite/libsframe.unwind/backtrace-fp-attr-1.c: Likewise. * libsframe/testsuite/libsframe.unwind/backtrace-fp-attr-1.lk: Likewise. * libsframe/testsuite/libsframe.unwind/backtrace-fp-attr-2.c: Likewise. * libsframe/testsuite/libsframe.unwind/backtrace-fp-attr-2.lk: Likewise.
Diffstat (limited to 'libsframe/testsuite/libsframe.unwind/solib-lib1.c')
-rw-r--r--libsframe/testsuite/libsframe.unwind/solib-lib1.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/libsframe/testsuite/libsframe.unwind/solib-lib1.c b/libsframe/testsuite/libsframe.unwind/solib-lib1.c
new file mode 100644
index 0000000..16c77ca
--- /dev/null
+++ b/libsframe/testsuite/libsframe.unwind/solib-lib1.c
@@ -0,0 +1,8 @@
+#include "solib-lib1.h"
+
+unsigned int
+adder(unsigned int a, unsigned int b, int (*call)(int))
+{
+ (void)(*call)(a+b);
+ return (a+b);
+}