You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
hello Discopop!
I find Discopop will crash in following target code.
#include<vector>
#include<algorithm>
#include<iostream>usingnamespacestd;int a = 0;
intC(int a) {
int sum = 0;
vector<int> c {1,2,3,4,5,6,7,8};
for_each(c.begin(), c.end(), [&](int item) {
sum += item * a;
});
return sum;
}
intB() {
int b = 1;
a++;
returnC(a);
}
voidA() {
a = 100;
}
intmain()
{
A();
int b = B();
int c = C(2);
cout<<"b="<<b<<",c="<<c<<endl;
return0;
}
And , I find the bug is in Discopop/DiscoPoP.cpp
// Remove values from locals if dereferencedif (isa<StoreInst>(I)) {
V = I.getOperand(0);
for (Value *w : staticallyPredictableValues) {
if (w == V) {
staticallyPredictableValues.erase(V);
}
}
Hi @RainMolisa
this bug is one of multiples that should be fixed by the upcoming Release 4.0 (#615).
Until the release, i would suggest to try your code again using the DiscoPoP version in branch "release/4.0.0", as this is the most reliable state as of now.
I will try to prepare the release as soon as possible.
Regarding your code snippet: I have tested it and it did work with branch "release/4.0.0". If you encounter any issue, please feel free to let me know, I'll be happy to help!
hello Discopop!
I find Discopop will crash in following target code.
And , I find the bug is in Discopop/DiscoPoP.cpp
To fix the bug, I change the code into following:
It's work!
Best Wish!
The text was updated successfully, but these errors were encountered: