summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/TargetAttributesSema.cpp
diff options
context:
space:
mode:
authorEli Friedman <eli.friedman@gmail.com>2011-09-30 18:53:25 +0000
committerEli Friedman <eli.friedman@gmail.com>2011-09-30 18:53:25 +0000
commit271002fc9928c04aa9319b1a537b6771c87c06e3 (patch)
treed0d88f710d85322029c254f507e58aa5801bec1c /clang/lib/Sema/TargetAttributesSema.cpp
parent7ba8a8d656b4ef9413bd8b41274eeda06897dc37 (diff)
downloadbcm5719-llvm-271002fc9928c04aa9319b1a537b6771c87c06e3.tar.gz
bcm5719-llvm-271002fc9928c04aa9319b1a537b6771c87c06e3.zip
Support dllimport and dllexport on x86-64 Windows. PR10978. Patch by Ruben Van Boxem.
llvm-svn: 140871
Diffstat (limited to 'clang/lib/Sema/TargetAttributesSema.cpp')
-rw-r--r--clang/lib/Sema/TargetAttributesSema.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/clang/lib/Sema/TargetAttributesSema.cpp b/clang/lib/Sema/TargetAttributesSema.cpp
index 877bc32521a..3a065cead50 100644
--- a/clang/lib/Sema/TargetAttributesSema.cpp
+++ b/clang/lib/Sema/TargetAttributesSema.cpp
@@ -248,7 +248,8 @@ namespace {
default: break;
}
}
- if (Attr.getName()->getName() == "force_align_arg_pointer" ||
+ if (Triple.getArch() != llvm::Triple::x86_64 &&
+ Attr.getName()->getName() == "force_align_arg_pointer" ||
Attr.getName()->getName() == "__force_align_arg_pointer__") {
HandleX86ForceAlignArgPointerAttr(D, Attr, S);
return true;
@@ -264,14 +265,14 @@ const TargetAttributesSema &Sema::getTargetAttributesSema() const {
const llvm::Triple &Triple(Context.getTargetInfo().getTriple());
switch (Triple.getArch()) {
- default:
- return *(TheTargetAttributesSema = new TargetAttributesSema);
-
case llvm::Triple::msp430:
return *(TheTargetAttributesSema = new MSP430AttributesSema);
case llvm::Triple::mblaze:
return *(TheTargetAttributesSema = new MBlazeAttributesSema);
case llvm::Triple::x86:
+ case llvm::Triple::x86_64:
return *(TheTargetAttributesSema = new X86AttributesSema);
+ default:
+ return *(TheTargetAttributesSema = new TargetAttributesSema);
}
}
OpenPOWER on IntegriCloud