in GMM application (xtabond2) we need to classify our variables as endogenous, predetermined and exogenous variables. what is the criteria for doing so? how would we get to know which variable falls into endogenous category?
Your decision should be driven by economic theory. A variable x would be exogeneous, if there is no feedback from the endogenous variable y on x. This implies that x is uncorrelated with past and future error terms. If unpredictable errors today have some impact on x in later periods, x variable is predetermined in the sense that it is fixed in period t, but may be influenced in t+1, t+2 etc. If x is endogenous, it is correlated with contemporanous errors. In that case, you should specify instruments for x, before the estimation is done.
In general, the status of x -exogenous, predetermined, endogenous- has implications on the list of instruments you use in your GMM analysis.
To complement what Christian said, Woolridge's textbook (2002) suggests a test for strict exogeneity in the context of a first difference or fixed effects model (see p.285).
Economic theoty and your expert knowledge should be taken into account first. Selecting such variables by the use of technical tests may be missleading in many cases.