Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Function @verifier.assume has invalid attributes #68

Closed
foonathan opened this issue Sep 9, 2022 · 2 comments
Closed

Function @verifier.assume has invalid attributes #68

foonathan opened this issue Sep 9, 2022 · 2 comments

Comments

@foonathan
Copy link

When using clam to insert invariants, it declares a function @verifier.assume:

; Function Attrs: inaccessiblememonly norecurse nounwind optnone
declare void @verifier.assume(i1) #1

However, attempting to disassemble the bitcode to LLVM IR generates an error as the function should also have the noinline attribute:

Attribute 'optnone' requires 'noinline'!
void (i1)* @verifier.assume
LLVM ERROR: Broken module found, compilation aborted!

I had to patch LLVM to get the .ll file and see what's going on by removing the following line: https://github.com/llvm/llvm-project/blob/97d00b72a2b0a7aca631e1402a647f32c4e8bafb/llvm/lib/IR/Verifier.cpp#L2051-L2052

@caballa
Copy link
Contributor

caballa commented Sep 9, 2022

Fix in commit 6b68447.

@foonathan thanks for reporting it!

@caballa caballa closed this as completed Sep 9, 2022
@foonathan
Copy link
Author

Thanks for the quick fix!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants