Splitting the spectral flow and the Alexander matrix