8086073: Fix PrintStubCode for empty StubCodeGenerator.
Reviewed-by: kvn, lfoltan
--- a/hotspot/src/share/vm/runtime/stubCodeGenerator.cpp Mon Jun 08 12:54:05 2015 +0200
+++ b/hotspot/src/share/vm/runtime/stubCodeGenerator.cpp Thu Jun 11 11:07:03 2015 -0400
@@ -96,7 +96,7 @@
toprint[toprint_len++] = cdesc;
if (cdesc == _first_stub) { saw_first = true; break; }
}
- assert(saw_first, "must get both first & last");
+ assert(toprint_len == 0 || saw_first, "must get both first & last");
// Print in reverse order:
qsort(toprint, toprint_len, sizeof(toprint[0]), compare_cdesc);
for (int i = 0; i < toprint_len; i++) {