Due to a problem in the Quartus® Prime Software version 17.1 and earlier, the error 18228 - module "tightly_coupled_data_master_0_altecc_encoder_module_module" cannot be declared more than once - is issued when more than one Nios II processor instance is using tightly coupled memories and ECC at the same time.
Disabling ECC for tighlty coupled memories in Nios II IP configuration mitigate this synthesis error.
This problem is scheduled to be resolved in a future release of the Quartus® Prime Software.