If you have an inkling that you will be retiring/be laid off in the next 5 years you should be stashing cash and taking steps to ensure that your portfolio has enough cash in it to bridge you to social security and handle any emergencies. Your priority is to be liquid and preserve your next egg.
If you are 401k/IRA rich and cash poor, you will have a cash-flow problem. If you are unable/unwilling to find new employment you will withdraw money from 401k/traditional IRA which will be taxed as ordinary income. That extra ordinary income will often cause your Obama care subsidies to disappear - suddenly healthcare goes from $90 a month to $800 a month. To compound the problem if the market is down when you need the cash flow (and you don’t have a cash position) you will erode your nest egg much quicker than you expected.
Many of my prior coworkers have found themselves in a financial bind post layoff/buyout despite having what they perceived as large 401k/IRA balances/lump sum distribution. Take steps now to ensure you are not in a bInd later. It is easy to get caught up in the accumulating the 401k/IRA but not thinking about the de-accumulation phase.
Also remember the 5 year rule for converted Roth IRA money. Some coworkers were surprised about that when they used Roth IRA for cash flow got hit with a 10% penalty and unexpected tax.
You worked hard for your $, preserve it.