From 557d92fff7fd0425c0fd54d1290a2f6923eca808 Mon Sep 17 00:00:00 2001
From: wsmoses
opt input.ll -load=/path/to/LLVMEnzyme-VERSION.so -passes=enzyme -o output.ll -S
If you are using CMake, Enzyme exports a special ClangEnzymeFlags
target which will automatically add the correct flags. See
here
-for an example.
Until June 2020, LLVM’s exisitng GVN pass had a bug handling invariant.load’s that would cause it to crash. These tend to be generated a lot by Enzyme for better optimization. This was reported -here -and resolved in master. Options for resolving include updating to later verison of LLVM with the fix, or disabling creation of invariant.load’s.
If you have an issue not resolved here, please make an issue on +for an example.
If you have an issue not resolved here, please make an issue on Github and consider making a pull request to this FAQ!