workaround for programIndex via preprocessor

This commit is contained in:
Evghenii
2013-11-14 19:48:50 +01:00
parent e162d5a99d
commit 25df23fed3

View File

@@ -1926,7 +1926,10 @@ Module::execPreprocessor(const char *infilename, llvm::raw_string_ostream *ostre
}
}
if (g->target->getISA() == Target::NVPTX64)
{
opts.addMacroDef("__NVPTX__");
opts.addMacroDef("programIndex=laneIndex()");
}
#if defined(LLVM_3_1)
inst.getLangOpts().BCPLComment = 1;