I installed (incredibly low price!) 128GB of OWC memory in my 2019 iMac 5K. Having 128GB has a godsend, helping make short work of stacked images and panoramas that with only 64GB had been problematic with my 2017 iMac 5K.
But... I need 256GB, darn it! Assembling a 1.4 gigapixel panorama today had Photoshop using 98GB of real memory and still using 16.5GB of compressed memory (slow).