As Michael Zolotukhin noticed, skipping bitcast is not always correct.
The 'bitcast' may be skipped when the size of the pointee is the same.
Bitcast between GEP and load can not be skipped, and the load can not be vectorized in the following case:
%arrayidx = getelementptr inbounds double*, double** %in, i64 %indvars.iv %tmp53 = bitcast double** %arrayidx to i8* %tmp54 = load i8, i8* %tmp53, align 1
Skipping 'bitcast' in this case allows to vectorize load:
%arrayidx = getelementptr inbounds double*, double** %in, i64 %indvars.iv %tmp53 = bitcast double** %arrayidx to i64* %tmp54 = load i64, i64* %tmp53, align 8