abhishekgahlot / gpuocelot

Automatically exported from code.google.com/p/gpuocelot
1 stars 0 forks source link

ocelot/translator/implementation/PTXToLLVMTranslator.cpp:2686: void translator::PTXToLLVMTranslator::_translateCvta(const ir::PTXInstruction&): Assertion `false' failed. #84

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Run CUDA program linked with gpuocelot as in documentation.

What is the expected output? What do you see instead?
- Should run normally with "llvm" backend.
Runs normally (but slow) only with "emulated" backend.

What version of the product are you using? On what operating system?
-Latest from svn, latest llvm-3.4svn, Gentoo GNU/Linux linux-3.8.8, glibc-2.15, 
gcc-4.6.3

Please provide any additional information below.
-Could not find any clues on google.

Original issue reported on code.google.com by volyrkr on 5 Jun 2013 at 12:20

GoogleCodeExporter commented 9 years ago
I don't have time to learn all the details so I found the type that was 
'invalid' - ir::PTXInstruction::Const and added it to the choice list.
Brute force worked.
Why Const was not included?
Thanks.

Index: PTXToLLVMTranslator.cpp
===================================================================
--- PTXToLLVMTranslator.cpp (revision 2235)
+++ PTXToLLVMTranslator.cpp (working copy)
@@ -2665,6 +2665,7 @@
        {
        case ir::PTXInstruction::Shared: /* fall through */
        case ir::PTXInstruction::Local:
+       case ir::PTXInstruction::Const:
        {
            assertM( i.addressSpace != ir::PTXInstruction::Local
                || i.a.addressMode != ir::PTXOperand::Address

Original comment by volyrkr on 5 Jun 2013 at 2:18