Work around MSVC "friend" semantics.
The error on clang-x86-win2008-selfhost is:
C:\buildbot\slave-config\clang-x86-win2008-selfhost\llvm\lib\Transforms\Vectorize\SLPVectorizer.cpp(955) : error C2248: 'llvm::slpvectorizer::BoUpSLP::ScheduleData' : cannot access private struct declared in class 'llvm::slpvectorizer::BoUpSLP'
C:\buildbot\slave-config\clang-x86-win2008-selfhost\llvm\lib\Transforms\Vectorize\SLPVectorizer.cpp(608) : see declaration of 'llvm::slpvectorizer::BoUpSLP::ScheduleData'
C:\buildbot\slave-config\clang-x86-win2008-selfhost\llvm\lib\Transforms\Vectorize\SLPVectorizer.cpp(337) : see declaration of 'llvm::slpvectorizer::BoUpSLP'
I reproduced this locally with both MSVC 2013 and MSVC 2015.
llvm-svn: 272772
This commit is contained in:
@@ -601,6 +601,7 @@ private:
|
||||
/// A list of blocks that we are going to CSE.
|
||||
SetVector<BasicBlock *> CSEBlocks;
|
||||
|
||||
public: // Workaround for MSVC friend semantics.
|
||||
/// Contains all scheduling relevant data for an instruction.
|
||||
/// A ScheduleData either represents a single instruction or a member of an
|
||||
/// instruction bundle (= a group of instructions which is combined into a
|
||||
@@ -730,6 +731,7 @@ private:
|
||||
/// dry-run).
|
||||
bool IsScheduled;
|
||||
};
|
||||
private:
|
||||
|
||||
#ifndef NDEBUG
|
||||
friend raw_ostream &operator<<(raw_ostream &os,
|
||||
|
||||
Reference in New Issue
Block a user