summaryrefslogtreecommitdiff
path: root/compiler/llvmGen/Llvm/MetaData.hs
diff options
context:
space:
mode:
authorBen Gamari <ben@smart-cactus.org>2017-09-15 19:14:02 -0400
committerBen Gamari <ben@smart-cactus.org>2017-09-15 19:42:04 -0400
commit6448322d7bc56c2b435b9bfda50430c0d0748a22 (patch)
tree32c5f411494fc58aa1cfecab2c08208ba62af0ad /compiler/llvmGen/Llvm/MetaData.hs
parentfc2de303e0a53392d4ab987131608bc6bdbd81db (diff)
downloadhaskell-wip/llvm-debug-info.tar.gz
Fix distinctionwip/llvm-debug-info
Diffstat (limited to 'compiler/llvmGen/Llvm/MetaData.hs')
-rw-r--r--compiler/llvmGen/Llvm/MetaData.hs7
1 files changed, 5 insertions, 2 deletions
diff --git a/compiler/llvmGen/Llvm/MetaData.hs b/compiler/llvmGen/Llvm/MetaData.hs
index 8215870a19..049d28733d 100644
--- a/compiler/llvmGen/Llvm/MetaData.hs
+++ b/compiler/llvmGen/Llvm/MetaData.hs
@@ -140,11 +140,14 @@ specialMetadata nodeName fields =
data MetaAnnot = MetaAnnot LMString MetaExpr
deriving (Eq)
+-- | Is a metadata node @distinct@?
+data Distinction = Distinct | NotDistinct
+
-- | Metadata declarations. Metadata can only be declared in global scope.
data MetaDecl
-- | Named metadata. Only used for communicating module information to
-- LLVM. ('!name = !{ [!<n>] }' form).
- = MetaNamed !LMString [MetaId]
+ = MetaNamed !LMString Distinction [MetaId]
-- | Metadata node declaration.
-- ('!0 = metadata !{ <metadata expression> }' form).
- | MetaUnnamed !MetaId !MetaExpr
+ | MetaUnnamed !MetaId Distinction !MetaExpr