Thanks for the reply!
Converting to 8 bits may speed it but it is strange that a Tiff in 32 bits takes few minutes to count the colors?
I would expect that loading the file to memory would take most of the time (which is required for any operations)...