| Index: src/IceConverter.cpp
|
| diff --git a/src/IceConverter.cpp b/src/IceConverter.cpp
|
| index 387128909b51d393744878ce0e9e31a119356390..cc185ae29b221db969d208e7c667f2ce422ce58a 100644
|
| --- a/src/IceConverter.cpp
|
| +++ b/src/IceConverter.cpp
|
| @@ -101,7 +101,7 @@ public:
|
|
|
| VarMap.clear();
|
| NodeMap.clear();
|
| - Func->setFunctionName(F->getName());
|
| + Func->setFunctionName(Ice::GlobalContext::mangleName(F->getName()));
|
| Func->setReturnType(convertToIceType(F->getReturnType()));
|
| Func->setInternal(F->hasInternalLinkage());
|
| Ice::TimerMarker T(Ice::TimerStack::TT_llvmConvert, Func.get());
|
| @@ -141,8 +141,7 @@ public:
|
| return Ctx->getConstantExternSym(Decl->getName());
|
| else {
|
| const Ice::RelocOffsetT Offset = 0;
|
| - return Ctx->getConstantSym(Offset, Decl->getName(),
|
| - Decl->getSuppressMangling());
|
| + return Ctx->getConstantSym(Offset, Decl->getName());
|
| }
|
| } else if (const auto CI = dyn_cast<ConstantInt>(Const)) {
|
| Ice::Type Ty = convertToIceType(CI->getType());
|
| @@ -889,11 +888,12 @@ void Converter::installGlobalDeclarations(Module *Mod) {
|
| E = Mod->global_end();
|
| I != E; ++I) {
|
| const GlobalVariable *GV = I;
|
| - auto *Var = VariableDeclaration::create(Ctx);
|
| - Var->setName(GV->getName());
|
| + constexpr bool NoSuppressMangling = false;
|
| + auto *Var =
|
| + VariableDeclaration::create(Ctx, NoSuppressMangling, GV->getLinkage());
|
| Var->setAlignment(GV->getAlignment());
|
| Var->setIsConstant(GV->isConstant());
|
| - Var->setLinkage(GV->getLinkage());
|
| + Var->setName(GV->getName());
|
| if (!Var->verifyLinkageCorrect(Ctx)) {
|
| std::string Buffer;
|
| raw_string_ostream StrBuf(Buffer);
|
|
|