The amplification is a simple control task. I think that it is not an easy task to find an optimal control function for a d-class switch. Especially, because the task is complicated by unknown output stage characteristics, which vary from circuit to circuit.
A 100 mhz ANN running on an FPGA could easily control a 1 MHz gate, IMO. It could also monitor and take the efficiency into account (because the best quality is at infinite frequency, where the efficiency is zero) by comparing the input and load currents. Is it an overkill for such a simple task? Do existing d-amplifiers provide much better price-quality relationship?