mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-04-04 10:30:01 +00:00
Tblgen was generating syntactically illegal C++ code like:
SDOperand Tmp0,Tmp1,Tmp2,Tmp3,; GCC has a bug (24907) in which is fails to catch this, but VC++ correctly notes its illegality, so tblgen must be taught to only generate legal C++. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25075 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
84e1064f45
commit
f356d70ec3
@ -2030,12 +2030,13 @@ public:
|
||||
std::string Fn = CP->getSelectFunc();
|
||||
NumRes = CP->getNumOperands();
|
||||
OS << " SDOperand ";
|
||||
for (unsigned i = 0; i != NumRes; ++i)
|
||||
unsigned i;
|
||||
for (i = 0; i < NumRes - 1; ++i)
|
||||
OS << "Tmp" << (i+ResNo) << ",";
|
||||
OS << ";\n";
|
||||
OS << "Tmp" << (i+ResNo) << ";\n";
|
||||
|
||||
OS << " if (!" << Fn << "(" << Val;
|
||||
for (unsigned i = 0; i < NumRes; i++)
|
||||
for (i = 0; i < NumRes; i++)
|
||||
OS << ", Tmp" << i + ResNo;
|
||||
OS << ")) goto P" << PatternNo << "Fail;\n";
|
||||
TmpNo = ResNo + NumRes;
|
||||
|
Loading…
x
Reference in New Issue
Block a user