Hi Gerard,
The AIC3104 is a very low cost portable codec. It was designed for portable consumer applications such as cell phones. Although it has found many useful homes in other applications, the AGC was designed as a very simple AGC for voice band microphone type applications. The AGC topology we use doesn't do well with pure sine wave type signals. If you use a recorded voice signal, you will see that the results will be pretty good. With sine waves, there can be some issues.
The PGA in the AIC3104 is very linear up to about 25 dB, after that it starts to run out of performance.