Compare and Swap Functionality in GHS compiler

Hello Team,

Do we have a compare and swap function for our ghs compiler?

Can we use __atomic_compare_exchange for ghs compiler?

Thanks in advance!!