How to find in a node template file that node is loaded directly or from 'node_load' function? I want to check, in a node template file (node-node-type.tpl.php), that code is executing because of a direct request from a user visiting a node page or from calling node_load function in somewhere else?

EDIT:

the problem was 'Number of posts on main page' option in 'Post settings'. its value was 30 (I don't remember why I set it to its maximum value but I'm sure there was a reason that wasn't related to it's true functionality I think it triggers something else).

now that we know problem is from 'Number of posts on main page' option how I
can I fix it?
why this option invokes node template file despite the fact that I use a custom page.tpl.php which doesn't call node_view at all?
Edit: I realise after writing the answer that I sound rather negative. Sorry about that, but I can't phrase this in a positive fashion.

Answer: First, and foremost, you are mixing logic, with output. The template should not have logic in it, and should absolutely not care about why it was called.

When a user visits node/1, core will call node_load(1). This is in no way different from calling node_load(1) anywhere else.

A node template does also not execute as a direct result of loading a node. Templates are used when the theme layer renders a node, which is the completely other end of the response.

You can, in theory, call debug_backtrace() to get the call stack, and from there figure out more information about from where node_load was called, but there is almost certainly exactly 0 valid use-cases for this. I guarantee that you do not want to go down that path, and even considering it means that something is seriously wrong.

I have built Drupal-sites professionaly for years now, and have done some really, really ugly hacks during that time. Neither of them would come anywhere near analysing the stacktrace, in the theme layer.