Leaving Switzerland for good - Please advice with the pillars

1st - Do not just forget about AHV/AVS: https://www.ahv-iv.ch/p/880.e

2nd - Particularly this thread should sort you out.

Depending on your social status in your new EU country, you may be eligible for a full payout (much valuable info in that thread, too!) upon leaving. Or non-mandatory part only, with the mandatory part having to stay on a Swiss vested benefits product until a few years before retirement age.

Non-mandatory meaning benefits that exceed the legally required minimum old-age savings credits. Do not confuse them with voluntary contributions or “freiwillige Einkäufe”. The latter will, as the name implies, never be legally required either. But many people will have non-mandatory benefits because their pension fund and its rules provided for them (thereby exceeding legally required minimums), without ever having chosen to contribute voluntarily.