test commit
authorSriram Murali <sriram87@gmail.com>
Thu, 10 Oct 2013 20:24:53 +0000 (20:24 +0000)
committerSriram Murali <sriram87@gmail.com>
Thu, 10 Oct 2013 20:24:53 +0000 (20:24 +0000)
- fix comments on vector type legalization

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192389 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/Target/TargetLowering.h

index cd95a732234fa9e392e86c148b1a20c81a95eeb4..0130e07c49f2a264dcacd3068abc08e2050328b9 100644 (file)
@@ -1473,10 +1473,12 @@ public:
     if (NumElts == 1)
       return LegalizeKind(TypeScalarizeVector, EltVT);
 
-    // Try to widen vector elements until a legal type is found.
+    // Try to widen vector elements until the element type is a power of two and 
+    // promote it to a legal type later on, for example:
+    // <3 x i8> -> <4 x i8> -> <4 x i32>
     if (EltVT.isInteger()) {
       // Vectors with a number of elements that is not a power of two are always
-      // widened, for example <3 x float> -> <4 x float>.
+      // widened, for example <3 x i8> -> <4 x i8>.
       if (!VT.isPow2VectorType()) {
         NumElts = (unsigned)NextPowerOf2(NumElts);
         EVT NVT = EVT::getVectorVT(Context, EltVT, NumElts);