At least in European context, many migrants who cross the border illegally lack sufficient education to do well in modern labour market, and end up having a very low employment rate & high dependency on welfare. Even those who do find employment are likely to have low salary that doesn't bring much tax income.
Thus uncontrolled migration can never be a solution to our population issues. Instead effort should be put into attracting more skilled workforce that is in demand, and they should come in legally.