Added constant branch optimization