Thanks for answering.The reason is that I use a laptop and when playing games if turbo boost is enabled the temperature gets too much that it may be dangerous for the laptop.So I thought that for fixing this issue it's a good idea to disable turbo boost while gaming and enabling it again after I'm done playing and I want to do sth else.So I wondered whether it's a safe solution or not.
Intel Turbo Boost, as a feature, will not operate if the temperature is too high. It will only activate if there is sufficient thermal headroom available. Bottom line, it shouldn't be responsible for your issues. If you are seeing a thermal problem in this case, my first question would be: What are you considering "dangerous"? I would be looking at the laptop's cooling solution. If nothing else, it may need a proper cleaning.