From 58af6d1594778173f757131bdc25f850e00c7420 Mon Sep 17 00:00:00 2001 From: Peter Collingbourne Date: Mon, 15 Jun 2015 22:16:51 +0000 Subject: Add safestack attribute to LLVMAttribute enum and Go bindings. Correct constants in commented-out part of LLVMAttribute enum. Add tests that verify that the safestack attribute is only allowed as a function attribute. llvm-svn: 239772 --- llvm/bindings/go/llvm/ir.go | 2 ++ llvm/bindings/go/llvm/ir_test.go | 2 ++ 2 files changed, 4 insertions(+) (limited to 'llvm/bindings') diff --git a/llvm/bindings/go/llvm/ir.go b/llvm/bindings/go/llvm/ir.go index e5916a1bacf..1f00cd58473 100644 --- a/llvm/bindings/go/llvm/ir.go +++ b/llvm/bindings/go/llvm/ir.go @@ -160,6 +160,8 @@ const ( InAllocaAttribute Attribute = 1 << 43 NonNullAttribute Attribute = 1 << 44 JumpTableAttribute Attribute = 1 << 45 + ConvergentAttribute Attribute = 1 << 46 + SafeStackAttribute Attribute = 1 << 47 ) //------------------------------------------------------------------------- diff --git a/llvm/bindings/go/llvm/ir_test.go b/llvm/bindings/go/llvm/ir_test.go index 981c94aa63e..edeeab935db 100644 --- a/llvm/bindings/go/llvm/ir_test.go +++ b/llvm/bindings/go/llvm/ir_test.go @@ -53,6 +53,7 @@ func TestAttributes(t *testing.T) { {AlwaysInlineAttribute, "alwaysinline"}, {BuiltinAttribute, "builtin"}, {ByValAttribute, "byval"}, + {ConvergentAttribute, "convergent"}, {InAllocaAttribute, "inalloca"}, {InlineHintAttribute, "inlinehint"}, {InRegAttribute, "inreg"}, @@ -78,6 +79,7 @@ func TestAttributes(t *testing.T) { {ReturnedAttribute, "returned"}, {ReturnsTwiceAttribute, "returns_twice"}, {SExtAttribute, "signext"}, + {SafeStackAttribute, "safestack"}, {StackProtectAttribute, "ssp"}, {StackProtectReqAttribute, "sspreq"}, {StackProtectStrongAttribute, "sspstrong"}, -- cgit v1.2.3