Symptoms
Assume that you enable the AlwaysOn Availability Groups feature in Microsoft SQL Server 2012. When you enable the Log Shipping feature for some databases that are in an AlwaysOn availability group, the server freezes, and 100 percent of CPU resources are used. Additionally, the sys.fn_hadr_backup_is_preferred_replica function uses most of the CPU resources.
Resolution
The issue was first fixed in the following cumulative update of SQL Server.
Cumulative Update 7 for SQL Server 2012 SP1 /en-us/help/2894115
Each new cumulative update for SQL Server contains all the hotfixes and all the security fixes that were included with the previous cumulative update. Check out the latest cumulative updates for SQL Server:
Status
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.