RFR(XXS): 8231025: Incorrect method tag offset for big endian platform
Markus Gronlund
markus.gronlund at oracle.com
Sat Sep 14 16:04:45 UTC 2019
Greetings,
Can I please have a review for the following changeset, description in bug.
Bug: https://bugs.openjdk.java.net/browse/JDK-8231025
Change set:
diff -r caa25ab47aca src/hotspot/share/jfr/support/jfrTraceIdExtension.hpp
--- a/src/hotspot/share/jfr/support/jfrTraceIdExtension.hpp Sat Sep 14 14:40:09 2019 +0200
+++ b/src/hotspot/share/jfr/support/jfrTraceIdExtension.hpp Sat Sep 14 17:52:10 2019 +0200
@@ -26,6 +26,7 @@
#define SHARE_JFR_SUPPORT_JFRTRACEIDEXTENSION_HPP
#include "jfr/recorder/checkpoint/types/traceid/jfrTraceId.hpp"
+#include "utilities/macros.hpp"
#define DEFINE_TRACE_ID_FIELD mutable traceid _trace_id
@@ -59,10 +60,19 @@
}
jbyte* flags_addr() const {
+#ifdef VM_LITTLE_ENDIAN
return (jbyte*)&_flags;
+#else
+ return ((jbyte*)&_flags) + 1;
+#endif
}
+
jbyte* meta_addr() const {
- return ((jbyte*)&_flags) + 1;
+#ifdef VM_LITTLE_ENDIAN
+ return (jbyte*)(&_flags) + 1;
+#else
+ return (jbyte*)&_flags;
+#endif
}
};
Thank you
Markus
More information about the hotspot-jfr-dev
mailing list