MCAPI general error 46

Hi

We are using MCAPI for multi-core communication in ADSP-SC(587/589).
it works normally good in debug mode but when switched the configuration from debug to release mode,
MCAPI give the status code 46 (General error).
Kindly, help to find the issue

Thanks
Parikshit