CUDA 6.5 compiler problems

Hi all,

Compiling under L4T with CUDA 6.5 compiler. I’m getting an internal error, “catastrophic error detected in compilation”, with the following scenario:

// Constructor
ConvolutionNode(std::initializer_liststd::string inputList): Node(inputList) {
// …
}

// Invocation
pRegistry->registerNode(“conv0_1”, new ConvolutionNode({ “conv1_1”, “idata” });

The compiler throws this error when attempting to instantiate the Node class in the line above.

Tips?

So the problem is that the initializer { “conv1_1” } is valid, whereas { “conv1_1”, “idata” } is not valid. A mod on one of the other forums mentioned that C++11 support in the CUDA 6.5 compiler is rudimentary at best.

The question is, have any patches been made for this issue, or does anyone have any workarounds?

Hi,

Thanks for your feedback.

Could you share a simple source to reproduce this issue?
Then we can check if any WAR is available for your use case.

Thanks

Thanks @AastaLLL for the response.

A basic test scenario is (compiled with => nvcc -std=c++11 test.cu):

#include

void testFunction(std::initializer_liststd::string stringList) {
// Do something
}

int main(void) {
// Works
testFunction({ “a” });

    // Doesn't work - throws "catastrophic error"
    testFunction({ "a", "b", "c" });

    return 0;

}

I would just like to do nice things like:

pRegistry->registerNode(“conv1_1”, new ConvNode(3, 3, 1, 1, 128, { “data”, “idata” }));

Without having to worry about variable parameter lists.

Thanks for the update.

Any updates on my update? ;)

Hi,

This issue may from g++ compiler rather than nvcc.
Could you help us check following commands?

nvcc --std=c++11 [code.cu]
g++ --std=c++11 [code.cpp]

Thanks.

Thanks for the update, AastaLLL. I compiled test code with the above command lines:

[nvcc --std=c++11 test.cu]

#include <string>

void testFunction(std::initializer_list<std::string> stringList) {
}

int main(void) {
        testFunction({ "a" });
        testFunction({ "a", "b", "c" });
        return 0;
}

[g++ --std=c++11 test.cpp]

#include <string>
#include <list>

void testFunction(std::initializer_list<std::string> stringList) {
}

int main(void) {
        testFunction({ "a" });
        testFunction({ "a", "b", "c" });
        return 0;
}

The g++ command line compiles the code correctly, whereas the nvcc command line fails with the “catastrophic error”.

Thanks.

We are discussing this issue internally.
Will update information with you later.

Hi,

C++11 support is available until CUDA 7.0.

As a result, it is not available for TK1 which is on CUDA 6.5.
Thanks.