Pakistan's fight against the Taliban is an illusion. The world may view it as a battle for Pakistan's soul, but the generals in Rawalpindi, with whom real power rests, are not so sure. If they were, 200,000 of their finest fighters wouldn't be chewing grass on the eastern border with India while the so-called battle for Pakistan's survival rages on in the north-west.

Blackmailing the world by threatening imminent collapse is vintage Pakistan. Recently, President Asif Ali Zardari told Der Spiegel that the safety of Pakistan's nuclear arsenal depended entirely upon how well the world supported democracy in his battered country. "If democracy in this country fails, if the world doesn't help democracy," he warned, "then any eventuality is possible." Having placed the burden of Pakistan's recovery from the mire of its own making on the world's shoulders, Zardari listed the "help" that his government expected: "billions of dollars".

But Pentagon documents released earlier this month give an alarming account of where the benignant billions of aid dollars poured into Pakistan's coffers over the last decade have ended up: on the most modern weaponry – combat aircraft, laser-guided kits, anti-ship missiles, air-to-air missiles – for use against India. Under the cloak of this conflict, Pakistan has equipped itself for battle with its traditional enemy, rapidly increasing its nuclear weapons at the same time.

The Taliban's recent targets have unsettled their erstwhile paymasters, but nothing seems to deter Islamabad from continuing with its policy of patronising Islamic extremists – so long as they are devoted to destroying India. Punjab is littered with these groups. In Lahore last month, Yahya Mujahid told me that his group, the banned Jamat-ud-Dawah, would continue to fight against Indian rule in Kashmir. The operations "have gone somewhat cold", he admitted. But he spoke confidently and strode assuredly – a man who knew things would turn in his favour.

Three weeks later, Hafiz Saeed, Jamat-ud-Dawah's leader, who had been detained after India produced several dossiers linking him to last November's Mumbai attacks, was freed. Among the reasons cited by the Lahore high court in ordering Saeed's release was this bolt from the blue: "The security laws and anti-terrorism laws of Pakistan are silent on al-Qaida being a terrorist organisation." The trial was a farce, a repetition of Pakistan's time-tested tactic of appearing to act against anti-India jihadis while not taking any action at all.

Mani Shankar Aiyar once described Pakistan as a country "divided against itself, but united against India". From that delusional feudal megalomaniac Zulfi Bhutto's pledge to wage a "thousand-year war" against India to General Pervez Musharraf's desperate attempt in 1999 to nuke it, hatred of India has been the constitutive sine qua non for Pakistan's survival. It is the one bugbear that makes Pakistanis out of Sindhis and Baluchis, Pathans and Punjabis.

Many Pakistanis I spoke to agreed that their country has gone to the dogs. But Kashmir still evokes the romantic idea of a Muslim nationhood. Pakistan continues to be defined by the struggle that created it – a struggle founded upon the premise that Muslims and Hindus cannot co-exist in one nation. With all of India's social failings, its success at forging a nationality out of its diversity stands as a towering repudiation of this idea, and merely by being itself, impeaches the logic of partition. Pakistan cannot justify its existence as long as India accommodates religious diversity. It is not enough that Pakistan is a Muslim country: for its creation to be truly vindicated, the country it was carved out of must be Hindu. As long as Kashmir, a Muslim-majority state, remains part of India, Pakistan will view partition as unfinished business and itself as its incomplete product.

But the Pakistan that was created in 1947 ceased to exist in 1971 with the creation of Bangladesh – in a manner that doesn't just cast deep moral questions on Pakistan's claim to speak for Kashmiri Muslims, but also offers an object lesson against indulging procrustean nationalisms, of which Pakistan remains a paragon. Created expressly to safeguard the Muslims of the subcontinent, Pakistan perpetrated the biggest genocide of Muslims since the arrival of Islam in south Asia. At least 3 million East Pakistanis in what is now Bangladesh were slaughtered by West Pakistani soldiers within the space of a few months in 1971. The Islamic bond which animates Pakistan's jihadist policy in Kashmir was absent during this massacre. It was secular India, its forces led entirely by non-Hindus – a Muslim air marshal (Idris Latif), a Sikh commander of ground forces (JS Aurora), a Parsi chief of army (Sam Manekshaw), and a Jewish strategist and principal negotiator (JFR Jacob) – which intervened to liberate Pakistanis from the madness of Pakistan.

What remained of Pakistan in 1971 became a plaything of the military-feudal-political elite who turned it into a back office for the outsourced wars of big powers. Three decades later, Pakistan represents state failure, religious extremism, terrorism, nuclear proliferation. Few dispensations have failed their people on the scale that Pakistan has: it exists solely to provide subsistence to the military establishment.

Within the next 20 years, Pakistan as we know it today will probably not exist. Built on the idea that differences between people must ultimately culminate in permanent division, Pakistan has become a victim of the very logic that created it: from Karachi in the south-east to Peshawar in the north-west, Jinnah's children are carrying his divisive message to its logical extreme. The tragedy is that this is not an aberration, but the acme, of the idea of Pakistan.

• This article was amended on 21 December 2011. It originally stated that at least 7 million East Pakistanis were killed by West Pakistani soldiers in 1971. This has now been corrected