-
Notifications
You must be signed in to change notification settings - Fork 1
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
Different iterator instructions reported in seemingly identical loops #1
Comments
Hey! This is a quick response, but I'll look into it in depth later today. So, without having a look at the attached files, I'd say that the IR generated is different because of |
A short update: It seems that the control dependence graph (CDG) generated for |
@robcasloz This was an issue with Pedigree, so I opened an issue for it here and it is hopefully address in the referenced PR. Please try it and let me know. |
Hi @compor, I tried the PR and it works just fine, now the same instructions are reported as iterators in both cases. Thanks! |
Cool! I'm closing this since it was addressed here. |
Hi Chris, thanks for the effort you put maintaining this library :)
In a simple single-loop function, the iterator recognition pass reports different LLVM IR instructions as belonging to the loop's iterator depending on whether the function returns:
or exits:
The loops are identical in both cases, so I would expect the same instructions to be reported.
How to reproduce
clang -emit-llvm -S foo.c -o foo.ll
(foo.c
is available here: foo.c.zip).opt -itr-annotate -S foo.ll -o foo-itr.ll
.grep "iterator \!2" foo-itr.ll
andgrep "iterator \!3" foo-itr.ll
produce the same output. Currently, this step fails.Thank you for your time! Let me know if I can help in any way.
The text was updated successfully, but these errors were encountered: