tool or option for viewing LIR nodes
Venkatachalam, Vasanth
Vasanth.Venkatachalam at amd.com
Mon May 6 08:29:55 PDT 2013
Doug and Giles,
Here's the command line I'm using.
tester at see-anna1:~/graalcloneinternal/graal$ ./mx.sh --vm server --java-home /home/tester/graal/jdk1.7.0_13/debug -G:Dump= -G:+PrintCFG unittest BasicHSAILTest
...
mx: error: unrecognized arguments: -G:Dump= -G:+PrintCFG
Can someone explain what I'm doing wrong here?
Vasanth
-----Original Message-----
From: Doug Simon [mailto:doug.simon at oracle.com]
Sent: Saturday, May 04, 2013 4:47 PM
To: Venkatachalam, Vasanth
Cc: graal-dev at openjdk.java.net
Subject: Re: tool or option for viewing LIR nodes
As Gilles says, the -G options should work under --vm server. It helps if you post the complete command line you are using to see if we can spot a problem.
-Doug
On May 4, 2013, at 10:02 PM, Gilles Duboscq <duboscq at ssw.jku.at> wrote:
> The server vm that contains Graal (--vm server) should definitely pick
> up all -G options including -G:Dump= and -G:+PrintCFG.
> Since you are talking about unit tests i suppose you are using the
> GraalCompilerTest's method to explicitly trigger compilation.
>
> I don't know how you are structuring your tests but there are some
> "Debug scopes" that need to be properly set up for these flags to
> work. Normally if you just make your test a subclass of
> GraalCompilerTest and then use its methods if should be fine.
>
>
> On Sat, May 4, 2013 at 2:30 AM, Vasanth Venkatachalam <
> Vasanth.Venkatachalam at amd.com> wrote:
>
>> Christian,
>>
>> Some more context to my question.
>>
>> I've added a Graal backend for HSAIL code generation. I'm debugging
>> the codegen for a test case where running with the --vm server option
>> produces some incorrect results.
>> Thus I'd like to view the nodes that are produced when running with
>> the mx --vm server option.
>>
>> It looks like the c1visualizer tool can't be used with --vm server.
>> Is there another tool that can help?
>>
>> I had a similar issue with the IdealGraphVisualizer. The -G:Dump=
>> option isn't recognized when running with --vm server.
>>
>> Vasanth
>>
>> -----Original Message-----
>> From: graal-dev-bounces at openjdk.java.net [mailto:
>> graal-dev-bounces at openjdk.java.net] On Behalf Of Christian Wimmer
>> Sent: Friday, May 03, 2013 12:22 PM
>> To: graal-dev at openjdk.java.net
>> Subject: Re: tool or option for viewing LIR nodes
>>
>>
>> On 05/03/2013 09:23 AM, Venkatachalam, Vasanth wrote:
>>> Is there a tool or option that would allow us to view the LIR nodes
>>> that
>> Graal generates for a program?
>>
>> Yes.
>>
>> Graal can output the graph, LIR, register allocator liveness
>> information, and machine code in the format required by the Client Compiler Visualizer.
>> As the name implies, the tool was originally written to visualize the
>> data structures of the Java HotSpot client compiler.
>>
>> You can get it here: https://java.net/projects/c1visualizer/
>>
>> The output is controlled the same ways as the output to the Ideal
>> Graph Visualizer, i.e., the -G:Dump= flag. In addition, I think you
>> have to also pass -G:+PrintCFG
>>
>> The tool is file-based, i.e., you get .cfg files in your working
>> directory that you can load with the c1visualizer.
>>
>> -Christian
>>
>>
>>
More information about the graal-dev
mailing list