aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorAnton Korobeynikov <asl@math.spbu.ru>2008-08-07 09:51:54 +0000
committerAnton Korobeynikov <asl@math.spbu.ru>2008-08-07 09:51:54 +0000
commit80475a585c8ad6e892e47d9d34ccd3eae953ad6e (patch)
tree9593b5067819f835033d2036a94f2c8bad6e2d51 /include
parentdb9a895bab6918b2319cc55c1989c0183a1e6434 (diff)
downloadexternal_llvm-80475a585c8ad6e892e47d9d34ccd3eae953ad6e.zip
external_llvm-80475a585c8ad6e892e47d9d34ccd3eae953ad6e.tar.gz
external_llvm-80475a585c8ad6e892e47d9d34ccd3eae953ad6e.tar.bz2
Provide convenient helpers
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54451 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
-rw-r--r--include/llvm/Target/TargetAsmInfo.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/include/llvm/Target/TargetAsmInfo.h b/include/llvm/Target/TargetAsmInfo.h
index e20a6c8..04e91cb 100644
--- a/include/llvm/Target/TargetAsmInfo.h
+++ b/include/llvm/Target/TargetAsmInfo.h
@@ -45,6 +45,18 @@ namespace llvm {
ThreadData, ///< Initialized TLS data objects
ThreadBSS ///< Uninitialized TLS data objects
};
+
+ static inline bool isReadOnly(Kind K) {
+ return (K == SectionKind::ROData ||
+ K == SectionKind::RODataMergeConst ||
+ K == SectionKind::RODataMergeStr ||
+ K == SectionKind::SmallROData);
+ }
+
+ static inline bool isBSS(Kind K) {
+ return (K == SectionKind::BSS ||
+ K == SectionKind::SmallBSS);
+ }
}
namespace SectionFlags {