added instruction counter