[llvm] r231334 - Revert r231104, "unique_ptrify FullDependenceAnalysis::DV", to appease msc18 C2280.
NAKAMURA Takumi
geek4civic at gmail.com
Wed Mar 4 17:25:06 PST 2015
Author: chapuni
Date: Wed Mar 4 19:25:06 2015
New Revision: 231334
URL: http://llvm.org/viewvc/llvm-project?rev=231334&view=rev
Log:
Revert r231104, "unique_ptrify FullDependenceAnalysis::DV", to appease msc18 C2280.
Modified:
llvm/trunk/include/llvm/Analysis/DependenceAnalysis.h
llvm/trunk/lib/Analysis/DependenceAnalysis.cpp
Modified: llvm/trunk/include/llvm/Analysis/DependenceAnalysis.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Analysis/DependenceAnalysis.h?rev=231334&r1=231333&r2=231334&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Analysis/DependenceAnalysis.h (original)
+++ llvm/trunk/include/llvm/Analysis/DependenceAnalysis.h Wed Mar 4 19:25:06 2015
@@ -221,6 +221,9 @@ namespace llvm {
Instruction *Dst,
bool LoopIndependent,
unsigned Levels);
+ ~FullDependence() {
+ delete[] DV;
+ }
/// isLoopIndependent - Returns true if this is a loop-independent
/// dependence.
@@ -267,7 +270,7 @@ namespace llvm {
unsigned short Levels;
bool LoopIndependent;
bool Consistent; // Init to true, then refine.
- std::unique_ptr<DVEntry[]> DV;
+ DVEntry *DV;
friend class DependenceAnalysis;
};
Modified: llvm/trunk/lib/Analysis/DependenceAnalysis.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Analysis/DependenceAnalysis.cpp?rev=231334&r1=231333&r2=231334&view=diff
==============================================================================
--- llvm/trunk/lib/Analysis/DependenceAnalysis.cpp (original)
+++ llvm/trunk/lib/Analysis/DependenceAnalysis.cpp Wed Mar 4 19:25:06 2015
@@ -226,12 +226,16 @@ bool Dependence::isScalar(unsigned level
//===----------------------------------------------------------------------===//
// FullDependence methods
-FullDependence::FullDependence(Instruction *Source, Instruction *Destination,
+FullDependence::FullDependence(Instruction *Source,
+ Instruction *Destination,
bool PossiblyLoopIndependent,
- unsigned CommonLevels)
- : Dependence(Source, Destination), Levels(CommonLevels),
- LoopIndependent(PossiblyLoopIndependent), Consistent(true),
- DV(CommonLevels ? new DVEntry[CommonLevels] : nullptr) {}
+ unsigned CommonLevels) :
+ Dependence(Source, Destination),
+ Levels(CommonLevels),
+ LoopIndependent(PossiblyLoopIndependent) {
+ Consistent = true;
+ DV = CommonLevels ? new DVEntry[CommonLevels] : nullptr;
+}
// The rest are simple getters that hide the implementation.
More information about the llvm-commits
mailing list