and Persia. Despite moving into and permanently settling in China, many of the Muslim immigrants and their descendants did not give up their Islamic faith nor "foreign" identity. Many of these new Chinese residents intermarried with the local Han population, forming and consolidating the foundations of the genetically diverse ethnic Hui population in China. Reconstruction during the Ming dynasty The city of Xi'an, after being destroyed during the collapse of the Tang dynasty, was reconstructed during the Ming dynasty by 1378 AD. The reconstruction of the original mosque into its contemporary form was patronized by the imperial government during Emperor Hongwu's reign. The mosque witnessed further additions during the Qing dynasty, which included the mosque's front gate, Paifang, and Sebil. Evidence of official patronage of the mosque is present in the form of plaques placed in the Mosque. For instance, a plaque stating the Declaration of the Reconstruction of the Mosque () was placed there in 1606 during the Ming dynasty. Another plaque called Declaration to Fix the Mosque () was placed there by the Qing government in 1768. It has been widely argued that although the Hui community largely adhered to their religious identity, they gravitated and later adopted the mainstream Han Chinese cultural traditions as encouraged by the Ming and later Qing governments. However, certain restrictions on the practice of Islam occurred after the Dungan Revolt (1862–1877), which started because of ethnic and religious tensions between the Muslims and the Han Chinese. The revolt led to riots and mass killing from both sides. After the Dungan Revolt the Qing government limited Muslim freedom of worship. The ritual slaughtering of animals was forbidden. The construction new mosques and the pilgrimage to Mecca were prohibited, though these restrictions were lifted after the overthrowing of the Qing dynasty. Today, the Great Mosque of Xi'an and its surrounding area have been developed as the center of the Hui population of Xi'an. In 1956, the government of the People's Republic of China declared the mosque to be a Historical and Cultural Site Protected at the Shaanxi Province Level. However, during the Cultural Revolution, as with practically all other religious facilities in mainland China, the mosque was temporarily shut down and converted into a steel factory. Following Mao Zedong's death in 1976, religious activities resumed, and the mosque was later promoted to a Major Historical and Cultural Site Protected at the National Level in