From 17376c4e021b4357ae44c300c7316a53a1fab651 Mon Sep 17 00:00:00 2001 From: Artur Pilipenko Date: Mon, 3 Aug 2015 14:31:49 +0000 Subject: Currently string attributes on function arguments/return values can be generated using LLVM API. However they are not supported in parser. So, the following scenario will fail: * generate function with string attribute using API, * dump it in LL format, * try to parse. Add parser support for string attributes to fix the issue. Reviewed By: reames, hfinkel Differential Revision: http://reviews.llvm.org/D11058 llvm-svn: 243877 --- llvm/test/Bitcode/attributes.ll | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'llvm/test/Bitcode') diff --git a/llvm/test/Bitcode/attributes.ll b/llvm/test/Bitcode/attributes.ll index a0bc66642f7..0cf0745175e 100644 --- a/llvm/test/Bitcode/attributes.ll +++ b/llvm/test/Bitcode/attributes.ll @@ -262,6 +262,16 @@ define void @f44() argmemonly ret void; } +; CHECK: define "string_attribute" void @f45(i32 "string_attribute") +define "string_attribute" void @f45(i32 "string_attribute") { + ret void +} + +; CHECK: define "string_attribute_with_value"="value" void @f46(i32 "string_attribute_with_value"="value") +define "string_attribute_with_value"="value" void @f46(i32 "string_attribute_with_value"="value") { + ret void +} + ; CHECK: attributes #0 = { noreturn } ; CHECK: attributes #1 = { nounwind } ; CHECK: attributes #2 = { readnone } -- cgit v1.2.3