identified bug due to llvm-3.4

This commit is contained in:
Evghenii
2013-11-14 21:18:25 +01:00
parent 1b940fd41e
commit 1445202e0e
4 changed files with 8 additions and 7 deletions

View File

@@ -2334,7 +2334,7 @@ Module::CompileAndOutput(const char *srcFile,
char ptxname[] = "nvptx64";
for (int k = 0; k < 7; k++)
ptxname[k] = target[k];
if (target != NULL && strcmp(ptxname,"nvptx64") == 0) // NVPTX64
if (0) //target != NULL && strcmp(ptxname,"nvptx64") == 0) // NVPTX64
{
std::vector<std::string> targets = lExtractTargets(target);
Assert(targets.size() > 1);
@@ -2458,7 +2458,8 @@ Module::CompileAndOutput(const char *srcFile,
}
else if (target == NULL || strchr(target, ',') == NULL) {
// We're only compiling to a single target
g->target = new Target(arch, cpu, target, generatePIC);
const bool isPTX = strcmp(target, "nvptx64") == 0;
g->target = new Target(arch, cpu, target, generatePIC, isPTX);
if (!g->target->isValid())
return 1;