Mercurial > hg > truffle
changeset 11259:3245779c0ce2
added support to disassemble installed test code via -G:Log
author | Doug Simon <doug.simon@oracle.com> |
---|---|
date | Wed, 07 Aug 2013 18:41:00 +0200 |
parents | 56f1aa40e13b |
children | 064ce0777eba |
files | graal/com.oracle.graal.compiler.test/src/com/oracle/graal/compiler/test/GraalCompilerTest.java |
diffstat | 1 files changed, 9 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/graal/com.oracle.graal.compiler.test/src/com/oracle/graal/compiler/test/GraalCompilerTest.java Wed Aug 07 18:40:05 2013 +0200 +++ b/graal/com.oracle.graal.compiler.test/src/com/oracle/graal/compiler/test/GraalCompilerTest.java Wed Aug 07 18:41:00 2013 +0200 @@ -449,6 +449,15 @@ if (Debug.isDumpEnabled()) { Debug.dump(new Object[]{compResult, code}, "After code installation"); } + if (Debug.isLogEnabled()) { + DisassemblerProvider dis = Graal.getRuntime().getCapability(DisassemblerProvider.class); + if (dis != null) { + String text = dis.disassemble(code); + if (text != null) { + Debug.log("Code installed for %s%n%s", method, text); + } + } + } return code; }