Not recommended. According to this issue, using Tor's high latency could result in significant revenue losses. The exact amount depends on your network conditions and gambling with the quality of Tor relay nodes. Based on my tests, the loss will not be less than 20%. If you cannot accept this, I suggest using a cheap/free no-log VPN instead.
@Trinity there is no guarantee that a pool doesn't log ip and tor is very easy to set up just sudo apt install tor and change in xmrig config to socks5 9050. it ensures no ip leakage and effectively works like kill switch in a vpn. vpns can leak ip if not configured properly but with tor there is no such issue