stream. I found it useful for debugging so I will share.
* main.c: Add --blob switch to dump the blob stream.
svn path=/trunk/mono/; revision=29967
+2004-06-19 Jackson Harper <jackson@ximian.com>
+
+ * dump.c/h: New function to dump the contents of the blob
+ stream. I found it useful for debugging so I will share.
+ * main.c: Add --blob switch to dump the blob stream.
+
2004-06-19 Jackson Harper <jackson@ximian.com>
* get.c/h: New function to stringify function pointers.
}
}
+void
+dump_stream_blob (MonoImage *m)
+{
+ int i;
+
+ fprintf (output, "Blob heap contents\n");
+
+ for (i = 0; i < m->heap_blob.size; i++) {
+ fprintf (output, "%x ", m->heap_blob.data [i]);
+ if (i > 0 && (i % 25) == 0)
+ fprintf (output, "\n");
+ }
+
+ fprintf (output, "\n");
+}
+
void dump_table_methodspec (MonoImage *m);
void dump_table_parconstraint(MonoImage *m);
void dump_table_implmap (MonoImage *m);
+void dump_stream_blob (MonoImage *m);
{ "--typeref", MONO_TABLE_TYPEREF, dump_table_typeref },
{ "--typespec", MONO_TABLE_TYPESPEC, dump_table_typespec },
{ "--implmap", MONO_TABLE_IMPLMAP, dump_table_implmap },
+ { "--blob", NULL, dump_stream_blob },
{ NULL, -1 }
};