OpenJDK 64-Bit Server VM warning: increase O_BUFLEN in ostream.hpp -- output truncated
Andrew Haley
aph at redhat.com
Wed Apr 8 15:27:58 UTC 2015
On 04/08/2015 04:10 PM, Thomas Stüfe wrote:
> Hi Andrew,
>
> yes, it is lame. The short term answer would be to fix the expression which
> prints out the classpath. Where is this print statement?
ostream.cpp:
for (SystemProperty* p = Arguments::system_properties(); p != NULL; p = p->next()) {
xs->text()->print_cr("%s=%s", p->key(), p->value());
(gdb) p p->key()
$24 = 0x3ffb00016a0 "sun.boot.class.path"
(gdb) p p->value()
$25 = 0x3ffb00029e0 "/local/aarch64/dev/build/linux-aarch64-normal-server-slowdebug/jdk/modules/jdk.zipfs:/local/aarch64/dev/build/linux-aarch64-normal-server-slowdebug/jdk/modules/java.transaction:/local/aarch64/dev/buil"...
> The long term answer could be e.g.: we could implement our own printf()
> routines. We (SAP) actually already did this inside our JVM for parts of
> our own tracing system. It is not rocket science, just a bit of work. If
> done right, there are several advantages, among others that you do not need
> temporary buffers for the libc printf() to print into. Depending on
> interest, I could try to contribute this to the OpenJDK.
In this case we don't need formatted printing at all.
for (SystemProperty* p = Arguments::system_properties(); p != NULL; p = p->next()) {
outputStream *text = xs->text();
text->print_raw(p->key());
text->put('=');
text->print_raw_cr(p->value());
}
works just fine. It's a bit of a kludge tho'. :-)
Andrew.
More information about the hotspot-dev
mailing list