changeset 13236:25da0f4e5c77

added extra space to disassembler buffer to account for disassembly header
author Doug Simon <doug.simon@oracle.com>
date Tue, 03 Dec 2013 18:03:39 +0100
parents 41f28bc4ac58
children bc1b0ff498f4
files src/share/vm/graal/graalCompilerToVM.cpp
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/share/vm/graal/graalCompilerToVM.cpp	Tue Dec 03 18:03:05 2013 +0100
+++ b/src/share/vm/graal/graalCompilerToVM.cpp	Tue Dec 03 18:03:39 2013 +0100
@@ -870,8 +870,8 @@
   // a ResourceMark and the buffer expands within the scope of the mark,
   // the buffer becomes garbage when that scope is exited. Experience shows that
   // the disassembled code is typically about 10x the code size so a fixed buffer
-  // sized to 20x code size should be sufficient.
-  int bufferSize = cb->code_size() * 20;
+  // sized to 20x code size plus a fixed amount for header info should be sufficient.
+  int bufferSize = cb->code_size() * 20 + 1024;
   char* buffer = NEW_RESOURCE_ARRAY(char, bufferSize);
   stringStream st(buffer, bufferSize);
   if (cb->is_nmethod()) {