8203339: Add oopDesc::field_offset()

Reviewed-by: rkennke, eosterlund
This commit is contained in:
Stefan Karlsson 2018-05-20 22:08:25 +02:00
parent 535c2507a0
commit 7b0d398bc7
3 changed files with 77 additions and 0 deletions

View file

@ -131,6 +131,8 @@ class oopDesc {
// Need this as public for garbage collection.
template <class T> inline T* obj_field_addr_raw(int offset) const;
template <typename T> inline size_t field_offset(T* p) const;
// Standard compare function returns negative value if o1 < o2
// 0 if o1 == o2
// positive value if o1 > o2