gradient descent is used to keep the model stable.
The primary goal of a LLM is word prediction. When the word predicted is not the target word gradient descent adjusts the weights.
Compilation is a deterministic process. AI is a probabilistic process. They are not the same.