aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.7/libjava/sysdep/pa/descriptor.h
diff options
context:
space:
mode:
Diffstat (limited to 'gcc-4.7/libjava/sysdep/pa/descriptor.h')
-rw-r--r--gcc-4.7/libjava/sysdep/pa/descriptor.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/gcc-4.7/libjava/sysdep/pa/descriptor.h b/gcc-4.7/libjava/sysdep/pa/descriptor.h
new file mode 100644
index 000000000..d9888516d
--- /dev/null
+++ b/gcc-4.7/libjava/sysdep/pa/descriptor.h
@@ -0,0 +1,7 @@
+// Given a function pointer, return the code address.
+// If the plabel bit is set, mask it off and return the code from the
+// first word of the function descriptor. Otherwise, the function
+// pointer is the code address.
+
+#define UNWRAP_FUNCTION_DESCRIPTOR(X) \
+ (((unsigned int)(X)) & 2 ? *(void **)(((unsigned int)(X)) & ~3) : (X))