Patent ID: 7406592

Claim:
A method for efficiently evaluating a Boolean expression comprising two or more operands and one or more operators, the method comprising: (a) parsing a first operator from the Boolean expression, wherein the Boolean expression is associated with a program module; (b) in response to parsing the first operator, storing on a stack a state value indicating that an operand is expected for the first operator; (c) repeating operations (a)-(b) for each of the operators in the Boolean expression; (d) evaluating a first operand from the Boolean expression to determine a value of the first operand; (e) in response to determining the value of the first operand, retrieving a state value from the stack; (f) determining whether to evaluate a second operand from the Boolean expression based on the value of the first operand and the state value retrieved from the stack; (g) in response to determining that the second operand should not be evaluated, skipping the evaluation of the second operand; (h) repeating operations (d)-(g) for each of the operands in the Boolean expression to evaluate the Boolean expression as true or false; (i) loading the program module via an extensible firmware interface if the Boolean expression is evaluated as true, the extensible firmware interface providing an interface between an operating system and system firmware; and (j) terminating operation (h) and returning an error if an error is encountered during the evaluation of the first operand or the second operand.