Using the Analog Comparator and the ADC on the Mega2560

The DIDR1 register does not influence the comparator operation. It only modifies the behaviour of AIN0/1 as digital inputs.
But ACSR.ACBG can be used to replace the external AIN0 signal by the internal bandgap reference.