I think it's less noisy to not use isPtrOrPtrVectorTy() and then again isVectorTy() in some places, and instead use a combination of dyn_cast and taking the scalar type, but it's fine as is. http://llvm-reviews.chandlerc.com/D1401