GCD test

According to this test, by comparing the indices of two arrays present in two or more statements, it can be calculated whether it is legal to parallelize the loop or not.

It is difficult to analyze array references in compile time to determine data dependency (whether they point to same address or not).

Loop code in general: To decide if there is loop carried dependence (two array references access the same memory location and one of them is a write operation) between a[x*i+k] and a[y*i+m], one usually[weasel words] needs to solve the equation[why?]

If GCD(x,y) does not divide (m-k) then both statements are independent and can be executed at parallel.

As 2 can not divide 1 properly (leaving remainder zero), there is no dependency between s1 and s2 and various other loop transformation methods can be applied.