aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/SelectionDAG/TargetLowering.cpp
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2007-06-21 14:42:22 +0000
committerDan Gohman <gohman@apple.com>2007-06-21 14:42:22 +0000
commitb9f10196961ebe5b5573a5705048a5a8a6b56bb3 (patch)
treef1927288f7daf6bc71c1375869417dae4a428ca7 /lib/CodeGen/SelectionDAG/TargetLowering.cpp
parent53855ca95c8fd6b61a3cba4782eb280bb1830c2b (diff)
Rename TargetLowering::getNumElements and friends to
TargetLowering::getNumRegisters and similar, to avoid confusion with the actual number of elements for vector types. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37687 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/SelectionDAG/TargetLowering.cpp')
-rw-r--r--lib/CodeGen/SelectionDAG/TargetLowering.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/CodeGen/SelectionDAG/TargetLowering.cpp b/lib/CodeGen/SelectionDAG/TargetLowering.cpp
index 30ada12bc7..f5bb9c7ee5 100644
--- a/lib/CodeGen/SelectionDAG/TargetLowering.cpp
+++ b/lib/CodeGen/SelectionDAG/TargetLowering.cpp
@@ -216,7 +216,7 @@ void TargetLowering::computeRegisterProperties() {
// Everything defaults to one.
for (unsigned i = 0; i != MVT::LAST_VALUETYPE; ++i)
- NumElementsForVT[i] = 1;
+ NumRegistersForVT[i] = 1;
// Find the largest integer register class.
unsigned LargestIntReg = MVT::i128;
@@ -227,12 +227,12 @@ void TargetLowering::computeRegisterProperties() {
// many registers to represent as the previous ValueType.
unsigned ExpandedReg = LargestIntReg; ++LargestIntReg;
for (++ExpandedReg; MVT::isInteger((MVT::ValueType)ExpandedReg);++ExpandedReg)
- NumElementsForVT[ExpandedReg] = 2*NumElementsForVT[ExpandedReg-1];
+ NumRegistersForVT[ExpandedReg] = 2*NumRegistersForVT[ExpandedReg-1];
// Inspect all of the ValueType's possible, deciding how to process them.
for (unsigned IntReg = MVT::i1; IntReg <= MVT::i128; ++IntReg)
// If we are expanding this type, expand it!
- if (getNumElements((MVT::ValueType)IntReg) != 1)
+ if (getNumRegisters((MVT::ValueType)IntReg) != 1)
SetValueTypeAction((MVT::ValueType)IntReg, Expand, *this, TransformToType,
ValueTypeActions);
else if (!isTypeLegal((MVT::ValueType)IntReg))
@@ -250,7 +250,7 @@ void TargetLowering::computeRegisterProperties() {
if (isTypeLegal(MVT::f64))
TransformToType[MVT::f64] = MVT::f64;
else {
- NumElementsForVT[MVT::f64] = NumElementsForVT[MVT::i64];
+ NumRegistersForVT[MVT::f64] = NumRegistersForVT[MVT::i64];
SetValueTypeAction(MVT::f64, Expand, *this, TransformToType,
ValueTypeActions);
}
@@ -260,7 +260,7 @@ void TargetLowering::computeRegisterProperties() {
SetValueTypeAction(MVT::f32, Promote, *this, TransformToType,
ValueTypeActions);
else {
- NumElementsForVT[MVT::f32] = NumElementsForVT[MVT::i32];
+ NumRegistersForVT[MVT::f32] = NumRegistersForVT[MVT::i32];
SetValueTypeAction(MVT::f32, Expand, *this, TransformToType,
ValueTypeActions);
}