TL;DR: Our sources are limited for the first few centuries, but the first extended text we have is very negative about Islam.
The followers of the Buddha's dharma (law, religion) may have first encountered Muslims only a few decades after Muhammad's death. But a Buddhist response to this new threat was late in coming. Perhaps this was because Islam was relatively tolerant to Buddhism, at least during its early centuries. We have the following testimony from an eighth-century Korean Buddhist pilgrim, talking about a kingdom in Central Asia recently conquered under the banner of Islam (emphasis mine):^1
At present, the place is guarded and oppressed by Arab forces. [...] The king, the chiefs, and the common people respect the Three Jewels [of Buddhism]. There are many monasteries and monks. Hinayana Buddhism is practiced. They eat meat, onions, and leeks. They do not profess any other religions.
According to this pilgrim, Buddhism was openly practiced even under Muslim rule. Muslim sources agree. Generally speaking, Arab generals who expanded into Buddhist areas promised to treat locals as dhimmi (followers of non-Muslim monotheistic religions assured protection in an Islamic state). For instance, here's what one Arab commander did when he conquered a Buddhist city in 711:
He conquered the city by treaty with the condition that he would not kill them nor enter their [Buddhist] temple [budd]. And he said, "The Budd will be considered similar to the churches of Zoroastrianism."
Yet as the years passed by, conflict between the two faiths grew severer. In India itself Muslim raiders grew ever more intrepid, culminating in Mahmud of Ghazni's devastating sacks of countless cities and temples. In Central Asia the last of the great Buddhist kingdoms fell in 1006. This victory is immortalized by one very, err, interesting poem penned by the triumphant Muslim conquerors:
We came down on them like a flood,
We went out among their cities,
We tore down the idol-temples,
We shat on the Buddha’s head!
The Buddhist response was pessimistic. We have a number of Khotanese Buddhist prophecies concerning the fate of their religion in their homeland, most of which have been preserved in Tibet. All foretell the eventual end of the rightful faith in Khotan, as kings of "heretic religion" (mu-stegs-kyi chos) - almost certainly a reference to Islam - conquer the country.
This conflict set the background for the Kalacakra Tantra, Buddhism's first great response to the new religion.
The Kalacakra Tantra - suitably meaning the Wheel of Time - was one of the (perhaps the) last great work of Indian Buddhism. Yet little is known about it. It may be from the ninth century, or the tenth, or the eleventh, and it may be from any part of northern India. Nevertheless, we do know that it presented powerful arguments in a world in which Islam seemed to be dominant.
The Kalacakra Tantra always refers to Muslims as "barbarians" (mlecche) or even "demons" and Islam as the "barbarian religion." Just as the Greeks or Chinese believed "barbarians" to be everything they were not, the writer of this tantra believes Islam to be everything Buddhism is not. This is how the Tantra should, perhaps, be viewed with regards to its anti-Islamic sentiments; as an extended comparison between Islam and Buddhism, with Buddhism being the path to enlightenment and Islam symbolizing the demons that plague the soul on this path. The general view of Islam espoused by this text is fairly clearly shown by the following terms used to describe the faith:
Islamic dietary practices are especially condemned as being disgusting and blasphemous (since Muslims eat beef) compared to the Buddhists, who eat proper food:
With regard to the food and drink of the Buddhists and demons [Muslims]: Buddhists eat superior cooked rice, and the barbarian diet includes beef. Buddhists drink delicious, flavorful mixtures, and the barbarians drink the fluid of the eggs of fowl and so forth.
Not only that, Islamic dietary practices are morally repulsive. They kill and eat animals in honor of the demon "Bismillah" (this is a misunderstanding of Islam^3 ) while refusing to eat animals that die on their own (i.e. that die due to their own bad karma during their previous incarnation). This is morally backwards and just like Hinduism, the Dharma's other ancient adversary. So the two great opponents of Buddhism can be criticized in a single stroke. The writer of the tantra actually predicts that because Muslims and Hindus are both immoral meat-eaters, Hindus will eventually be doomed to convert to Islam:
Using the mantra of the barbarian deity Bismillah, they [Muslims] will slit the throats of animals with cleavers. Then they will prescribe eating the flesh of those beasts killed with the mantra of their own deity, and will prohibit eating the flesh of those that die due to their own karma. That very dharma [Islam] is authoritative for you [Hindu priests] because of the statement in the smrti [a Hindu legal text]: "Beasts are created for sacrifice." With regard to killing there is no difference between the barbarian dharma and the Vedic dharma [i.e. between Islam and Hinduism].
In many other fields Islam appears to be the total antithesis of Buddhism. Buddhist monks eat at morning and fast the rest of the day, while Muslims on fast eat at night and fast during the day. Buddhist monks wear red while laymen wear white; among the barbarians, ascetics dress in white. Buddhism promotes proper sexual behavior; Islam allows cousin marriage. Truly, Islam is the atyantaadharma - the absolute anti-religion.
But this is all about Muslim culture. What about the religion itself? First, its history is actually presented in a verse in the Kalacakra Tantra (set in the future tense since it's a prophecy by the Buddha):
Adam, Noah, and Abraham [are the first three barbarian teachers]; there are also five others whose nature is tamas [vicious, dark] in the family of demonic snakes: Moses, Jesus, the White-Clad One, Muhammad, and the Mahdl, who will be the eighth - he will belong to the darkness.
This list of prophets seems to derive from a Shi'ite source, but what matters more from our perspective is how the Abrahamic prophets' names are transliterated.
All this just goes to show the sheer negativity Buddhists had for their Muslim invaders.
The author of the Kalacakra understood that Muhammad was especially important, with the most space being devoted to him out of the eight barbarian teachers as well as a few characteristic epithets:
Muhammad, the incarnation of Al-Rahman [the Islamic God], the teacher and master of the barbarian religion [...] Muhammad, the lord of goblins.
So what exactly is the barbarian religion preached by these teachers? The Muslims are claimed to worship Rahman (Arabic for 'Merciful,' the most common title of the Islamic God), who created everything. Rahman is a capricious deity who sends people who please Him to Heaven and those who anger Him to Hell, with no chance at reincarnation. But He is pleased by very peculiar things indeed:
[Muslims] cut the skin from the tips of their penises as a cause for happiness in heaven.
Indeed, the writer concludes that Rahman is a "death god" and "the lord of darkness," favorably compared to a demon who attacked the Sun and Moon.
What about more complex Islamic theology? The Kalacakra remarks that Muslims have three peculiar beliefs. First, they believe in a Creator. This is easily refuted with the standard Buddhist arguments against Hindu creationism. Second, they hold that reincarnation does not exist. This is not explicitly refuted. Third, according to the Buddhist writer, Muslims believe that only the material body exists.^4 This is given some more detailed refutation involving the Buddhist doctrine of impermanence. Nevertheless, the impression is that the writer believes Islam to be a very lowly religion, worthy only of being categorized with the least sophisticated of Indian philosophies.
Well, there is some good to find in Islam, as it so happens.
They belong to a single caste, and do not take [each] other's property; they speak the truth and practice hygiene. Their youths avoid others' wives, and upholding the precepts of asceticism, they resort to their own wives.
Buddhists appear to have been consistently favorable towards Islam's lack of caste. But that's it - early Indian Buddhist opinion of Islam was never very high.
^1 The Hye Ch'o Diary: Memoir of the Pilgrimage to the Five Regions of India, p.52.
^2 This is especially interesting because the Qur'an explicitly bans the consumption of blood, suggesting that the writer was projecting general Buddhist stereotypes of barbarians into his discussion of Muslims.
^3 According to halal animals must be slaughtered with the prayer bismillah, "in the name of God." This does not mean
^4 The fact that Muslims don't believe in reincarnation apparently confused the writer enough to make him believe that Muslims don't actually believe in souls.