debug function

Add a simple & not well did debug function
can trace back stacks