Skip to content

Commit 975a23c

Browse files
stepasitewsmoses
authored andcommitted
Llvm 16 (#2)
* fix for argmemonly
1 parent b954bed commit 975a23c

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

enzyme/Enzyme/AdjointGenerator.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,9 @@ class AdjointGenerator
193193
#if LLVM_VERSION_MAJOR >= 14
194194
#if LLVM_VERSION_MAJOR >= 16
195195
AL = AL.addAttributeAtIndex(DT->getContext(), AttributeList::FunctionIndex,
196-
Attribute::AttrKind::Memory);
196+
Attribute::getWithMemoryEffects(
197+
DT->getContext(),
198+
llvm::MemoryEffects::argMemOnly()));
197199
#else
198200
AL = AL.addAttributeAtIndex(DT->getContext(), AttributeList::FunctionIndex,
199201
Attribute::AttrKind::ArgMemOnly);

0 commit comments

Comments
 (0)