Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 286421

Summary: object reference graph incorrect
Product: [Tools] MAT Reporter: Randall Theobald <rstheo>
Component: CoreAssignee: Project Inbox <mat.core-inbox>
Status: RESOLVED NOT_ECLIPSE QA Contact:
Severity: normal    
Priority: P3 CC: andrew_johnson
Version: 0.8   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
problem system dump none

Description Randall Theobald CLA 2009-08-12 13:41:19 EDT
Created attachment 144269 [details]
problem system dump

I think I have come across what could be a major bug in MAT or the IBM adapter. In this particular dump I have (IBM system dump), I keep finding references that should be impossible. For example, in a WeakHashMap$Entry.next field, the object referred to was NOT a WeakHashMap$Entry object. I came across a few other instances where it made me question the integrity of the data being shown to me.

Open the attached dump in MAT. Go to the class XSDParser, static field, userDataMap. Browse the WeakHashMap entries and see that there are some .next fields are not pointing to WeakHashMap$Entry objects. (e.g. 0xdc561b8, 0xe06adb8)
Comment 1 Andrew Johnson CLA 2009-08-13 07:54:37 EDT
I can reproduce the problem with objects

0xdc561b8
0xe06adb8
0xe0653f0
0xdb851c8

The dump is partially corrupt as in the error log there are 20 messages of these types

Invalid object field reference 0xdb89300 of type com.ibm.dtfj.image.CorruptDataException: Unknown class ID 230216736 found at field java/util/WeakHashMap$Entry.value of type Ljava/lang/Object; in object of type java/util/WeakHashMap$Entry at address 0xdb851c8 while finding outbound references

Invalid array element reference 0xdb894b0 of type ? found at index 0 in array of type [Ljava/lang/Object; length 5 at address 0xdb853b0 while finding outbound references

and this final message, so there have been hundreds of thousands of these errors.

297,876 repeated messages have been suppressed 

What VM options were used to generate the dump?
Comment 2 Randall Theobald CLA 2009-08-13 08:18:42 EDT
My eclipsi.ini had this line:

   -Xdump:system:events=user+systhrow,filter=*Memory*,request=exclusive+prepwalk+compact

but it was our Performance Inspector JProf JVMTI agent that triggered the system dump.

How can I find those error messages? Can we put some sort of warning up in MAT to notify the user of such a thing? My jextract log was clean.
Comment 3 Andrew Johnson CLA 2010-03-04 09:49:54 EST
Window->Error Log
will show you the messages from the parser.
Comment 4 Andrew Johnson CLA 2010-06-16 05:37:25 EDT
The dump was corrupt, so we can't do anything.