I see this with matlab-shell, when trying to tab-complete, in Emacs 23
and emacs 24 on the Mac, both on Lion and on Snow Leopard. I fired this
up in the debugger and it looks like it gets stuck on a system call but
I'm afraid I couldn't figure out any more than that.
At first start, Matlab returns completions just fine, but after about an hour it starts hanging when tab is pressed.