WASHINGTON — Iranian jets have carried out airstrikes against Islamic State militants in Iraq in recent days, Pentagon officials and independent analysts say, underscoring the strange alliances generated by the war against the extremist group that has beheaded Americans and killed and terrorized Iraqi civilians.