[llvm-branch-commits] [llvm-gcc-branch] r102967 - in /llvm-gcc-4.2/branches/Apple/Morbo/gcc: llvm-backend.cpp llvm-convert.cpp
Bill Wendling
isanbard at gmail.com
Mon May 3 15:28:25 PDT 2010
Author: void
Date: Mon May 3 17:28:25 2010
New Revision: 102967
URL: http://llvm.org/viewvc/llvm-project?rev=102967&view=rev
Log:
Revert r102947.
Modified:
llvm-gcc-4.2/branches/Apple/Morbo/gcc/llvm-backend.cpp
llvm-gcc-4.2/branches/Apple/Morbo/gcc/llvm-convert.cpp
Modified: llvm-gcc-4.2/branches/Apple/Morbo/gcc/llvm-backend.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/branches/Apple/Morbo/gcc/llvm-backend.cpp?rev=102967&r1=102966&r2=102967&view=diff
==============================================================================
--- llvm-gcc-4.2/branches/Apple/Morbo/gcc/llvm-backend.cpp (original)
+++ llvm-gcc-4.2/branches/Apple/Morbo/gcc/llvm-backend.cpp Mon May 3 17:28:25 2010
@@ -1375,12 +1375,8 @@
} else if (!TREE_PUBLIC(decl)) {
Linkage = GlobalValue::InternalLinkage;
} else if (DECL_WEAK(decl)) {
- if (DECL_ONE_ONLY(decl) &&
- !lookup_attribute("weak", DECL_ATTRIBUTES(decl)))
- Linkage = GlobalValue::getWeakLinkage(flag_odr);
- else
- // The user may have explicitly asked for weak linkage - ignore flag_odr.
- Linkage = GlobalValue::WeakAnyLinkage;
+ // The user may have explicitly asked for weak linkage - ignore flag_odr.
+ Linkage = GlobalValue::WeakAnyLinkage;
} else if (DECL_ONE_ONLY(decl)) {
Linkage = GlobalValue::getWeakLinkage(flag_odr);
} else if (DECL_COMMON(decl) && // DECL_COMMON is only meaningful if no init
Modified: llvm-gcc-4.2/branches/Apple/Morbo/gcc/llvm-convert.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/branches/Apple/Morbo/gcc/llvm-convert.cpp?rev=102967&r1=102966&r2=102967&view=diff
==============================================================================
--- llvm-gcc-4.2/branches/Apple/Morbo/gcc/llvm-convert.cpp (original)
+++ llvm-gcc-4.2/branches/Apple/Morbo/gcc/llvm-convert.cpp Mon May 3 17:28:25 2010
@@ -545,12 +545,8 @@
} else if (DECL_COMDAT(FnDecl)) {
Fn->setLinkage(Function::getLinkOnceLinkage(flag_odr));
} else if (DECL_WEAK(FnDecl)) {
- if (DECL_ONE_ONLY(FnDecl) &&
- !lookup_attribute("weak", DECL_ATTRIBUTES(FnDecl)))
- Fn->setLinkage(Function::getWeakLinkage(flag_odr));
- else
- // The user may have explicitly asked for weak linkage - ignore flag_odr.
- Fn->setLinkage(Function::WeakAnyLinkage);
+ // The user may have explicitly asked for weak linkage - ignore flag_odr.
+ Fn->setLinkage(Function::WeakAnyLinkage);
} else if (DECL_ONE_ONLY(FnDecl)) {
Fn->setLinkage(Function::getWeakLinkage(flag_odr));
}
More information about the llvm-branch-commits
mailing list