question about testing arrays
Venkatachalam, Vasanth
Vasanth.Venkatachalam at amd.com
Mon Mar 4 16:16:42 PST 2013
Hi Thomas,
I tried running the following similar test case inside BasicPTXTest:
@SuppressWarnings("all")
public static int arraysquares(int array1[]) {
return array1[0];
}
When I run this in PTX mode, I get the error below. Can you explain how to get past this in PTX?
I was initially seeing the same error in HSAIL until I implemented the Guard instruction, at which point I got the "ICMP receiving a constant" error alluded to earlier.
Vasanth
1) test1(com.oracle.graal.compiler.ptx.test.BasicPTXTest)
com.oracle.graal.graph.GraalInternalError: java.lang.InternalError: NYI
at node: 18|!Guard
at com.oracle.graal.compiler.gen.LIRGenerator.doBlock(LIRGenerator.java:381)
at com.oracle.graal.compiler.GraalCompiler$3.emitBlock(GraalCompiler.java:249)
at com.oracle.graal.compiler.GraalCompiler$3.run(GraalCompiler.java:236)
at com.oracle.graal.debug.internal.DebugScope.executeScope(DebugScope.java:166)
at com.oracle.graal.debug.internal.DebugScope.scope(DebugScope.java:154)
at com.oracle.graal.debug.Debug.scope(Debug.java:101)
at com.oracle.graal.debug.Debug.scope(Debug.java:96)
at com.oracle.graal.compiler.GraalCompiler.emitLIR(GraalCompiler.java:23
-----
-----Original Message-----
From: Thomas Wuerthinger [mailto:thomas.wuerthinger at oracle.com]
Sent: Monday, March 04, 2013 4:08 PM
To: Venkatachalam, Vasanth
Cc: graal-dev at openjdk.java.net
Subject: Re: question about testing arrays
No, the issue is caused by the operand to the compare instruction not expecting a constant but a register. This is why I was asking you if an operand to an HSAIL compare instruction may also be a constant directly? Or does HSAIL require the constant be loaded into a register first?
- thomas
More information about the graal-dev
mailing list