(Marked as offensive for obvious reasons. Using a clearly extreme example to make a point, because when people argue about free speech, it's usually about extreme examples.)
Here's an article from the grandchild of Holocaust survivors. It's in the Globe and Mail, the most widely read newspaper in Canada on weekdays and Saturdays. A company like that has a lot to lose, and so I'm inclined to trust them not to invent a genocide.
Here's a Chinese government source claiming that the oppression of Uyghur muslims is a hoax. If I were to look for dozens more sources in China, they would likely all agree, more or less. Now, these sources have to say that, because China doesn't have free speech, but the same could be said about the previous Canadian source I cited. Holocaust denial is illegal in Canada, so I should expect major sources to all report that it happened when discussing the topic whether or not it actually did.
In fact, I would hold that many sources reporting about the Holocaust in countries where Holocaust denial is illegal, have similar reliability issues to a major Chinese news source claiming that China has never committed human rights abuses, or that COVID-19 originated in the US. The government isn't strictly scripting the narrative for news sources, but banning denial is definitely putting strong pressure to write the narrative one way. (And once a government that bans speech, I'm often less inclined to believe that they aren't pulling some strings behind the scenes.)
I still believe the Holocaust happened, but mostly because I have sources from countries where it is legal to deny the Holocaust, and because the bans on Holocaust denial are poorly enforced. (Even a Chinese citizen with access to the internet and a good VPN could pretty easily outsmart government propaganda.) However, the consequence of criminalizing Holocaust denial has been that, logically speaking, many sources reporting on the Holocaust are no longer trustworthy. If the Holocaust was a hoax, the cost of lying would be low, because the government is telling them what position to take. There's other forensic evidence we can look at, and types of research individuals could do themselves, but most people won't go to that much effort, and we are generally pretty reliant on secondary and tertiary sources faithfully reporting the truth.
When we think about "knowing the truth," there's a certain type of information that comes to mind. Did the Holocaust happen? Was the Civil War fought over slavery? We often think that if people know the answers to these questions, we have effectively taught them a sufficient amount of the truth.
But there is another type of information that is arguably more important. What is the evidence that the Civil War was fought over slavery? What is the strongest argument that it wasn't? What is the strongest argument to believe the Holocaust didn't happen? This second type of information is necessary to see and analyze before we can arrive at the first type.
A logical person will be less likely to trust sources reporting a fact if the government mandates that fact. Generally, we want people to be logical, and we also want people to know the truth. If we censor falsehoods, then we can no longer achieve both of these goals. Banning Holocaust denial is killing the goose that lays the golden egg.