Credit-driven investment, heterogeneous labor markets and macroeconomic dynamics