Retirement tax questions

What about the mega backdoor strategy? That involves contributing after-tax to a traditional 401k and then rolling it into a Roth IRA without needing to pay taxes to roll it over. Since I know that's possible, the traditional 401k would need to track after-tax contributions in order for them to know what to withhold when you do the rollover.