namespace mirror { classClass; class Object;
} // namespace mirror
// How we want to check the heap's correctness. enum VerifyObjectMode {
kVerifyObjectModeDisabled, // Heap verification is disabled.
kVerifyObjectModeFast, // Check heap accesses quickly by using VerifyClassClass.
kVerifyObjectModeAll // Check heap accesses thoroughly.
};
enum EXPORT VerifyObjectFlags {
kVerifyNone = 0x0, // Verify self when we are doing an operation.
kVerifyThis = 0x1, // Verify reads from objects.
kVerifyReads = 0x2, // Verify writes to objects.
kVerifyWrites = 0x4, // Verify all things.
kVerifyAll = kVerifyThis | kVerifyReads | kVerifyWrites,
};
// Implements the actual object checks. void VerifyObjectImpl(ObjPtr<mirror::Object> obj) NO_THREAD_SAFETY_ANALYSIS;
// Is a front to optimize out any calls if no verification is enabled.
ALWAYS_INLINE staticinlinevoid VerifyObject(ObjPtr<mirror::Object> obj) NO_THREAD_SAFETY_ANALYSIS { if (kVerifyObjectSupport > kVerifyObjectModeDisabled && obj != nullptr) {
VerifyObjectImpl(obj);
}
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.