[1] - https://beta.openai.com/?app=chat&demo=5
Whereas java is the exact opposite. Every single command in java is precisely defined, and does exactly what you tell it to do. Compilers already have 100% effectiveness on doing this.
I am lead to assume that an AI would then compile "what I meant" and not "what I wrote". I'm not sure that's helpful because that sounds like a great way to get random, sometimes, bugs.
If you are getting errors from the compiler it is because your code is imprecise - and the fix there is to make it more precise.
I may have misinterpreted your question, or lack the imagination to see where you are going, so please feel free to expand on your point.
Notable works:
AutoTVM - https://arxiv.org/abs/1805.08166
CHAMELEON - https://deepai.org/publication/chameleon-adaptive-code-optim...
GPU-Warp Scheduling - https://deepai.org/publication/rlws-a-reinforcement-learning...