If it involves a couple of hacky tricks, I don't care if your code solves the problem 6% faster.
Hardware scales and will improve over time. The human capacity of understanding and maintaining code does not.
There are always exceptions to the rule, but generally speaking:
clean code > performance.