Depends on the PSU model (what exact power at the +12V rail it can provide, as well as it's build quality/reliability). Theoretically, a good-quality 400W PSU is enough for an 8320e (~158W http://www.guru3d.com/articles-pages/amd-fx-8320e-processor-review,7.html) and a 1050 Ti (~75W http://www.tomshardware.com/reviews/nvidia-geforce-gtx-1050-ti,4787-6.html).
You may be looking at a ~160W (CPU) + ~75W (GPU) + less than ~100W (HDD/SSD/RAM/MB/Fans/etc.) = less than ~335W power consumption at full load. So, if your 400W can only provide, say, ~300W at the +12V rail, your rig **may** be pushing your PSU to its limit, which is not recommended.