OSDN Git Service

Add dvmHumanReadableDescriptor function, and use it.
authorElliott Hughes <enh@google.com>
Mon, 22 Nov 2010 21:14:23 +0000 (13:14 -0800)
committerElliott Hughes <enh@google.com>
Mon, 22 Nov 2010 21:50:09 +0000 (13:50 -0800)
commit5016966b91f1bc36b2bd52ec13ecfd8de1c68209
tree2ce61b59ffd09e0916297060671b4e73c3a6bbec
parenteb6e6fa4642fc89e31adf28be103f9032eb379e5
Add dvmHumanReadableDescriptor function, and use it.

We were abusing the fact that dvmDescriptorToDot, which is actually meant
for the class loading machinery, produces more readable output than a
regular descriptor. This patch adds a dvmHumanReadableDescriptor function,
switches all the relevant callers over to it, and and reuses the code that
was already in HprodClass.c.

This means we now say "java.lang.String[]" instead of "[Ljava.lang.String;".

Note that the old hprof code would have left "I" unchanged; I modified it
to translate "I" to "int" (et cetera). This was probably an oversight because
primitive scalars can't appear on the heap, so hprof had no need to format
those types (just arrays of primitives, which it got right).

Bug: 3216276
Change-Id: I63f32a2b020674dfa62ce198ff2699ec01857540
vm/Exception.c
vm/Misc.c
vm/Misc.h
vm/analysis/CodeVerify.c
vm/analysis/VerifySubs.c
vm/hprof/HprofClass.c
vm/interp/Interp.c
vm/interp/Stack.c
vm/native/java_lang_Class.c