Also, switch to a more clear 'sink' function with its declaration to
avoid any confusion about 'g'. Thanks for the suggestion Frits.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123113
91177308-0d34-0410-b5e6-
96231b3b80d8
void f(int N) {
std::vector<int> v(N);
- g(v);
+
+ extern void sink(void*); sink(&v);
}
into
void f(int N) {
std::vector<int> v(N);
- g(v);
+ for (int k = 0; k < N; ++k)
+ v[k] = 0;
+
+ extern void sink(void*); sink(&v);
}
into almost the same as the previous note, but replace its final BB with: