This happened to me. During my aforementioned hemorrhoid surgery. From what I've learned since, anesthesia is actually four different meds. One to put you to sleep, one so you don't remember, one so you don't feel the pain, and one to paralyze you so you don't move while they are operating.
So, I wake up in the middle of surgery and I remember it - so two of the three aren't working. Fortunately, the pain one was. I've read since that people have woke up feeling the pain..............And, the paralyze one was working. So, I couldn't let the docs know I was awake.........................I put all my efforts into moving and somehow did because I heard one say "He's awake" and then I was out again.
It was like those nightmares when you are trying to run but you can't. Horrible.