Techniques are provided for use with implantable medical devices such as pacemakers for optimizing atrioventricular (AV) pacing delays for use with cardiac resynchronization therapy (CRT). In one example, the end of atrial mechanical contraction and the onset of isovolumic ventricular mechanical contraction are detected within a patient in which the device is implanted based on cardiomechanical signals, such as cardiogenic impedance (Z) signals, S1 heart sounds or left atrial pressure (LAP) signals. Then, a cardiomechanical time delay (MC_AV) between the end of atrial contraction and the onset of isovolumic ventricular contraction is determined. AV pacing delays are set based on MC_AV to align the end an atrial kick with the onset of isovolumic ventricular contraction. Thereafter, pacing is controlled based on the AV pacing delays.