From b7141207a483d39b99c2b4da4eb3bb591eca9e1a Mon Sep 17 00:00:00 2001 From: Tim Northover Date: Thu, 30 May 2019 18:48:23 +0000 Subject: Reapply: IR: add optional type to 'byval' function parameters When we switch to opaque pointer types we will need some way to describe how many bytes a 'byval' parameter should occupy on the stack. This adds a (for now) optional extra type parameter. If present, the type must match the pointee type of the argument. The original commit did not remap byval types when linking modules, which broke LTO. This version fixes that. Note to front-end maintainers: if this causes test failures, it's probably because the "byval" attribute is printed after attributes without any parameter after this change. llvm-svn: 362128 --- llvm/test/Bitcode/attributes-3.3.ll | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'llvm/test/Bitcode/attributes-3.3.ll') diff --git a/llvm/test/Bitcode/attributes-3.3.ll b/llvm/test/Bitcode/attributes-3.3.ll index b564425c373..f1b37d19912 100644 --- a/llvm/test/Bitcode/attributes-3.3.ll +++ b/llvm/test/Bitcode/attributes-3.3.ll @@ -48,7 +48,7 @@ define void @f7(i8* noalias) } define void @f8(i8* byval) -; CHECK: define void @f8(i8* byval) +; CHECK: define void @f8(i8* byval(i8)) { ret void; } -- cgit v1.2.3