XMath.Exp : An internal compiler error has been detected
Closed this issue · 4 comments
Describe the bug
ILGPU crashes when I use XMath.Exp or XMath.Pow.
Environment
- ILGPU version: [e.g., 1.5.1]
- .NET version: [e.g., .NET 8]
- Operating system: [e.g., Windows 10]
- Hardware (if GPU-related): [e.g., NVIDIA GeForce GTX 1080]
Steps to reproduce
a = IntrinsicMath.Abs(1 / b0);
c = XMath.Exp(-1 * b1 * a);
Expected behavior
Output:
ERROR:An internal compiler error has been detected
Additional context
No response
hi @ShagufthaT
Which version of ILGPU are you using?
Which version of .NET are you using?
What type of graphics cards are you using? Nvidia/Cuda?
If you look at the Releases page, you will find some sample code. The sample code is also available on Github (e.g. https://github.com/m4rs-mt/ILGPU/blob/master/Samples/AlgorithmsMath/Program.cs). Are you able to get these to work?
Also, please ensure that the ILGPU
nuget package version matches the ILGPU.Algorithms
nuget package version.
Hi @MoFtZ
ILGPU version: 1.5.1
ILGPU Algorithms: 1.5.1
.Net version: 6.0
Graphics card: Nvidia/Cuda
Abs works fine but XMath.Sinh, XMath.Exp, XMath.Pow etc shows the same error.
Have you called EnableAlgorithms
?
https://github.com/m4rs-mt/ILGPU/blob/master/Samples/AlgorithmsMath/Program.cs#L46
Also, the exception thrown by ILGPU may have an InnerException
property. Please take a look, as it will have more detailed information.
Ah! I missed to call EnableAlgorithms. It works fine now. Thanks a lot.