Fast path evaluation of Boolean predicates
First Claim
1. A system, comprising:
- a memory storing a plurality of instructions; and
one or more processors configured to access the memory, wherein the one or more processors are further configured to execute the plurality of instructions to at least;
receive event data from an event stream;
identify a continuous query language query for querying the event data of the event stream;
generate a first logical plan comprising one or more logical operators of the continuous language query;
determine, based at least in part on the one or more logical operators of the continuous query language query in the first logical plan, a first instruction for enabling evaluation of a subset of the one or more logical operators of the continuous query language query;
generate, based at least in part on the first instruction in the first logical plan, a second logical plan for implementing the continuous query language query, the second logical plan comprising at least one conditional instruction for skipping evaluation of at least one or more expressions associated with the one or more logical operators after a first expression comprising the one or more expressions has been evaluated;
compile at least the second logical plan into machine-readable instructions for implementing the subset of the logical operators of the continuous query language query in the first logical plan; and
execute the machine-readable instructions, the machine-readable instructions comprising the conditional instruction for skipping evaluation, at a runtime, of the one or more expressions associated with the subset of the logical operators of the continuous query language query, the conditional instruction identifying, at the runtime, a function comprising a list of input arguments, and the list of input arguments comprising at least one of an input operand indicating a result of execution of a previous instruction in the second logical plan, a storage parameter indicating a storage location to jump to if an expression represented by the input operand satisfies a condition, or a result parameter indicating a result location of execution of the conditional instruction.
1 Assignment
0 Petitions
Accused Products
Abstract
Techniques for managing fast path evaluation of Boolean predicates are provided. In some examples, the fast path evaluation may be based at least in part on received queries and/or query statements associated with a database and/or streaming data. In some examples, a first instruction for enabling execution of a subset of logical operators of the query may be determined. The determination may be based at least in part on the logical operators of the query. Additionally, based at least in part on the first instruction, logical instructions for implementing the query may be generated. Further, the logical instructions may be compiled into machine-readable instructions for implementing only the subset of the logical operators of the query.
518 Citations
21 Claims
-
1. A system, comprising:
-
a memory storing a plurality of instructions; and one or more processors configured to access the memory, wherein the one or more processors are further configured to execute the plurality of instructions to at least; receive event data from an event stream; identify a continuous query language query for querying the event data of the event stream; generate a first logical plan comprising one or more logical operators of the continuous language query; determine, based at least in part on the one or more logical operators of the continuous query language query in the first logical plan, a first instruction for enabling evaluation of a subset of the one or more logical operators of the continuous query language query; generate, based at least in part on the first instruction in the first logical plan, a second logical plan for implementing the continuous query language query, the second logical plan comprising at least one conditional instruction for skipping evaluation of at least one or more expressions associated with the one or more logical operators after a first expression comprising the one or more expressions has been evaluated; compile at least the second logical plan into machine-readable instructions for implementing the subset of the logical operators of the continuous query language query in the first logical plan; and execute the machine-readable instructions, the machine-readable instructions comprising the conditional instruction for skipping evaluation, at a runtime, of the one or more expressions associated with the subset of the logical operators of the continuous query language query, the conditional instruction identifying, at the runtime, a function comprising a list of input arguments, and the list of input arguments comprising at least one of an input operand indicating a result of execution of a previous instruction in the second logical plan, a storage parameter indicating a storage location to jump to if an expression represented by the input operand satisfies a condition, or a result parameter indicating a result location of execution of the conditional instruction. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10)
-
-
11. A non-transitory computer-readable memory storing a plurality of instructions executable by one or more processors, the plurality of instructions comprising:
-
instructions that cause the one or more processors to receive event data from an event stream; instructions that cause the one or more processors to identify a continuous query language query statement for querying the event data of the event stream; instructions that cause the one or more processors to generate a first logical plan comprising one or more logical operators of the continuous language query statement; instructions that cause the one or more processors to determine, based at least in part on the one or more logical operators of the continuous query language query statement in the first logical plan, a first instruction for enabling evaluation of less than all of the one or more logical operators of the continuous query language query statement; instructions that cause the one or more processors to generate, based at least in part on the first instruction in the first logical plan, a second logical plan for implementing the continuous query language query statement, the second logical plan comprising at least one conditional instruction for skipping evaluation of at least one or more expressions associated with the one or more logical operators after a first expression comprising the one or more expressions has been evaluated; instructions that cause the one or more processors to compile the second logical plan into machine-readable code for implementing the one or more logical operators of the continuous query language query statement in the first logical plan; and instructions that cause the one or more processors to execute the machine-readable instructions, the machine-readable instructions comprising the conditional instruction for skipping evaluation, at a runtime, of the one or more expressions associated with the subset of the logical operators of the continuous query language query, the conditional instruction identifying, at the runtime, a function comprising a list of input arguments, and the list of input arguments comprising at least one of an input operand indicating a result of execution of a previous instruction in the second logical plan, a storage parameter indicating a storage location to jump to if an expression represented by the input operand satisfies a condition, or a result parameter indicating a result location of execution of the conditional instruction. - View Dependent Claims (12, 13, 14)
-
-
15. A computer-implemented method, comprising:
-
receiving event data from an event stream; receiving, by a computing system, a continuous query language query statement for processing the event data of the event stream; generating a first logical plan comprising one or more logical operators of the continuous language query; generating, based at least in part on the one or more logical operators of the continuous query language query statement in the first logical plan, a query graph for enabling evaluation of less than all of the one or more logical operators of the continuous query language query statement; generating, based at least in part on the query graph, a second logical plan for implementing the continuous query language query statement to process the event data of the event stream, the second logical plan comprising at least one conditional instruction for skipping evaluation of at least one or more expressions associated with the one or more logical operators after a first expression comprising the one or more expressions has been evaluated; compiling, by the computing system, the second logical plan into machine-readable instructions for implementing the one or more logical operators of the continuous query language query statement in the first logical plan; and executing the machine-readable instructions, the machine-readable instructions comprising the conditional instruction for skipping evaluation, at a runtime, of the one or more expressions associated with the subset of the logical operators of the continuous query language query, the conditional instruction identifying, at the runtime, a function comprising a list of input arguments, and the list of input arguments comprising at least one of an input operand indicating a result of execution of a previous instruction in the second logical plan, a storage parameter indicating a storage location to jump to if an expression represented by the input operand satisfies a condition, or a result parameter indicating a result location of execution of the conditional instruction. - View Dependent Claims (19, 20, 21)
-
- 16. The computer-implemented method of 15, further comprising executing at least a portion of the machine-readable instructions.
-
17. The computer-implemented method of 16, wherein executing at least a portion of the machine-readable instructions includes at least jumping one or more of the machine-readable instructions.
Specification