+ // Check whether this is a constant drived from a pointer. + Constant *itC = c; + while(isa<ConstantExpr>(itC)) + itC = dyn_cast<ConstantExpr>(itC)->getOperand(0); + if (itC->getType()->isPointerTy()) + return getConstantPointerRegister(dyn_cast<ConstantExpr>(c), elemID); + //else + // assert(0); I think the commented code is useless, you can remove it.
} _______________________________________________ Beignet mailing list Beignet@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/beignet