summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/SelectionDAG
diff options
context:
space:
mode:
authorPete Cooper <peter_cooper@apple.com>2015-07-15 00:07:55 +0000
committerPete Cooper <peter_cooper@apple.com>2015-07-15 00:07:55 +0000
commit7e747d26c5434e2e6526fccf22a8931ca02aa387 (patch)
tree3131c4ab0965d50db115136d34bd274a06798850 /llvm/lib/CodeGen/SelectionDAG
parente2f8ce91e75e3e1b36b2cc2fbf52cdb00fbcfab2 (diff)
downloadbcm5719-llvm-7e747d26c5434e2e6526fccf22a8931ca02aa387.tar.gz
bcm5719-llvm-7e747d26c5434e2e6526fccf22a8931ca02aa387.zip
Use getStoreSize() instead of getStoreSizeInBits()/8. NFC.
The calls here were both to getStoreSizeInBits() which multiplies by 8. We then immediately divided by 8. Calling getStoreSize() returns the values we need without the extra arithmetic. llvm-svn: 242254
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG')
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
index 18c78b1f284..817ccb45c31 100644
--- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
@@ -1872,8 +1872,7 @@ SDValue SelectionDAG::CreateStackTemporary(EVT VT, unsigned minAlign) {
/// CreateStackTemporary - Create a stack temporary suitable for holding
/// either of the specified value types.
SDValue SelectionDAG::CreateStackTemporary(EVT VT1, EVT VT2) {
- unsigned Bytes = std::max(VT1.getStoreSizeInBits(),
- VT2.getStoreSizeInBits())/8;
+ unsigned Bytes = std::max(VT1.getStoreSize(), VT2.getStoreSize());
Type *Ty1 = VT1.getTypeForEVT(*getContext());
Type *Ty2 = VT2.getTypeForEVT(*getContext());
const DataLayout &DL = getDataLayout();
OpenPOWER on IntegriCloud