jdk9 : forcing inlining in src/share/vm/oops/instanceKlass.inline.hpp for xlc

Baesken, Matthias matthias.baesken at sap.com
Wed Mar 9 17:01:07 UTC 2016


Hello ,
CR 8075955: "Replace the macro based implementation of oop_oop_iterate with a template based solution"

changed src/share/vm/oops/instanceKlass.inline.hpp

and replaced macro based oop iteration by templates.
For performance reason, the change (and a follow up change for Oracle Studio) introduced forcing of inlining for some places in
src/share/vm/oops/instanceKlass.inline.hpp  , see


http://hg.openjdk.java.net/jdk9/dev/hotspot/file/797e6aac6d53/src/share/vm/oops/instanceKlass.inline.hpp

....
// The iteration over the oops in objects is a hot path in the GC code.
// By force inlining the following functions, we get similar GC performance
// as the previous macro based implementation.
#ifdef TARGET_COMPILER_visCPP
#define INLINE __forceinline
#elif defined(TARGET_COMPILER_sparcWorks)
#define INLINE __attribute__((always_inline))
#else
#define INLINE inline
#endif
....

(which is compiler dependent)
Should we do this for the AIX port too ?

http://www.ibm.com/support/knowledgecenter/SSGH2K_12.1.0/com.ibm.xlc121.aix.doc/language_ref/function_attributes.html?lang=en


describes the function attributes of xlc which can be used.
Diff to instanceKlass.inline.hpp  :

43,44d42
< #elif defined(TARGET_COMPILER_xlc)
< #define INLINE __attribute__((always_inline))


Regards, Matthias
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/ppc-aix-port-dev/attachments/20160309/4c1af93a/attachment.html>


More information about the ppc-aix-port-dev mailing list