diff options
author | Duncan Sands <baldrick@free.fr> | 2008-11-06 08:51:32 +0000 |
---|---|---|
committer | Duncan Sands <baldrick@free.fr> | 2008-11-06 08:51:32 +0000 |
commit | f178f8300def4fba515aea09c294da6a521eb1cd (patch) | |
tree | 3336ef24a81870f6681755bd3ff0476f9e3403d4 | |
parent | 47b546d75f5ad4f67d10615bfc3a764cff5c6abf (diff) | |
download | bcm5719-llvm-f178f8300def4fba515aea09c294da6a521eb1cd.tar.gz bcm5719-llvm-f178f8300def4fba515aea09c294da6a521eb1cd.zip |
Formating/comment changes - no functionality change.
llvm-svn: 58801
-rw-r--r-- | llvm/lib/CodeGen/SelectionDAG/LegalizeTypes.h | 21 |
1 files changed, 8 insertions, 13 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/LegalizeTypes.h b/llvm/lib/CodeGen/SelectionDAG/LegalizeTypes.h index 172a46e73e7..1d1ed349441 100644 --- a/llvm/lib/CodeGen/SelectionDAG/LegalizeTypes.h +++ b/llvm/lib/CodeGen/SelectionDAG/LegalizeTypes.h @@ -80,20 +80,15 @@ private: return Legal; case TargetLowering::Promote: // Promote can mean - // 1) On integers, use the promote integer type (e.g., i8 to i32) - // 2) For vectors, use the widen vector type returned by the target - // (e.g., v3i32 to v4i32). If the type is the same as the original - // type, than expand the vector instead. - if (!VT.isVector()) { + // 1) For integers, use a larger integer type (e.g. i8 -> i32). + // 2) For vectors, use a wider vector type (e.g. v3i32 -> v4i32). + if (!VT.isVector()) return PromoteInteger; - } else { - // TODO: move widen code to LegalizeType. - if (VT.getVectorNumElements() == 1) { - return ScalarizeVector; - } else { - return SplitVector; - } - } + else if (VT.getVectorNumElements() == 1) + return ScalarizeVector; + else + // TODO: move widen code to LegalizeTypes. + return SplitVector; case TargetLowering::Expand: // Expand can mean // 1) split scalar in half, 2) convert a float to an integer, |