summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CodeGenModule.h
diff options
context:
space:
mode:
authorEli Friedman <eli.friedman@gmail.com>2008-06-01 15:54:49 +0000
committerEli Friedman <eli.friedman@gmail.com>2008-06-01 15:54:49 +0000
commitf6b091f73a0e841fda5d5eb2214a7fa563ca8a2b (patch)
treed06ca66bb2c15691ddf5be45919ad7a5f215e219 /clang/lib/CodeGen/CodeGenModule.h
parent10c2417570d51b330f54842c2f9f4c92d1f560ca (diff)
downloadbcm5719-llvm-f6b091f73a0e841fda5d5eb2214a7fa563ca8a2b.tar.gz
bcm5719-llvm-f6b091f73a0e841fda5d5eb2214a7fa563ca8a2b.zip
First cut at setting attributes for functions and calls; this puts us
much closer to passing the gcc struct layout tests. It might be possible to refactor this a bit, but I'm not sure there's actually enough common code for that to be useful. To get the calling convention completely correct, a bit of platform-specific code is necessary even for x86-Linux. On x86-Linux, the alignment of function parameters is extremely strange; as far as I can tell, it's always 4 except for SSE vectors or structs containing SSE vectors. I'm continuing to investigate this. llvm-svn: 51839
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.h')
-rw-r--r--clang/lib/CodeGen/CodeGenModule.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/clang/lib/CodeGen/CodeGenModule.h b/clang/lib/CodeGen/CodeGenModule.h
index 3e775260676..de2995f6a8c 100644
--- a/clang/lib/CodeGen/CodeGenModule.h
+++ b/clang/lib/CodeGen/CodeGenModule.h
@@ -26,6 +26,7 @@ namespace llvm {
class Function;
class GlobalValue;
class TargetData;
+ class FunctionType;
}
namespace clang {
@@ -149,6 +150,10 @@ private:
/// searches for any entries in GlobalDeclMap that point to OldVal, changing
/// them to point to NewVal. This is badbadbad, FIXME!
void ReplaceMapValuesWith(llvm::Constant *OldVal, llvm::Constant *NewVal);
+
+ void SetFunctionAttributes(const FunctionDecl *FD,
+ llvm::Function *F,
+ const llvm::FunctionType *FTy);
};
} // end namespace CodeGen
OpenPOWER on IntegriCloud