1. A non-transitory computer-readable recording medium storing a computer program that causes a computer to perform a procedure comprising: detecting a plurality of branch instructions, each of which specifies execution of branch processing on the basis of a result of a comparison operation between integers and indicates the same jump destination, in a first code; converting a first instruction group including the plurality of branch instructions in the first code into a second instruction group having fewer branch instructions than the first instruction group by using logical and arithmetic instructions, the converted second instruction group having a greater number of instructions than the first instruction group; and generating a second code using the converted second instruction group when the number of cycles of processing based on the converted second instruction group is smaller than that based on the first instruction group.