Respect alignments better.

llvm-svn: 83328
diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp
index fdc9740..f7fe69e 100644
--- a/clang/lib/CodeGen/CodeGenModule.cpp
+++ b/clang/lib/CodeGen/CodeGenModule.cpp
@@ -345,6 +345,9 @@
 
   if (D->hasAttr<NoInlineAttr>())
     F->addFnAttr(llvm::Attribute::NoInline);
+
+  if (const AlignedAttr *AA = D->getAttr<AlignedAttr>())
+    F->setAlignment(AA->getAlignment()/8);
 }
 
 void CodeGenModule::SetCommonAttributes(const Decl *D,