summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/TargetInfo.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang/lib/CodeGen/TargetInfo.cpp')
-rw-r--r--clang/lib/CodeGen/TargetInfo.cpp14
1 files changed, 0 insertions, 14 deletions
diff --git a/clang/lib/CodeGen/TargetInfo.cpp b/clang/lib/CodeGen/TargetInfo.cpp
index 473b312b42b..12341431ac0 100644
--- a/clang/lib/CodeGen/TargetInfo.cpp
+++ b/clang/lib/CodeGen/TargetInfo.cpp
@@ -6656,20 +6656,6 @@ public:
void setTargetAttributes(const Decl *D, llvm::GlobalValue *GV,
CodeGen::CodeGenModule &CGM,
ForDefinition_t IsForDefinition) const override {
-
- if (const VarDecl *VD = dyn_cast_or_null<VarDecl>(D)) {
- if (CGM.getCodeGenOpts().UInitCstDataInROData &&
- VD->getType().isConstQualified() && !VD->hasInit()) {
- llvm::GlobalVariable *GVar = dyn_cast_or_null<llvm::GlobalVariable>(GV);
- if (GVar && !GVar->hasSection()) {
- GVar->setLinkage(llvm::GlobalValue::ExternalLinkage);
- GVar->setSection("rodata");
- }
- }
-
- return;
- }
-
const FunctionDecl *FD = dyn_cast_or_null<FunctionDecl>(D);
if (!FD) return;
llvm::Function *Fn = cast<llvm::Function>(GV);
OpenPOWER on IntegriCloud