11. The system of claim 10 , wherein the cost of execution is the total of a first provisional cost corresponding to the conditional expression being positive and a second provisional cost corresponding to the conditional expression being negative, and wherein the first provisional cost is based on a number of conditional expressions being true in response to the conditional expression being positive, and the second provisional cost is based on a number of conditional expressions being true in response to the conditional expression being negative.
10. A system for optimizing conditional statements in a program, the system comprising a hardware processor coupled to a memory wherein the hardware processor is configured to implement a method comprising: identifying a conditional expression having an inclusion relation corresponding to a plurality of conditional statements in the program, wherein a result of the conditional expression is representative of a result of the plurality of conditional statements respectively; determining, for the conditional expression, a position in the program as a move destination for the conditional expression, wherein executing the conditional expression at the move destination optimizes a number of conditional statements being executed in the program; determining a cost of execution of the program with the conditional expression being moved to the move destination, and wherein the cost of execution is based on a number of conditional statements corresponding to the inclusion relation, and a cost to access memory; and in response to the cost of execution of the program with the conditional expression being moved to the move destination being less than a cost without the movement, moving the conditional expression to the move destination, wherein moving the conditional expression comprises: in the case where a result of the conditional expression is not cached in a variable, generating an if statement for the conditional expression and caching a result of the conditional expression in a new variable, wherein the if statement is generated in increasing order of the cost of execution; and in the case where the result of the conditional expression is cached in the variable, replacing a conditional operator of the conditional expression with a logical operator, prior to caching the result in the new variable.