diff options
author | Alan Modra <amodra@bigpond.net.au> | 2009-10-30 00:48:54 -0700 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2009-10-30 00:48:54 -0700 |
commit | 31c759bf37a7a41faf8b13800deb769e8a5f3871 (patch) | |
tree | b1e594e990e74cff74ab667cfb4a57faa790e6dd /sysdeps/generic/elf | |
parent | 51a71cf063505d689337cf998670691a0a4b2410 (diff) | |
download | glibc-31c759bf37a7a41faf8b13800deb769e8a5f3871.zip glibc-31c759bf37a7a41faf8b13800deb769e8a5f3871.tar.gz glibc-31c759bf37a7a41faf8b13800deb769e8a5f3871.tar.bz2 |
Uglify IFUNC tests for PPC.
Diffstat (limited to 'sysdeps/generic/elf')
-rw-r--r-- | sysdeps/generic/elf/ifunc-sel.h | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/sysdeps/generic/elf/ifunc-sel.h b/sysdeps/generic/elf/ifunc-sel.h new file mode 100644 index 0000000..6a27b69 --- /dev/null +++ b/sysdeps/generic/elf/ifunc-sel.h @@ -0,0 +1,26 @@ +/* Used by the elf ifunc tests. */ +#ifndef ELF_IFUNC_SEL_H +#define ELF_IFUNC_SEL_H 1 + +extern int global; + +static inline void * +ifunc_sel (int (*f1) (void), int (*f2) (void), int (*f3) (void)) +{ + switch (global) + { + case 1: + return f1; + case -1: + return f2; + default: + return f3; + } +} + +static inline void * +ifunc_one (int (*f1) (void)) +{ + return f1; +} +#endif |