The number in the question is a little off. Tesla's release notes for FSD Beta V12, which reached customers in early 2024, said a single end-to-end neural network, trained on millions of video clips, replaced over 300,000 lines of explicit C++ code. That's hundreds of thousands of lines, not millions, and the 'millions' most likely comes from the training data, not the code.
What replaced the code was a neural network that takes camera input and outputs steering, acceleration and braking, instead of human-written rules such as 'if the light is red, stop.' Reports from the time, including Electrek's coverage, describe this as a shift in the city-streets driving stack, not a rewrite of all of Tesla's software. Tesla's code still runs much of the car, and the exact share of the stack that's neural now isn't something the release notes spell out.
Because the behavior comes from trained weights rather than readable rules, you can't trace a given driving decision back to one line of code. That is the main trade-off people argue about.