llvm.org GIT mirror llvm / f6283fd
Make some static variables const. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47566 91177308-0d34-0410-b5e6-96231b3b80d8 Dan Gohman 12 years ago
1 changed file(s) with 3 addition(s) and 3 deletion(s). Raw diff Collapse all Expand all
65426542 bool isSigned = Node->getOpcode() == ISD::SINT_TO_FP;
65436543 MVT::ValueType SrcVT = Node->getOperand(0).getValueType();
65446544 if (VT == MVT::ppcf128 && SrcVT != MVT::i64) {
6545 static uint64_t zero = 0;
6545 static const uint64_t zero = 0;
65466546 if (isSigned) {
65476547 Hi = LegalizeOp(DAG.getNode(ISD::SINT_TO_FP, MVT::f64,
65486548 Node->getOperand(0)));
65496549 Lo = DAG.getConstantFP(APFloat(APInt(64, 1, &zero)), MVT::f64);
65506550 } else {
6551 static uint64_t TwoE32[] = { 0x41f0000000000000LL, 0 };
6551 static const uint64_t TwoE32[] = { 0x41f0000000000000LL, 0 };
65526552 Hi = LegalizeOp(DAG.getNode(ISD::SINT_TO_FP, MVT::f64,
65536553 Node->getOperand(0)));
65546554 Lo = DAG.getConstantFP(APFloat(APInt(64, 1, &zero)), MVT::f64);
65686568 }
65696569 if (VT == MVT::ppcf128 && SrcVT == MVT::i64 && !isSigned) {
65706570 // si64->ppcf128 done by libcall, below
6571 static uint64_t TwoE64[] = { 0x43f0000000000000LL, 0 };
6571 static const uint64_t TwoE64[] = { 0x43f0000000000000LL, 0 };
65726572 ExpandOp(DAG.getNode(ISD::SINT_TO_FP, MVT::ppcf128, Node->getOperand(0)),
65736573 Lo, Hi);
65746574 Hi = DAG.getNode(ISD::BUILD_PAIR, VT, Lo, Hi);