mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-09-14 15:25:25 +00:00
Regenerate.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35237 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
File diff suppressed because it is too large
Load Diff
@@ -2936,20 +2936,16 @@ FunctionHeaderH
|
|||||||
CurModule.RenameMap[Key] = Conflict->getName();
|
CurModule.RenameMap[Key] = Conflict->getName();
|
||||||
Fn = new Function(FT, CurFun.Linkage, FunctionName, M);
|
Fn = new Function(FT, CurFun.Linkage, FunctionName, M);
|
||||||
InsertValue(Fn, CurModule.Values);
|
InsertValue(Fn, CurModule.Values);
|
||||||
} else if (CurFun.Linkage == GlobalValue::InternalLinkage) {
|
|
||||||
// We can safely rename the function we're defining
|
|
||||||
std::string NewName = makeNameUnique(FunctionName);
|
|
||||||
Fn = new Function(FT, CurFun.Linkage, NewName, M);
|
|
||||||
InsertValue(Fn, CurModule.Values);
|
|
||||||
RenameMapKey Key = makeRenameMapKey(FunctionName, PFT, ID.S);
|
|
||||||
CurModule.RenameMap[Key] = NewName;
|
|
||||||
} else {
|
} else {
|
||||||
// We can't quietly rename either of these things, but we must
|
// We can't quietly rename either of these things, but we must
|
||||||
// rename one of them. Generate a warning about the renaming and
|
// rename one of them. Only if the function's linkage is internal can
|
||||||
// elect to rename the thing we're now defining.
|
// we forgo a warning message about the renamed function.
|
||||||
std::string NewName = makeNameUnique(FunctionName);
|
std::string NewName = makeNameUnique(FunctionName);
|
||||||
|
if (CurFun.Linkage != GlobalValue::InternalLinkage) {
|
||||||
warning("Renaming function '" + FunctionName + "' as '" + NewName +
|
warning("Renaming function '" + FunctionName + "' as '" + NewName +
|
||||||
"' may cause linkage errors");
|
"' may cause linkage errors");
|
||||||
|
}
|
||||||
|
// Elect to rename the thing we're now defining.
|
||||||
Fn = new Function(FT, CurFun.Linkage, NewName, M);
|
Fn = new Function(FT, CurFun.Linkage, NewName, M);
|
||||||
InsertValue(Fn, CurModule.Values);
|
InsertValue(Fn, CurModule.Values);
|
||||||
RenameMapKey Key = makeRenameMapKey(FunctionName, PFT, ID.S);
|
RenameMapKey Key = makeRenameMapKey(FunctionName, PFT, ID.S);
|
||||||
@@ -3005,7 +3001,7 @@ BEGIN
|
|||||||
;
|
;
|
||||||
|
|
||||||
FunctionHeader
|
FunctionHeader
|
||||||
: OptLinkage FunctionHeaderH BEGIN {
|
: OptLinkage { CurFun.Linkage = $1; } FunctionHeaderH BEGIN {
|
||||||
$$ = CurFun.CurrentFunction;
|
$$ = CurFun.CurrentFunction;
|
||||||
|
|
||||||
// Make sure that we keep track of the linkage type even if there was a
|
// Make sure that we keep track of the linkage type even if there was a
|
||||||
|
Reference in New Issue
Block a user