I am working on a Oracle HotSpot and GC internals article, but I am confused about the meaning of OOP (Ordinary Object Pointer).
The Oracle documentation states that an OOP is a 32 or 64 bit pointer to an object datastructure on the heap:
An "oop", or ordinary object pointer in Java Hotspot parlance, is a managed pointer to an object. An oop is normally the same size as a native machine pointer
It can be compressed, but that is besides the issue.
I wanted to find articles about this datastructure but then the confusion started.
Some articles say OOP is actually the datastructure itself, not the pointer!
Some other articles seem contradictory on this point, like on infoq.com. At first it states an OOP is a pointer:
An OOP is a genuine pointer in the C / C++ sense - a machine word which points to a memory location inside the Java heap.
but after that it says:
An OOP consists of two machine words of header, which are called the Mark and the Klass words followed by the member fields of this instance.
So the pointer consists of header and member fields? That can't be true.
Finally I tried to look at the source code of Oracle JDK and OpenJDK HotSpot source (because Oracle HotSpot is not open source). But based on that it seemed OOP is really the object datastructure. But in this case what is the pointer?
So the question is: what is the OOP in HotSpot JVM?