1. A method of deadlock detection in a parallel program comprising: recording lock events during operation of the parallel program and a first order relation among the lock events; converting information relevant to the operation of the parallel program into gate lock events and recording the gate lock events, wherein the information relevant to the operation of the parallel program includes at least one of thread relevant information and program logic relevant information; establishing a second order relation among the gate lock events and lock events associated with the gate lock events and adding the second order relation to the first order relation; constructing a lock graph corresponding to the operation procedure of the parallel program based on the added second order relation; and performing deadlock detection on the constructed lock graph, wherein the information relevant to the operation of the parallel program comprises thread creation information including information of a parent thread and information of a child thread, wherein establishing the second order relation among the gate lock events and lock events associated with the gate lock events further comprises: acquiring by the parent thread a first set of lock events before creating the child thread; acquiring by the child thread a second set of lock events; acquiring a third set of lock events that is an intersection of the first set of lock events and the second set of lock events; and establishing an order relation among the thread creation information and the lock events in the third set of lock events.