Hi FARHEEN. You are definitely experiencing overheating. This can be caused by a non-functioning system fan, or if the air ducts are blocked. Overheating can reduce the life of your computer, so you will want to resolve this as soon as you can. Here are a few troubleshooting documents you can use to help you.
Troubleshooting an Overheating and Auto Shutdown Issue
http://h10025.www1.hp.com/ewfrf/wc/document?cc=us&dlc=en&docname=c03904182&lc=en&product=5344258&tmp_track_link=ot_search
Reducing Heat Inside the PC to Prevent Overheating:
http://h10025.www1.hp.com/ewfrf/wc/document?cc=us&dlc=en&docname=c01657439&lc=en&product=5344258&tmp_track_link=ot_search
If they do not resolve the issue, you will want to contact Phone support.
HP technical support: 800-474-6836. If you live outside the US/Canada Region please click the link below to get the support number for your region. http://www.hp.com/cgi-bin/hpsupport/index.pl