you are the only person who knows the answer to that
You can always “spoil” compulsions after the fact! For example, if you engage in excessive hand washing, you can touch something “contaminated” afterwards. If you do a mental compulsion, you can spoil it by agreeing with the original intrusive thought. Instead of confessing, spoil your compulsion and move on! You can do it!