1. A compiling method, the method comprising: simulating a first program code which includes at least one first operation command to generate a first operation result; compiling the first program code to generate a second program code which includes at least one second operation command; simulating the second program code to generate a second operation result; and comparing the first operation result with the second operation result to verify whether the second program code is valid.