For the moment AI have "learn" from good and bad code.
It is not a secure or optimized code generated today.
But
AI is improving day after day, and after this code generation step, it will, one day optimize it, and some times later do a code that you will not be able to understand directly in machine code.
So yes, it is not for today.
But still aware it will not stay this way.
As the "computer" player of a chess game.