Minecraft uses a lot of the client RAM (sometimes it uses up all available memory) when minimized from windowed mode. When maximizing, it does so very slowly with white screen or very distorted main screen, but when it finishes maximizing, the RAM usage goes back to normal.
Duplicate of MC-101338