<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta>
      <journal-title-group>
        <journal-title>Joint Conference (March</journal-title>
      </journal-title-group>
    </journal-meta>
    <article-meta>
      <title-group>
        <article-title>In-memory Caching for Multi-query Optimization of Data-intensive Scalable Computing Workloads</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Pietro Michiardi</string-name>
          <email>pietro.michiardi@eurecom.fr</email>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Damiano Carra</string-name>
          <email>damiano.carra@univr.it</email>
          <xref ref-type="aff" rid="aff1">1</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Sara Migliorini</string-name>
          <email>sara.migliorini@univrit</email>
          <xref ref-type="aff" rid="aff1">1</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>EURECOM</institution>
          ,
          <addr-line>Biot</addr-line>
          ,
          <country country="FR">France</country>
        </aff>
        <aff id="aff1">
          <label>1</label>
          <institution>University of Verona</institution>
          ,
          <addr-line>Verona</addr-line>
          ,
          <country country="IT">Italy</country>
        </aff>
      </contrib-group>
      <pub-date>
        <year>2019</year>
      </pub-date>
      <volume>26</volume>
      <issue>2019</issue>
      <abstract>
        <p>In modern large-scale distributed systems, analytics jobs submitted by various users often share similar work. Instead of optimizing jobs independently, multi-query optimization techniques can be employed to save a considerable amount of cluster resources. In this work, we introduce a novel method combining inmemory cache primitives and multi-query optimization, to improve the eficiency of data-intensive, scalable computing frameworks. By careful selection and exploitation of common (sub) expressions, while satisfying memory constraints, our method transforms a batch of queries into a new, more eficient one which avoids unnecessary recomputations. To find feasible and eficient execution plans, our method uses a cost-based optimization formulation akin to the multiple-choice knapsack problem. Experiments on a prototype implementation of our system show significant benefits of worksharing for TPC-DS workloads.</p>
      </abstract>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>INTRODUCTION</title>
      <p>
        Modern technologies to analyze large amounts of data have
flourished in the past decade, with general-purpose cluster processing
frameworks such as MapReduce [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ], Dryad [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ] and Spark [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ].
More recently, a lot of efort has been put in raising the level
of abstraction, and allow users to interact with such systems
with a relational API. SQL-like querying capabilities are not only
interesting to users for their simplicity, but also bring additional
benefits from a wide range of automatic query optimizations,
aiming at eficiency and performance.
      </p>
      <p>
        Large-scale analytics systems are deployed in shared
environments, whereby multiple users submit queries concurrently.
In this context, concurrent queries often perform similar work,
such as scanning and processing the same set of input data. The
research in [
        <xref ref-type="bibr" rid="ref4">4</xref>
        ] on 25 production clusters, estimated that over
35,000 hours of redundant computation could be eliminated per
day by simply reusing intermediate query results (approximately
equivalent to shutting of 1500 machines daily). It is thus truly
desirable to study query optimization techniques that go beyond
optimizing the performance of a single query, but instead
consider multiple queries, for eficient resource utilization.
      </p>
      <p>
        Multi-query optimization (MQO) amounts to find similarities
among a set of queries and uses a variety of techniques to avoid
redundant work during query execution. For traditional database
systems, MQO trades some small optimization overheads for
increased query performance, using techniques such as sharing
sub-expressions [
        <xref ref-type="bibr" rid="ref5 ref6 ref7">5–7</xref>
        ], materialized views selection [
        <xref ref-type="bibr" rid="ref8 ref9">8, 9</xref>
        ], and
pipelining [
        <xref ref-type="bibr" rid="ref10">10</xref>
        ]. Work sharing optimizations operating at query
runtime, for staged databases, have also been extensively studied
[
        <xref ref-type="bibr" rid="ref11 ref12 ref13 ref14">11–14</xref>
        ]. The idea of reusing intermediate data across queries
running in distributed systems has received significant attention:
for MapReduce [
        <xref ref-type="bibr" rid="ref15 ref16">15, 16</xref>
        ], for SCOPE operating on top of Cosmos
[
        <xref ref-type="bibr" rid="ref17">17</xref>
        ] and for Massive Parallel Processing frameworks [
        <xref ref-type="bibr" rid="ref18">18</xref>
        ].
      </p>
      <p>
        In this paper, we study MQO in the context of distributed
computing engines such as Apache Spark [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ], with analytics
jobs written in SparkSQL [
        <xref ref-type="bibr" rid="ref19">19</xref>
        ], in which relational operators are
mapped to stages of computation and I/O. Following the
tradition of RDBMSes, queries are first represented as (optimized)
logical plans, which are transformed into (optimized) physical
plans, and finally run as execution plans. Additionally, modern
parallel processing systems, such as Spark, include an operator to
materialize in RAM the content of a (distributed) relation, which
we use extensively. Our approach to MQO is that of traditional
database systems, as it operates on a batch of queries. However,
unlike traditional approaches, it blends pipelining and global
query planning with shared operators, using in-memory caching
to support worksharing. Our problem formulation amounts to
a cache admission problem, which we cast as a cost-based,
constrained combinatorial optimization task, setting it apart from
previous works in the literature.
      </p>
      <p>We present the design of a MQO component that, given a set
of concurrent queries, proceeds as follows. First, it analyzes query
plans to find sharing opportunities, using logical plan
fingerprinting and an eficient lookup procedure. Then it builds multiple
sharing plans, using shared relational operators and scans, which
subsume common work across the given query set. Sharing plans
materialize their output relation in RAM. A cost-based
optimization selects best sharing plans with dynamic programming, using
cardinality estimation and a knapsack formulation of the
problem, that considers a memory budget given to the MQO problem.
The final step is a global query plan rewrite, including sharing
plans which pipeline their output to modified consumer queries.</p>
      <p>We validate our system with a prototype built for SparkSQL,
using the standard TPC-DS benchmark for the experiments.
Overall, our method achieves up to 80% reduction in query runtime,
when compared to a setup with no worksharing. Our main
contributions are as follows:
• We propose a general approach to MQO for distributed
computing frameworks. Our approach produces sharing plans, that
are materialized in RAM, aiming at eliminating redundant work.
• We cast the optimization problem of selecting the best sharing
plans as a Multiple-choice Knapsack problem, and solve it
eficiently through dynamic programming.
• Our ideas materialize into a system prototype based on
SparkSQL, which we evaluated using standard benchmarks, obtaining
tangible improvements in aggregate query execution times.
2</p>
    </sec>
    <sec id="sec-2">
      <title>RELATED WORK</title>
      <p>
        MQO in RDBMSes. Multi-query optimization has been studied
extensively [
        <xref ref-type="bibr" rid="ref10 ref20 ref21 ref6 ref7">6, 7, 10, 20, 21</xref>
        ]. More recently, similar
subexpressions sharing has been revisited by Zhou et al. in [
        <xref ref-type="bibr" rid="ref5">5</xref>
        ], who show
that reusable common subexpressions can improve query
performance. Their approach avoids some limitations of earlier work
[
        <xref ref-type="bibr" rid="ref20 ref7">7, 20</xref>
        ]. More recently, work sharing at the execution engine has
been studied [
        <xref ref-type="bibr" rid="ref11 ref12 ref13 ref14">11–14</xref>
        ]. The MQO problem is considered at query
runtime, and requires a staged database system. Techniques such
as pipelining [
        <xref ref-type="bibr" rid="ref12">12</xref>
        ] and multiple query plans [
        <xref ref-type="bibr" rid="ref22 ref23">22, 23</xref>
        ] have proven
extremely beneficial for OLAP workloads. Our work is rooted
on such previous literature, albeit the peculiarities of the
distributed execution engine (which we also take into account in
our cost model), and the availability of an eficient mechanism
for distributed caching steer our problem statement apart from
the typical optimization objectives and constraints from the
literature.
      </p>
      <p>
        Materialized views can be used in conjunction with MQO to
reduce query response times [
        <xref ref-type="bibr" rid="ref24 ref8 ref9">8, 9, 24</xref>
        ]. A broad range of works
addressed the problem of materialized view selection and
maintenance, including both deterministic [
        <xref ref-type="bibr" rid="ref25 ref26 ref7">7, 25, 26</xref>
        ] and randomized
[
        <xref ref-type="bibr" rid="ref27 ref28 ref29">27–29</xref>
        ] strategies. In this paper, we focus on analytics queries
in which data can be assumed to be static. Workloads consist
mostly of ad-hoc, long running, scan-heavy queries over data
periodically loaded in a distributed file system. Problems related
to view maintenance do not manifest in our setup. Moreover, our
approach considers storing intermediate relations in RAM.
      </p>
      <sec id="sec-2-1">
        <title>MQO in Cloud and Massively Parallel Processing (MPP).</title>
        <p>
          Building upon MQO techniques in RDBMSes, Silva et al. [
          <xref ref-type="bibr" rid="ref17">17</xref>
          ]
proposed an extension to the SCOPE query optimizer which
optimizes cloud scripts containing common expressions while
reconciling physical requirements. In MPP databases, the work in
[
          <xref ref-type="bibr" rid="ref18">18</xref>
          ] presents a comprehensive framework for the optimization
of Common Table Expressions (CTEs) implemented for Orca.
Compared to our method, we consider not only CTEs but also
similar subexpressions to augment sharing opportunities.
MQO in MapReduce. The idea of making MapReduce jobs share
some intermediate results was studied in [
          <xref ref-type="bibr" rid="ref15 ref16 ref17 ref30 ref31 ref32 ref33 ref34">15–17, 30–34</xref>
          ]. The
common denominator of such works is that they operate at a
lower level of abstraction than we do.
        </p>
        <p>
          More recently, [
          <xref ref-type="bibr" rid="ref35">35</xref>
          ] formulates the MQO problem as a
costbased, binary optimization task, which is addressed with an
external optimizer. Nevertheless, this work does not exploit caching as
a mechanism to re-use work. The work in [
          <xref ref-type="bibr" rid="ref36">36</xref>
          ] presents a method
to estimate the benefit associated to materializing intermediate
results of past queries, and this method is orthogonal to ours.
Additionally, views are materialized on disk, instead of memory.
The work in [
          <xref ref-type="bibr" rid="ref37">37</xref>
          ] addresses the problem of work sharing by
casting it as an exact query subgraph matches. As such, it tackles
the MQO problem from a diferent angle, and it does not exploit
caching. The work in [
          <xref ref-type="bibr" rid="ref38">38</xref>
          ] cast the MQO task as an integer
linear programming problem. However, the induced cost model is
simplistic, and does not exploit in-memory caching.
Caching to recycle work. Previous works [
          <xref ref-type="bibr" rid="ref39 ref40 ref41 ref42 ref43">39–43</xref>
          ] that address
the problem of reusing intermediate query results, cast it as a
general caching problem. Our work substantially difers from
those approaches in that they mainly focus on cache eviction,
where past queries are used to decide what to keep in memory, in
an on-line fashion. Instead, in this work we focus on the of-line
constrained optimization problem of cache admission: the goal
is to decide the best content to store in the cache, rather than
selecting which to evict if space is needed. The only work that
considers the reuse of intermediate results when analyzing the
overall execution plan of multiple queries is [
          <xref ref-type="bibr" rid="ref40">40</xref>
          ]. Nevertheless,
they focus on small problem instances which do not require the
general, cost-based approach we present in this work.
        </p>
      </sec>
    </sec>
    <sec id="sec-3">
      <title>PROBLEM STATEMENT</title>
      <p>We introduce a simple running example, that is rich enough to
illustrate the gist of the MQO problem. Consider the following
three concurrent queries:
QUERY 1:
SELECT name, dept_name, salary
FROM employees, departments, salaries
WHERE dep = dept_id</p>
      <p>AND id = emp_id
AND gender = 'F'
AND location = 'us'</p>
      <p>AND salary &gt; 20000
ORDER BY salary DESC
QUERY 2:
SELECT name, dept_name, title,</p>
      <p>to as title_expired_on
FROM departments, employees, titles
WHERE dep = dept_id</p>
      <p>AND id = emp_id
AND gender = 'F'
AND location = 'us'</p>
      <p>AND from &gt;= 2010
QUERY 3:
SELECT id, name, salary, from_date
FROM employees, salaries
WHERE id = emp_id</p>
      <p>AND age &gt; 30</p>
      <p>AND SALARY &gt; 30000</p>
      <p>Figure 1 illustrates the optimized operator trees (logical plans)
of the queries in the above example. The leaf nodes represent the
base relations. Each intermediate node is a relational operator
(Selection, Projection, Join, etc.). The arrows between nodes indicate
data flow. Our MQO strategy uses such optimized logical plans
to produce new plans – whose aim is to exploit sharing
opportunities by caching distributed relations – which are translated
into physical plans for execution.</p>
      <p>First, we see that the three queries can share the scan of the
employees, departments and salaries relations. Hence, a
simple approach to work sharing would be to inject a cache operator
in Query 1, which would steer the system to serve input relations
from RAM instead of reading them from disk, when executing
Query 2 and 3. A more refined approach could be to find common
work (not only common I/O), in the form of similar subexpressions
(SE) among the queries from the example, such as filtering and
projecting records, and materialize intermediate results in RAM,
so that to re-use such intermediate relations.</p>
      <p>Figure 1 illustrates four examples of similar SEs, which are
labelled as ψi , i = 1, 2, 3, 4 (we explain the meaning of this label
in the next section). For example, consider the subexpression
labelled as ψ2: all three queries share the same sub-tree structure, in
the form Projectp (Filterf (employees)), but use diferent filtering
predicates and projections. In principle, it is thus possible to save
reading, parsing, filtering and projecting costs on the employees
relation: by caching the intermediate output of a general form
of subexpression, which subsumes the three similar sub-trees
in each query. Such costs would be payed once, and the cached
intermediate relation could serve three consumer queries. To this
aim, we need to build a covering expression (CE) that combines
the variants of the predicates appearing in the operators, e.g.,
considering ψ2 the corresponding CE could be:</p>
      <p>Projectid, name, dep, age(Filtergender=F ∨ age&gt;30(employees))
Similarly, the SEs labelled as ψ3 and ψ4 share the projection
and filtering on department and salaries relations.</p>
      <p>We anticipate that, in the context of our work, it is possible to
rank some SEs according to the benefits they bring, in terms of
reducing redundant work.</p>
      <p>Sort
[salary, DESC]</p>
      <p>Project
[name, dept_name, salary]</p>
      <p>Join
[id = emp_id]</p>
      <p>Project
[name, dept_name, title, to]</p>
      <p>Join
[id = emp_id]</p>
      <p>Project
[id, name, salary,
from_date]</p>
      <p>Join
[id= emp_id]
ψ2</p>
      <p>Project
[id, name, age]</p>
      <p>For instance, the SE Projectp (Filterf (employees)) leads to
additional savings when compared to the SE Filterf (employees),
and caching the intermediate relation of the corresponding CE
results in a smaller memory footprint because of its selectivity.
More to the point, we now consider the SE labelled as ψ1 in
Figure 1: Query 1 and 2 share a common sub-tree in their respective
logical plans, that involves selections, projections and joins. In
this case, selecting this SE as a candidate to build a CE between
Query 1 and 2 contributes to decreased scanning, computation
and communication costs. However, since caching a relation in
RAM bears its own costs and must satisfy capacity constraints,
materializing in RAM the output of the CE might reveal not
beneficial after all: a join operator could potentially produce an
intermediate relation too big to fit in RAM.</p>
      <p>Overall, given an input query set, our problem amounts to
explore a potentially very large search space, to identify SEs, to
build the corresponding CEs – which we also call sharing plans,
and to decide which CEs to include in the optimized output
plan. Our MQO strategy aims at reducing the search space to
build CEs by appropriately pruning SEs according to their rank.
Furthermore, a cost-based selection of candidate CEs must ensure
memory budget constraints to be met.
4</p>
    </sec>
    <sec id="sec-4">
      <title>CACHE-BASED WORK SHARING</title>
      <p>We consider a set of concurrent queries submitted by multiple
users to be parsed, analyzed and individually optimized by a
query optimizer. Our MQO method operates on a set of
optimized logical plans corresponding to the set of input queries,
that we call the input set. We approach the MQO problem with
the following steps:
§4.1: Similar subexpressions identification. The goal is to
identify all common subexpressions in the input set. Two (or
more) operators sharing similar subexpressions constitute a SE,
which are candidates for building covering expressions (CEs).
§4.2: Building sharing plans. The goal is to construct one or
more groups of covering expressions CEs for a set of SEs.
§4.3: Sharing plan selection. The goal is to select the best
combination of CEs, using estimated costs and memory constraints.
We model this step as a Multiple-Choice Knapsack problem, and
use dynamic programming to solve it.
§4.4: Query rewriting. The last step to achieve MQO is to
rewrite the input query set such as to use selected sharing plans.
4.1</p>
    </sec>
    <sec id="sec-5">
      <title>Similar Subexpression Identification</title>
      <p>Finding similar subexpressions, given an input set of logical plans,
has received considerable attention in the literature. What sets
our approach apart from previous works lies behind the very
nature of the resource we use to achieve work sharing: memory
is limited, and the overall MQO process we present is seen as a
constrained optimization problem, which strives to use caching
with parsimony. Thus, we use a general rule of thumb that prefers
a large number of CEs (built from the corresponding SEs) with
small memory footprints instead of a small number of CEs with
large memory requirements. This is in line with low-level systems
considerations: data materialization in RAM is not cost-free, and
current parallel processing frameworks are sometimes fragile,
when it comes to memory management under pressure.</p>
      <p>
        Armed with the above considerations, we first consider the
input to our task: we search SEs given a set of “locally optimized”
query plans, which are represented in a tree form. Such input
plans have been optimized by applying common rules such as
early filtering, predicate push-down, plan simplification and
collapsing [
        <xref ref-type="bibr" rid="ref19">19</xref>
        ]. The natural hierarchy of optimized logical plans
implies that the higher in the tree an operator is, the less the data
lfowing from its edges. Hence, similar subexpressions that are
found higher in the plan are preferred because they potentially
exhibit smaller memory footprints.
      </p>
      <p>Additional considerations are in order. Some operators
produce output relations that are not easy to materialize in RAM: for
example, binary operators such as join, generally produce large
outputs that would deplete memory resources if cached. When
searching for SEs, we recognize “cache unfriendly” operators and
preempt them for being considered as valid candidates, either by
selecting SEs that appear lower in the logical plan hierarchy (e.g.,
which could imply caching the input relations of a join), or by
selecting SEs that subsume them (e.g., which could imply caching
a relation resulting from filtering a join output). Currently, we
treat the join, Cartesian product and Union as “cache unfriendly”
operators. This means that our method does not produce SEs
rooted at cache unfriendly operators; moreover, cache unfriendly
operators can be shared inside a common SE only when they are
syntactically equal.1 Next, we provide the necessary definitions
that are then used to describe the identification of SEs.</p>
      <p>Definition 4.1 (Sub-tree). Given a logical plan of a query Q,
represented as a tree τ Q where leaf nodes are base relations and
each intermediate node is a relational algebra operator, a
subtree τsQ of τ Q is a continuous portion of the logical plan of Q
containing an intermediate node of τ Q and all its descendant in
τ Q . In other words, a sub-tree includes all the base relations and
operators that are necessary to build its root.</p>
      <p>
        If the context is clear, we denote a sub-trees simply as τ ,
without indicating from which query it has been derived. Given any
two sub-trees, we need to determine if they have the same
structure in terms of base relations and operators. To this aim, we
define a similarity function based on a modified Merkle Tree
(also known as hash tree)[
        <xref ref-type="bibr" rid="ref44">44</xref>
        ], whereby each internal node
identiifer is the combination of identifiers of its children. In particular,
given an operator u, its identifier, denoted by ID( u), is given by:
( (u.label ) u ∈ {filter, project,input rel.}
ID(u) =
      </p>
      <p>(u.label, u.attributes) otherwise.</p>
      <p>Notice that this definition makes a distinction between loose and
strict identifier. A loose identifier, such that used for projections
and selections, allows the construction of a shared operator that
subsumes the individual attributes with more general ones, which
allows sharing computation among SEs. Instead, a strict identifier,
such that used for all other operators (including joins and unions),
imposes strict equality for two sub-graphs to be considered SEs.
In principle, this restricts the applicability of a shared operator.
However, given the above considerations about cache unfriendly
operators, our approach still shares both I/O and computation.</p>
      <p>Definition 4.2 (Fingerprint).
is computed as</p>
      <p>Given a sub-tree τ , its fingerprint
h(ID(τroot)) τroot = leaf

F (τ ) = h(ID(τroot)|F (τchild)) τroot = unary

h(ID(τroot)|F (τl.child)|F (τr.child)) τroot = binary

where h() is a robust cryptographic hash function, and the
operation | indicates concatenation.</p>
      <p>The fingerprint F (τ ) is computed recursively starting from
the root of the sub-tree (τroot), down to the leaves (that is,
input relations). If the root is a unary operator, we compute the
ifngerprint of its child sub-tree ( τchild), conversely in case of a
binary operator, we consider the left and right sub-trees (τl.child
and τr.child). For the sake of clarity, we omit an additional
sorting which ensures the isomorphic property for binary operators:
for example, TableA join TableB and TableB join TableA are two
isomorphic expressions, and have the same fingerprint.</p>
      <p>
        We are now ready to define what a similar subexpression is.
1Our method can be easily extended for sharing similar join operators, for example
by applying the “equivalence classes” approach used in [
        <xref ref-type="bibr" rid="ref5">5</xref>
        ]. Despite technical
simplicity, our current optimization problem formulation would end-up discarding such
potential SEs, due to their large memory footprints. Hence, we currently preempt
such SEs from being considered.
      </p>
      <sec id="sec-5-1">
        <title>Algorithm 1 Similar subexpressions identification</title>
        <p>Definition 4.3 (Similar subexpression). A similar subexpression
(SE) ω is a set of sub-trees that have the same fingerprint ψ , i.e.
ω = {τi | F (τi ) = ψ }.</p>
        <p>Algorithm 1 provides a pseudo-code of our procedure to find,
given a set of input queries, the SEs according to Definition 4.3
that will be the input of the next phase, the search for covering
expressions. The underlying idea is to avoid a brute-force search
of fingerprints, which would produce a large number of SEs.
Instead, by proceeding in a top-down manner when exploring
logical plans, we produce fewer SEs candidates, by interrupting
the lookup procedure as early and as “high” as possible.</p>
        <p>The procedure uses a fingerprint table FT (line 2) to track
SEs: this is a HashMap, where the key is a fingerprint ψ , and the
value is a set of subtrees. Each logical plan from the input set of
queries is examined in a depth-first manner. We first consider the
whole query tree (line 4) and check if its root is a cache-friendly
operator: in this case, we add the tree to the SEs identified by its
ifngerprint. The method AddValueSet(ψ , τ ) retrieves the value
(which is a set) from the HashMap FT given the key ψ (line 9),
and adds the subtree τ to such a set – if the key does not exists,
it adds it and create a value with a set containing the subtree τ .
If the root is not a cache-friendly operator, or the logical plan
contains a cache-unfriendly operator, then we need to explore
the subtrees (line 13), i.e. we consider the root’s child (if the the
operator at the root is unary) or children (otherwise).</p>
        <p>At the end, we extract the set of SEs from the HashMap FT:
we consider the SEs bigger than a threshold k in order to focus
on SEs that ofer potential work sharing opportunities.</p>
        <p>Going back to our running example, Algorithm 1 outputs a
set of SEs as follows {ω1, ω2, ω3, ω4} – in Figure 1 the sub-trees
corresponding to them are labelled ψ1, ψ2, ψ3 and ψ4, where ψi is
the fingerprint of SE ωi . For instance, ω1 contains two sub-trees
(one from Query 1, and one from Query 2), while ω2 contains
three sub-trees, one from each query.</p>
      </sec>
    </sec>
    <sec id="sec-6">
      <title>Building Sharing Plans</title>
      <p>Given a list of candidate SEs, this phase aims at building
covering subexpressions (CEs) corresponding to identified SEs, and
generate a set of candidate groups of CEs for their final selection.
Covering subexpressions. For each similar sub-query in the
same SE ωi , the goal is to produce a new plan to “cover” all
operations of each individual sub-query. Recall that all sub-trees
τj within a SE ωi share the same sub-query plan fingerprint: that
is, they operate on the same input relation(s) and apply the same
relational operators to generate intermediate output relations. If
the operator attributes are exactly the same across all τj , then
the CE will be identical to any of the τj . In general, however,
operators can have diferent attributes or predicates. In this case,
the CE construction is slightly more involved.</p>
      <p>First, we note that, by construction, the only shared
operators we consider are projections and selections. Indeed, for cache
unfriendly operators, the SE identification phase omits their
fingerprint from the lookup procedure (see Algorithm 1, lines 8-9).
Nevertheless, they could be included within a subtree, but they
are in any case “surrounded” by cache-friendly operators (see for
instance in Figure 1, the SE labeled as ψ1). As a consequence, a
CE can be constructed in a top-down manner, by “OR-ing” the
ifltering predicates and by “unioning” the projection columns of
the corresponding operators in the SE. The CE thus produces and
materializes all output records that are needed for its consumer
queries. Figure 2 illustrates an example of CE for a simple SE
of two sub-queries taken from the running example shown in
Figure 1. In particular, we consider the SE labeled as ψ2.</p>
      <p>The resulting CE contains the same operators as the subtrees
τj ∈ ωi , but with modified predicates or attribute lists.</p>
      <p>In general, we can build a CE, which we denote with Ω i , from a
f ()
SE ωi , by applying a transformation function f (), [τ1, ...τm ] −−→
τi∗, which trasforms a collection of similar sub-trees to a single,
covering sub-tree τi∗. Note that the resulting covering sub-tree
has the fingerprint of the sub-trees in ωi .</p>
      <p>Definition 4.4 (Covering subexpression). A Covering
subexpression (CE) Ω i = f (ωi ) is a sub-tree τi∗ derived from the SE ωi by
applying the transformation f (), with F (τi∗) = F (τj ) ∀τj ∈ ωi ,
such that all τj ∈ ωi can be derived from τi∗.</p>
      <p>In summary, the query plan τi∗ that composes Ω i contains
the same nodes as any subtree τj ∈ ωi , changing the predicates
of the selections (OR of all the predicates in τj ) and projections
(union of all the predicates in τj ).</p>
      <p>Once the set of CEs, Ω = {Ω 1, Ω 2, . . . }, has been derived from
the corresponding set of SEs, ω = {ω1, ω2, . . . }, we need to face
the problem of CE selection. The main question we need to answer
is: among the CEs contained in the set Ω , which ones should be
cached? Each CE covers diferent portions of the query logical
plans, therefore a CE may include another CE. Looking at the
running example shown in Figure 1, we have that Ω 1 (derived
from ω1, in the figure labeled with ψ1) contains Ω 3 (derived from
ω3 and labeled in the figure with ψ3). If we decide to store Ω 1 in
the cache, it becomes questionable to store Ω 3 as well.</p>
      <p>The next step of our process is then to identify the potential
combinations of mutually exclusive CEs that will be the input of
the optimization problem: each combination will have a value
and weight, where the value provides a measure of the work
sharing opportunities, and the weight indicates the amount of
space required to cache the CE in RAM. We start considering
how to compute such values and weights, and we proceed with
the algorithm to identify the potential combination of CEs.</p>
      <sec id="sec-6-1">
        <title>CE value and weight: a cost-based model. We use cardinality</title>
        <p>estimation and cost modeling to reason about the benefit of using
CEs. The objective is to estimate if a given CE, that could serve
multiple consumer queries, yields lower costs than executing
individually the original queries it subsumes.</p>
        <p>The cardinality estimator component analyzes relational
operators to estimate their output size. To do so, it first produces
statistics about input relations. At relation level, it obtains the
number of records and average record size. At column level, it
collects the min and max values, approximates column cardinality
and produces an equi-width histogram for each column.</p>
        <p>The cost estimator component uses the results from cardinality
estimation to approximate a (sub) query execution cost. We model
the total execution cost of a (sub) query as a combination of CPU,
disk and network I/O costs. Hence, given a sub-tree τj , we denote
by CE (τj ) the execution cost of sub-tree τj . This component
recursively analyzes, starting from the root of sub-tree τj , relational
operators to determine their cost (and their selectivity), which is
the multiplication between predefined constants (representative
of the compute cluster running the parallel processing
framework) and the estimated number of input and output records.
Given a SE ω = {τ1, τ2, . . . , τm }, the total execution cost C(ωi )
related to the execution of all similar sub-trees τj ∈ ωi without
the work-sharing optimization is given by</p>
        <p>C(ωi ) =</p>
        <p>CE (τj ).
m
Õ
j=1
Instead, the cost of using the corresponding CE Ω i must account
for both the execution cost of the common sub-tree τi∗, and
materialization (CW ) and retrieving (CR ) costs associated to the cache
operator we use in our approach, which accounts for write and
read operations:</p>
        <p>C(Ω i ) = CE (τi∗) + CW (|τi∗ |) + m · CR (|τi∗ |),
where both CW (|τi∗ |) and CR (|τi∗ |) are functions of the cardinality
|τi∗ | of the intermediate output relation obtained by executing τi∗.
Eq. 2 indicates that retrieving costs are “payed” by each of the m
consumer queries from the SE ωi that can use the CE Ω i .</p>
        <p>Then, we can derive the value of a CE Ω i , denoted by v(Ω i ), as
the diference between the cost of an unoptimized set of sub-trees
(execution of ωi ) and the cost of the CE Ω i :</p>
        <p>v(Ω i ) = C(ωi ) − C(Ω i ).</p>
        <p>From Equations 1 and 2, we note that v(Ω i ) is an increasing
function in m. Indeed, the more similar sub-queries a CE can
serve, the higher its value.</p>
        <p>Along with the value, we need to associate to a CE also a
weight, since the memory is limited and we need to take into
(1)
(2)
(3)</p>
        <sec id="sec-6-1-1">
          <title>Algorithm 2 Algorithm to generate CE candidates.</title>
          <p>Input: Set Ω of CEs
Output: Set of Knapsack items (potential CEs)
1: procedure GenerateKPitems(Ω = {Ω 1, Ω 2, . . . })
2: Ω exp ← ∅
3: while Ω not empty do
4: Ω i ← PopLargest(Ω )
5: DescSet ← FindDescendant(Ω i , Ω )
6: Groupi ← [Ω i ] ∪ Expand(DescSet)
7: Ω exp ← Ω exp ∪ {Groupi }
8: Remove(DescSet, Ω )
9: end while
10: return Ω exp
11: end procedure
account if a CE can fit in the cache. The weight, denoted by
w(Ω i ) is the size required to cache in RAM the output of Ω i , i.e.
w(Ω i ) = |τi∗ | =∆ |Ω i |.</p>
          <p>Having defined the CE value and weight, we describe next the
algorithm to identify the potential combination of CE.</p>
        </sec>
      </sec>
      <sec id="sec-6-2">
        <title>Generating the candidate set of CEs. Next, we focus on the</title>
        <p>problem of generating a combinatorial set of CEs, with their
associated value and weight, to be given as an input to the multi-query
optimization solver we have designed. Given the complexity of
the optimization task, our goal is to produce a small set of
valuable alternative options, which we call the candidate set of CEs.
We present an algorithm to produce such a set, but first illustrate
the challenges it addresses using the example shown in Fig. 1.</p>
        <p>Let’s focus on CE Ω 1 (corresponding to the sub-trees labeled as
ψ1). A naive enumeration of all possible choices of candidate CE
to be cached leads to the following, mutually exclusive options: (i)
Ω 1, (ii) Ω 2, (iii) Ω 3, (iv) both (Ω 2,Ω 3), (v) both (Ω 1,Ω 2), and (vi)
both (Ω 1,Ω 3). Intuitively, however, it is easy to discern valuable
from wasteful options. For example, the compound CE (Ω 1, Ω 2)
could be a good choice, since Ω 2 can be cached to serve query
1 and 2 – and of course used to build Ω 1 – and for query 3.
Conversely, caching the compound (Ω 1, Ω 3) brings less value,
since it only benefits query 1 and query 2, but costs more than
simply caching Ω 1, which also serves both query 1 and 2.</p>
        <p>It is thus important to define how to compute the value and
weight of compound CE. In this work we only consider compound
CEs for which value and weight are additive in the values and
weights of their components. This is achieved with compounds
of disjoint CEs, i.e., those that have no common sub-trees.</p>
        <p>For example, consider the two CEs Ω 1 and Ω 2, and the
subtrees used to build them. The CE Ω 2 is included in Ω 1, but only
some of the originating sub-trees of Ω 2 are included in the
originating sub-trees of Ω 1 (in particular, the ones in query 1 and 2, but
not in query 3). Given our definition of the value and the weight
of CEs, the value and the weight of the compound (Ω 1, Ω 2) may
not be equal to the sums of the values and of the weights of
each individual CE, since part of the CE need to be reused to
compute diferent sub-trees. Thus, we discard this option from
the candidate set.</p>
        <p>Algorithm 2 generates the candidate input for the optimization
solver as a set of non-overlapping groups of CEs; then, the
optimization algorithm selects a single candidate for each group in
order to determine the best set of CEs to store in memory. Given
the full set of Ω of CEs as input, we consider CE Ω i starting from
the root of the logical plan and remove it from the set (line 4). We
then look for its descendants from the input set Ω , i.e. all the CEs
contained in Ω i (line 5). With a CE and its descendant, we build
a list of options that contains (i) the CE itself and its individual
descendants, and (ii) all the compounds of disjoint descendant
CEs (line 6 and 7). We then remove the descendant from Ω and
continue the search for other groups.</p>
        <p>Considering our running example, we start from Ω = {Ω 1, Ω 2,
Ω 3, Ω 4}. The “largest” CE is Ω 1, and its descendants are Ω 2 and
Ω 3, therefore the list of mutually exclusive options for this group
would be [Ω 1, Ω 2, Ω 3, (Ω 2, Ω 3)]. The output of Alg. 2 then is:
{[Ω 1, Ω 2, Ω 3, (Ω 2, Ω 3)] , [Ω 4]} ,
(4)
where the notation (·, ·) indicates a compound CE, and [·, ·]
indicates a group of related CEs.</p>
        <p>Note that a CE may be part of more than one larger CE: to keep
the algorithm simple, we consider only the largest ancestor for
each CE. To each option, we associate the value and the weight
(in case of a compound, the sum of each component), that will
be used by the optimization solver.
4.3</p>
      </sec>
    </sec>
    <sec id="sec-7">
      <title>Sharing Plan Selection</title>
      <p>
        Next, we delve into our MQO problem formulation. In this work,
we model the process that selects which sharing plan to use as a
Multiple-choice Knapsack problem (MCKP) [
        <xref ref-type="bibr" rid="ref45">45</xref>
        ]. Essentially, the
knapsack contains items (that is, sharing plans or CEs) that have
a weight and a value. The knapsack capacity is constrained by a
constant c: this is representative of the memory constraints given
to the work sharing optimizer. Hence, the sum of the weights of
all items placed in the knapsack cannot exceed its capacity c.
      </p>
      <p>Our problem is thus to select which set of CEs (single, or
compound) to include in the knapsack. The output of the previous
phase (and in particular, the output of Algorithm 2) is a set
containing m groups of mutually exclusive options, or items. Each
group Gi , i = 1, 2, . . . , д, contains |Gi | items, which can be single
CE or compounds of CEs. For instance, looking at our running
example, the output shown in Eq. (4) contains д = 2 groups: the
ifrst group has 4 items, the second group just one item. Given a
group i, each item j has a value vi,j and a weight wi,j computed
as described in Sect. 4.2.</p>
      <p>The MCKP solver needs to choose at most one item from
each group such that the total value is maximized, while the
corresponding total weight must not exceed the capacity c. More
formally, the problem can be cast as following:</p>
      <p>Maximize
subject to
Õд |Gi |</p>
      <p>Õ
i=1 j=1
Õд |Gi |</p>
      <p>
        Õ
i=1 j=1
|Gi |
Õ
j=1
vi,j xi,j
wi,j xi,j ≤ c
xi,j ≤ 1, ∀i = 1 . . . д
(5)
xi,j ∈ {0, 1}, ∀i = 1 . . . д, j = 1 . . . |Gi |
where the variable xi,j indicates if item j from group i has been
selected or not. The MCKP is a well-known NP-Hard problem:
in this work, we implement a dynamic programming technique
to solve it [
        <xref ref-type="bibr" rid="ref46">46</xref>
        ].
      </p>
      <p>Note that alternative formulations exist, for which a provably
optimal greedy algorithm can be constructed: for example, we
could consider a fractional formulation of the knapsack problem.
This approach, however, would be feasible only if the underlying
query execution engine could support partial caching of a relation.
As it turns out, the system we target in our work does support
hierarchical storage levels for cached relations: what does not fit
in RAM, is automatically stored on disk. Although this represents
an interesting direction for future work (as it implies a linear
time greedy heuristic can be used), in this paper we limit our
attention to the 0/1 problem formulation.
4.4</p>
    </sec>
    <sec id="sec-8">
      <title>Query Rewriting</title>
      <p>The last step is to transform the original input queries to benefit
from the selected combination of cache plans.</p>
      <p>Recall that the output of a cache plan is materialized in RAM
after its execution. Then, for each input query that is a consumer
for a given cache plan, we build an extraction plan which
manipulates the cached data to produce the output relation, as it would
be obtained by the original input query. In other words, in the
general case, we apply the original input query to the cached
relation instead of using the original input relation. In the case of
a CE subsuming identical SEs, the extraction plan is an identity:
the original query simply replaces the sub-tree containing the
CE by its cached intermediate relation. Instead, if shared
operators are used – because of SEs having the same fingerprint but
diferent attributes – we build an extraction plan that applies the
original filter and projection predicates or attributes to “extract”
relevant tuples from the cached relation produced from the CE.</p>
      <p>Considering our running example, assume that the output of
the MCKP solver is to store Ω 2 and Ω 3 in cache. Ω 3 derives from
ω3, where the composing sub-trees (one from query 1, and one
from query 2) are the same, therefore the extraction plan will be
Ω 3 itself. Instead, ω2 (from which Ω 2 derives) contains sub-trees
with diferent filtering and projection predicates: when Ω 2 is
materialized in the cache, we need to apply the correct filtering
(e.g., “gender = F”) and projection predicates to extract the actual
result when considering the diferent queries.
5</p>
    </sec>
    <sec id="sec-9">
      <title>EXPERIMENTAL EVALUATION</title>
      <p>
        We now present experimental results to evaluate the efectiveness
of our methodology, which we implement for the Apache Spark
and SparkSQL systems – the details of the implementation can
be found in our companion TR [
        <xref ref-type="bibr" rid="ref48">48</xref>
        ]
Experimental setup. We run our experiments on a cluster
consisting of 8 server-grade worker nodes, with 8 cores each and a
1 Gbps commodity interconnect. Each worker is granted 30 GB
of RAM each, of which half is dedicated to caching. We use the
queries in the TPC-DS benchmark library for Spark SQL
developed by Databricks [
        <xref ref-type="bibr" rid="ref47">47</xref>
        ], and generate a CSV dataset with scaling
factor of 50. We use Apache Spark 2.0: for all test, we clear the
operating system’s bufer cache in all workers and master, and
disable the “data compression" feature of Spark.
      </p>
      <p>Results. We select a subset of all queries available in the TPC-DS
benchmark, and focus on the 50 queries that can be successfully
executed without failures or parsing errors. We present results
for a setup in which we consider all the 50 queries and execute
them in the order of their identifiers. Figure 3 shows the empirical
Cumulative Distribution Function (CDF) of the runtime ratios
between a system absorbing the workload with MQO enabled and
disabled. Overall, we note that, for 60% of the queries, we obtain
a 80% decrease of the runtime. In total, our approach reduces
the runtime for 82% of the queries. On the other hand, 18% of
the queries experience a larger runtime, which is explained by
the overheads associated to caching. Overall, our optimizer has
identified 60 SEs, and it has built 45 CEs. The cache used to store
the output is approximately 26 GB (out of 120 GB available). The
optimization process took less than 2 seconds, while the query
runtime are in the order of tens of minutes (individually) and
hours (all together).</p>
      <p>Next, we consider an experimental setup in which we emulate
the presence of a queuing component that triggers the execution
of our worksharing optimization. In particular, since TPC-DS
queries have no associated submission timestamp, we take a
randomized approach (without replacement) to select which queries
are submitted to the queuing component, and parametrize the
latter with the number of queries – we call this parameter the
window size – to accumulate before triggering our MQO
mechanism. For a given window size, we repeat the experiment, i.e.,
we randomly select queries from the full TPC-DS workload, 20
times, and we build the corresponding empirical CDF of the
runtime ratio, as defined above. We also measure the number of
SEs identified within the window size, and show the
corresponding empirical CDF. Given this setup, we consider all possible
combinations of queries to assess the benefits of worksharing.</p>
      <p>Figure 4 shows the boxplots of the runtime ratio (top) and
number of similar subexpression identified (bottom) for diferent
window sizes. The boxplots indicate the main percentiles (5%, 25%,
50%, 75%, 95%) of the empirical CDF, along with the average (red
lines). The Figure shows a clear pattern: as the size of the window
increases, there are more chances of finding a high number of SE,
thus better sharing opportunities, which translates into reduced
aggregate runtime. We observe a 20% decrease of the aggregate
runtime (median) with a window size of only five queries, which
ramps up to 45% when the window size is set to 20 queries.</p>
      <p>
        Note that a queuing mechanism can introduce an additional
delay for the execution of a query, because the system needs
to accumulate a suficient number of queries in the window
before triggering their optimization and execution. Investigating
the trade-of between eficiency and delay, as well as studying
scheduling policies to steer system behavior is part of our future
research agenda. Due to space contraints, we refer to [
        <xref ref-type="bibr" rid="ref48">48</xref>
        ] for
additional evaluations and discussion.
6
      </p>
    </sec>
    <sec id="sec-10">
      <title>CONCLUSION</title>
      <p>We presented a new approach to MQO that uses in-memory
caching to improve the eficiency of computing frameworks such
as Apache Spark. Our method takes a batch of input queries and
ifnds common (sub)expressions, leading to the construction of
covering expressions that subsume the individual work required
by each query. To make the search problem tractable, we used
several techniques: modified hash trees to quickly identify common
sub-graphs, and an algorithm to enumerate (and prune) feasible
common expressions. MQO was cast as a multiple-choice
knapsack problem: each feasible common expression was associated
with a value (representative of how much work could be shared
among queries) and a weight (representative of the memory
pressure imposed by caching the common data), and the goal was to
ifll a knapsack representative of memory constraints.</p>
      <p>To quantify the benefit of our approach, we implemented
a prototype for Apache Spark SQL, and we used well-known
workloads. Our results indicated that worksharing opportunities
are frequent, and that our method brings substantial benefits in
terms of reduced query runtime, with up to an 80% reduction for
a large fraction of the submitted queries.</p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          [1]
          <string-name>
            <given-names>J.</given-names>
            <surname>Dean</surname>
          </string-name>
          and
          <string-name>
            <given-names>S.</given-names>
            <surname>Ghemawat</surname>
          </string-name>
          , “
          <article-title>Mapreduce: simplified data processing on large clusters</article-title>
          ,
          <source>” Comm. of the ACM</source>
          , vol.
          <volume>51</volume>
          , no.
          <issue>1</issue>
          , pp.
          <fpage>107</fpage>
          -
          <lpage>113</lpage>
          ,
          <year>2008</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          [2]
          <string-name>
            <given-names>M.</given-names>
            <surname>Isard</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            <surname>Budiu</surname>
          </string-name>
          ,
          <string-name>
            <given-names>Y.</given-names>
            <surname>Yu</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Birrell</surname>
          </string-name>
          , and
          <string-name>
            <given-names>D.</given-names>
            <surname>Fetterly</surname>
          </string-name>
          , “
          <article-title>Dryad: distributed data-parallel programs from sequential building blocks,” in ACM SIGOPS Op</article-title>
          .
          <source>Systems Review</source>
          , vol.
          <volume>41</volume>
          , no.
          <issue>3</issue>
          ,
          <issue>2007</issue>
          , pp.
          <fpage>59</fpage>
          -
          <lpage>72</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          [3]
          <string-name>
            <given-names>M.</given-names>
            <surname>Zaharia</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            <surname>Chowdhury</surname>
          </string-name>
          ,
          <string-name>
            <surname>T. Das</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          <string-name>
            <surname>Dave</surname>
            , J. Ma,
            <given-names>M.</given-names>
          </string-name>
          <string-name>
            <surname>McCauley</surname>
            ,
            <given-names>M. J.</given-names>
          </string-name>
          <string-name>
            <surname>Franklin</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          <string-name>
            <surname>Shenker</surname>
            ,
            <given-names>and I. Stoica</given-names>
          </string-name>
          , “
          <article-title>Resilient distributed datasets: A fault-tolerant abstraction for in-memory cluster computing,”</article-title>
          <source>in Proc. of USENIX NSDI</source>
          ,
          <year>2012</year>
          , pp.
          <fpage>2</fpage>
          -
          <lpage>2</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          [4]
          <string-name>
            <given-names>P. K.</given-names>
            <surname>Gunda</surname>
          </string-name>
          ,
          <string-name>
            <given-names>L.</given-names>
            <surname>Ravindranath</surname>
          </string-name>
          ,
          <string-name>
            <given-names>C. A.</given-names>
            <surname>Thekkath</surname>
          </string-name>
          ,
          <string-name>
            <given-names>Y.</given-names>
            <surname>Yu</surname>
          </string-name>
          , and
          <string-name>
            <given-names>L.</given-names>
            <surname>Zhuang</surname>
          </string-name>
          , “Nectar:
          <article-title>Automatic management of data and computation in datacenters</article-title>
          .”
          <source>in Proc. of OSDI</source>
          , vol.
          <volume>10</volume>
          ,
          <year>2010</year>
          , pp.
          <fpage>1</fpage>
          -
          <lpage>8</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          [5]
          <string-name>
            <given-names>J.</given-names>
            <surname>Zhou</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.-A.</given-names>
            <surname>Larson</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.-C.</given-names>
            <surname>Freytag</surname>
          </string-name>
          , and W. Lehner, “
          <article-title>Eficient exploitation of similar subexpressions for query processing</article-title>
          ,”
          <source>in Proc. of ACM SIGMOD</source>
          ,
          <year>2007</year>
          , pp.
          <fpage>533</fpage>
          -
          <lpage>544</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          [6]
          <string-name>
            <given-names>T. K.</given-names>
            <surname>Sellis</surname>
          </string-name>
          , “
          <article-title>Multiple-query optimization</article-title>
          ,
          <source>” ACM Trans. Database Syst.</source>
          , vol.
          <volume>13</volume>
          , no.
          <issue>1</issue>
          , pp.
          <fpage>23</fpage>
          -
          <lpage>52</lpage>
          , Mar.
          <year>1988</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>
          [7]
          <string-name>
            <given-names>P.</given-names>
            <surname>Roy</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            <surname>Seshadri</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            <surname>Sudarshan</surname>
          </string-name>
          , and
          <string-name>
            <given-names>S.</given-names>
            <surname>Bhobe</surname>
          </string-name>
          , “
          <article-title>Eficient and extensible algorithms for multi query optimization,” in ACM SIGMOD Record</article-title>
          , vol.
          <volume>29</volume>
          , no.
          <issue>2</issue>
          ,
          <issue>2000</issue>
          , pp.
          <fpage>249</fpage>
          -
          <lpage>260</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          [8]
          <string-name>
            <given-names>J.</given-names>
            <surname>Goldstein</surname>
          </string-name>
          and P.-Å. Larson, “
          <article-title>Optimizing queries using materialized views: a practical, scalable solution,” in ACM SIGMOD Record</article-title>
          , vol.
          <volume>30</volume>
          , no.
          <issue>2</issue>
          ,
          <issue>2001</issue>
          , pp.
          <fpage>331</fpage>
          -
          <lpage>342</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref9">
        <mixed-citation>
          [9]
          <string-name>
            <given-names>H.</given-names>
            <surname>Mistry</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.</given-names>
            <surname>Roy</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            <surname>Sudarshan</surname>
          </string-name>
          , and
          <string-name>
            <given-names>K.</given-names>
            <surname>Ramamritham</surname>
          </string-name>
          , “
          <article-title>Materialized view selection and maintenance using multi-query optimization,” in ACM SIGMOD Record</article-title>
          , vol.
          <volume>30</volume>
          , no.
          <issue>2</issue>
          ,
          <issue>2001</issue>
          , pp.
          <fpage>307</fpage>
          -
          <lpage>318</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref10">
        <mixed-citation>
          [10]
          <string-name>
            <given-names>N. N.</given-names>
            <surname>Dalvi</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S. K.</given-names>
            <surname>Sanghai</surname>
          </string-name>
          ,
          <string-name>
            <given-names>R.</given-names>
            <surname>Parsan</surname>
          </string-name>
          , and
          <string-name>
            <given-names>S.</given-names>
            <surname>Sudarshan</surname>
          </string-name>
          , “Pipelining in multiquery optimization,”
          <source>in Proc. of ACM PODS</source>
          ,
          <year>2001</year>
          , pp.
          <fpage>59</fpage>
          -
          <lpage>70</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref11">
        <mixed-citation>
          [11]
          <string-name>
            <given-names>I.</given-names>
            <surname>Psaroudakis</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            <surname>Athanassoulis</surname>
          </string-name>
          ,
          <article-title>and</article-title>
          <string-name>
            <given-names>A.</given-names>
            <surname>Ailamaki</surname>
          </string-name>
          , “
          <article-title>Sharing data and work across concurrent analytical queries</article-title>
          ,
          <source>” VLDB Endowment</source>
          , vol.
          <volume>6</volume>
          , no.
          <issue>9</issue>
          , pp.
          <fpage>637</fpage>
          -
          <lpage>648</lpage>
          , Jul.
          <year>2013</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref12">
        <mixed-citation>
          [12]
          <string-name>
            <given-names>S.</given-names>
            <surname>Harizopoulos</surname>
          </string-name>
          ,
          <string-name>
            <given-names>V.</given-names>
            <surname>Shkapenyuk</surname>
          </string-name>
          ,
          <article-title>and</article-title>
          <string-name>
            <given-names>A.</given-names>
            <surname>Ailamaki</surname>
          </string-name>
          , “
          <article-title>Qpipe: A simultaneously pipelined relational query engine,”</article-title>
          <source>in Proc. of ACM SIGMOD</source>
          ,
          <year>2005</year>
          , pp.
          <fpage>383</fpage>
          -
          <lpage>394</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref13">
        <mixed-citation>
          [13]
          <string-name>
            <given-names>S.</given-names>
            <surname>Arumugam</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Dobra</surname>
          </string-name>
          ,
          <string-name>
            <given-names>C. M.</given-names>
            <surname>Jermaine</surname>
          </string-name>
          ,
          <string-name>
            <given-names>N.</given-names>
            <surname>Pansare</surname>
          </string-name>
          , and L. Perez, “
          <article-title>The datapath system: A data-centric analytic processing engine for large data warehouses,”</article-title>
          <source>in Proc. of ACM SIGMOD</source>
          ,
          <year>2010</year>
          , pp.
          <fpage>519</fpage>
          -
          <lpage>530</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref14">
        <mixed-citation>
          [14]
          <string-name>
            <given-names>G.</given-names>
            <surname>Giannikis</surname>
          </string-name>
          , G. Alonso, and
          <string-name>
            <given-names>D.</given-names>
            <surname>Kossmann</surname>
          </string-name>
          , “Shareddb:
          <article-title>Killing one thousand queries with one stone</article-title>
          ,
          <source>” VLDB Endowment</source>
          , vol.
          <volume>5</volume>
          , no.
          <issue>6</issue>
          , pp.
          <fpage>526</fpage>
          -
          <lpage>537</lpage>
          , Feb.
          <year>2012</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref15">
        <mixed-citation>
          [15]
          <string-name>
            <given-names>T.</given-names>
            <surname>Nykiel</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            <surname>Potamias</surname>
          </string-name>
          ,
          <string-name>
            <given-names>C.</given-names>
            <surname>Mishra</surname>
          </string-name>
          , G. Kollios, and
          <string-name>
            <given-names>N.</given-names>
            <surname>Koudas</surname>
          </string-name>
          , “Mrshare2:
          <article-title>Sharing across multiple queries in mapreduce</article-title>
          ,
          <source>” VLDB Endowment</source>
          , vol.
          <volume>3</volume>
          , no.
          <issue>1-2</issue>
          , pp.
          <fpage>494</fpage>
          -
          <lpage>505</lpage>
          , Sep.
          <year>2010</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref16">
        <mixed-citation>
          [16]
          <string-name>
            <given-names>G.</given-names>
            <surname>Wang and C.-Y. Chan</surname>
          </string-name>
          ,
          <article-title>“Multi-query optimization in mapreduce framework</article-title>
          ,
          <source>” VLDB Endowment</source>
          , vol.
          <volume>7</volume>
          , no.
          <issue>3</issue>
          , pp.
          <fpage>145</fpage>
          -
          <lpage>156</lpage>
          , Nov.
          <year>2013</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref17">
        <mixed-citation>
          [17]
          <string-name>
            <given-names>Y. N.</given-names>
            <surname>Silva</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.-A.</given-names>
            <surname>Larson</surname>
          </string-name>
          , and
          <string-name>
            <given-names>J.</given-names>
            <surname>Zhou</surname>
          </string-name>
          , “
          <article-title>Exploiting common subexpressions for cloud query processing</article-title>
          ,”
          <source>in Proc. of IEEE ICDE</source>
          ,
          <year>2012</year>
          , pp.
          <fpage>1337</fpage>
          -
          <lpage>1348</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref18">
        <mixed-citation>
          [18]
          <string-name>
            <given-names>A.</given-names>
            <surname>El-Helw</surname>
          </string-name>
          ,
          <string-name>
            <given-names>V.</given-names>
            <surname>Raghavan</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M. A.</given-names>
            <surname>Soliman</surname>
          </string-name>
          ,
          <string-name>
            <given-names>G.</given-names>
            <surname>Caragea</surname>
          </string-name>
          ,
          <string-name>
            <given-names>Z.</given-names>
            <surname>Gu</surname>
          </string-name>
          , and
          <string-name>
            <given-names>M.</given-names>
            <surname>Petropoulos</surname>
          </string-name>
          , “
          <article-title>Optimization of common table expressions in mpp database systems,” VLDB End.</article-title>
          , vol.
          <volume>8</volume>
          , no.
          <issue>12</issue>
          , pp.
          <fpage>1704</fpage>
          -
          <lpage>1715</lpage>
          ,
          <year>2015</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref19">
        <mixed-citation>
          [19]
          <string-name>
            <given-names>M.</given-names>
            <surname>Armbrust</surname>
          </string-name>
          , et al., “
          <article-title>Spark sql: Relational data processing in spark,”</article-title>
          <source>in Proc. of ACM SIGMOD</source>
          ,
          <year>2015</year>
          , pp.
          <fpage>1383</fpage>
          -
          <lpage>1394</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref20">
        <mixed-citation>
          [20]
          <string-name>
            <given-names>S.</given-names>
            <surname>Finkelstein</surname>
          </string-name>
          , “
          <article-title>Common expression analysis in database applications</article-title>
          ,”
          <source>in Proc. of ACM SIGMOD</source>
          ,
          <year>1982</year>
          , pp.
          <fpage>235</fpage>
          -
          <lpage>245</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref21">
        <mixed-citation>
          [21]
          <string-name>
            <given-names>J.</given-names>
            <surname>Shim</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.</given-names>
            <surname>Scheuermann</surname>
          </string-name>
          , and
          <string-name>
            <given-names>R.</given-names>
            <surname>Vingralek</surname>
          </string-name>
          , “
          <article-title>Dynamic caching of query results for decision support systems,”</article-title>
          <source>in Proc. of IEEE SSDBM</source>
          ,
          <year>1999</year>
          , pp.
          <fpage>254</fpage>
          -
          <lpage>.</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref22">
        <mixed-citation>
          [22]
          <string-name>
            <given-names>G.</given-names>
            <surname>Candea</surname>
          </string-name>
          ,
          <string-name>
            <given-names>N.</given-names>
            <surname>Polyzotis</surname>
          </string-name>
          , and
          <string-name>
            <given-names>R.</given-names>
            <surname>Vingralek</surname>
          </string-name>
          , “
          <article-title>Predictable performance and high query concurrency for data analytics,” The VLDB Journal</article-title>
          , vol.
          <volume>20</volume>
          , no.
          <issue>2</issue>
          , pp.
          <fpage>227</fpage>
          -
          <lpage>248</lpage>
          , Apr.
          <year>2011</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref23">
        <mixed-citation>
          [23] --, “
          <article-title>A scalable, predictable join operator for highly concurrent data warehouses</article-title>
          ,
          <source>” VLDB Endowment</source>
          , vol.
          <volume>2</volume>
          , no.
          <issue>1</issue>
          , pp.
          <fpage>277</fpage>
          -
          <lpage>288</lpage>
          , Aug.
          <year>2009</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref24">
        <mixed-citation>
          [24]
          <string-name>
            <given-names>J.</given-names>
            <surname>Yang</surname>
          </string-name>
          ,
          <string-name>
            <given-names>K.</given-names>
            <surname>Karlapalem</surname>
          </string-name>
          , and
          <string-name>
            <given-names>Q.</given-names>
            <surname>Li</surname>
          </string-name>
          , “
          <article-title>Algorithms for materialized view design in data warehousing environment,” in VLDB</article-title>
          , vol.
          <volume>97</volume>
          ,
          <year>1997</year>
          , pp.
          <fpage>25</fpage>
          -
          <lpage>29</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref25">
        <mixed-citation>
          [25]
          <string-name>
            <given-names>S.</given-names>
            <surname>Agrawal</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            <surname>Chaudhuri</surname>
          </string-name>
          , and
          <string-name>
            <given-names>V. R.</given-names>
            <surname>Narasayya</surname>
          </string-name>
          , “
          <article-title>Automated selection of materialized views and indexes in sql databases</article-title>
          .”
          <source>in VLDB</source>
          , vol.
          <year>2000</year>
          ,
          <year>2000</year>
          , pp.
          <fpage>496</fpage>
          -
          <lpage>505</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref26">
        <mixed-citation>
          [26]
          <string-name>
            <given-names>X.</given-names>
            <surname>Baril</surname>
          </string-name>
          and
          <string-name>
            <given-names>Z.</given-names>
            <surname>Bellahsene</surname>
          </string-name>
          , “
          <article-title>Selection of materialized views: A cost-based approach</article-title>
          ,” in
          <source>Advanced Information Systems Engineering</source>
          . Springer,
          <year>2003</year>
          , pp.
          <fpage>665</fpage>
          -
          <lpage>680</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref27">
        <mixed-citation>
          [27]
          <string-name>
            <given-names>C.</given-names>
            <surname>Zhang</surname>
          </string-name>
          and J.
          <string-name>
            <surname>Yang</surname>
          </string-name>
          , “
          <article-title>Genetic algorithm for materialized view selection in data warehouse environments,” in DataWarehousing and Knowledge Discovery</article-title>
          . Springer,
          <year>1999</year>
          , pp.
          <fpage>116</fpage>
          -
          <lpage>125</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref28">
        <mixed-citation>
          [28]
          <string-name>
            <given-names>R.</given-names>
            <surname>Derakhshan</surname>
          </string-name>
          ,
          <string-name>
            <given-names>F. K.</given-names>
            <surname>Dehne</surname>
          </string-name>
          ,
          <string-name>
            <given-names>O.</given-names>
            <surname>Korn</surname>
          </string-name>
          , and
          <string-name>
            <given-names>B.</given-names>
            <surname>Stantic</surname>
          </string-name>
          , “
          <article-title>Simulated annealing for materialized view selection in data warehousing environment</article-title>
          .
          <source>” in Databases and applications</source>
          ,
          <year>2006</year>
          , pp.
          <fpage>89</fpage>
          -
          <lpage>94</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref29">
        <mixed-citation>
          [29]
          <string-name>
            <given-names>P.</given-names>
            <surname>Kalnis</surname>
          </string-name>
          ,
          <string-name>
            <given-names>N.</given-names>
            <surname>Mamoulis</surname>
          </string-name>
          , and
          <string-name>
            <given-names>D.</given-names>
            <surname>Papadias</surname>
          </string-name>
          , “
          <article-title>View selection using randomized search,” Data &amp; Knowledge Engineering</article-title>
          , vol.
          <volume>42</volume>
          , no.
          <issue>1</issue>
          , pp.
          <fpage>89</fpage>
          -
          <lpage>111</lpage>
          ,
          <year>2002</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref30">
        <mixed-citation>
          [30]
          <string-name>
            <given-names>P.</given-names>
            <surname>Agrawal</surname>
          </string-name>
          ,
          <string-name>
            <given-names>D.</given-names>
            <surname>Kifer</surname>
          </string-name>
          , and
          <string-name>
            <given-names>C.</given-names>
            <surname>Olston</surname>
          </string-name>
          , “
          <article-title>Scheduling shared scans of large data ifles</article-title>
          ,
          <source>” VLDB Endowment</source>
          , vol.
          <volume>1</volume>
          , no.
          <issue>1</issue>
          , pp.
          <fpage>958</fpage>
          -
          <lpage>969</lpage>
          ,
          <year>2008</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref31">
        <mixed-citation>
          [31]
          <string-name>
            <given-names>P.</given-names>
            <surname>Bhatotia</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Wieder</surname>
          </string-name>
          ,
          <string-name>
            <given-names>R.</given-names>
            <surname>Rodrigues</surname>
          </string-name>
          ,
          <string-name>
            <given-names>U. A.</given-names>
            <surname>Acar</surname>
          </string-name>
          , and
          <string-name>
            <given-names>R.</given-names>
            <surname>Pasquin</surname>
          </string-name>
          , “Incoop:
          <article-title>Mapreduce for incremental computations,”</article-title>
          <source>in Proc. of ACM SoCC</source>
          ,
          <year>2011</year>
          , p.
          <fpage>7</fpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref32">
        <mixed-citation>
          [32]
          <string-name>
            <given-names>I.</given-names>
            <surname>Elghandour</surname>
          </string-name>
          and
          <string-name>
            <given-names>A.</given-names>
            <surname>Aboulnaga</surname>
          </string-name>
          , “
          <article-title>Restore: reusing results of mapreduce jobs</article-title>
          ,
          <source>” VLDB Endowment</source>
          , vol.
          <volume>5</volume>
          , no.
          <issue>6</issue>
          , pp.
          <fpage>586</fpage>
          -
          <lpage>597</lpage>
          ,
          <year>2012</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref33">
        <mixed-citation>
          [33]
          <string-name>
            <given-names>B.</given-names>
            <surname>Li</surname>
          </string-name>
          ,
          <string-name>
            <given-names>E.</given-names>
            <surname>Mazur</surname>
          </string-name>
          ,
          <string-name>
            <given-names>Y.</given-names>
            <surname>Diao</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>McGregor</surname>
          </string-name>
          ,
          <string-name>
            <given-names>and P.</given-names>
            <surname>Shenoy</surname>
          </string-name>
          , “
          <article-title>A platform for scalable one-pass analytics using mapreduce,”</article-title>
          <source>in Proc. of ACM SIGMOD</source>
          ,
          <year>2011</year>
          , pp.
          <fpage>985</fpage>
          -
          <lpage>996</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref34">
        <mixed-citation>
          [34] --, “
          <article-title>Scalla: a platform for scalable one-pass analytics using mapreduce,”</article-title>
          <source>ACM Trans. on Database Systems</source>
          , vol.
          <volume>37</volume>
          , no.
          <issue>4</issue>
          , p.
          <fpage>27</fpage>
          ,
          <year>2012</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref35">
        <mixed-citation>
          [35]
          <string-name>
            <given-names>J.</given-names>
            <surname>Camacho-Rodríguez</surname>
          </string-name>
          ,
          <string-name>
            <given-names>D.</given-names>
            <surname>Colazzo</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            <surname>Herschel</surname>
          </string-name>
          ,
          <string-name>
            <surname>I. Manolescu</surname>
          </string-name>
          , and
          <string-name>
            <given-names>S.</given-names>
            <surname>Roy</surname>
          </string-name>
          <string-name>
            <surname>Chowdhury</surname>
          </string-name>
          , “
          <article-title>Reuse-based optimization for pig latin</article-title>
          ,”
          <source>in Proceedings of the 25th ACM International on Conference on Information and Knowledge Management, ser. CIKM '16. ACM</source>
          ,
          <year>2016</year>
          , pp.
          <fpage>2215</fpage>
          -
          <lpage>2220</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref36">
        <mixed-citation>
          [36]
          <string-name>
            <given-names>L. L.</given-names>
            <surname>Perez</surname>
          </string-name>
          and
          <string-name>
            <surname>C. M. Jermaine</surname>
          </string-name>
          , “
          <article-title>History-aware query optimization with materialized intermediate views</article-title>
          ,”
          <source>in Proceedings of the 30th IEEE International Conference on Data Engineering</source>
          , Chicago,
          <string-name>
            <surname>ICDE</surname>
          </string-name>
          <year>2014</year>
          , IL, USA, March 31 - April 4,
          <year>2014</year>
          ,
          <year>2014</year>
          , pp.
          <fpage>520</fpage>
          -
          <lpage>531</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref37">
        <mixed-citation>
          [37]
          <string-name>
            <given-names>A.</given-names>
            <surname>Jindal</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            <surname>Qiao</surname>
          </string-name>
          ,
          <string-name>
            <given-names>H.</given-names>
            <surname>Patel</surname>
          </string-name>
          ,
          <string-name>
            <given-names>Z.</given-names>
            <surname>Yin</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Di</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            <surname>Bag</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            <surname>Friedman</surname>
          </string-name>
          ,
          <string-name>
            <given-names>Y.</given-names>
            <surname>Lin</surname>
          </string-name>
          ,
          <string-name>
            <given-names>K.</given-names>
            <surname>Karanasos</surname>
          </string-name>
          , and
          <string-name>
            <given-names>S.</given-names>
            <surname>Rao</surname>
          </string-name>
          , “
          <article-title>Computation reuse in analytics job service at microsoft</article-title>
          ,”
          <source>in Proceedings of the 2018 International Conference on Management of Data, ser. SIGMOD '18</source>
          . New York, NY, USA: ACM,
          <year>2018</year>
          , pp.
          <fpage>191</fpage>
          -
          <lpage>203</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref38">
        <mixed-citation>
          [38]
          <string-name>
            <given-names>A.</given-names>
            <surname>Jindal</surname>
          </string-name>
          ,
          <string-name>
            <given-names>K.</given-names>
            <surname>Karanasos</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            <surname>Rao</surname>
          </string-name>
          , and
          <string-name>
            <given-names>H.</given-names>
            <surname>Patel</surname>
          </string-name>
          , “Selecting subexpressions to materialize at datacenter scale,
          <source>” Proc. VLDB Endow.</source>
          , vol.
          <volume>11</volume>
          , no.
          <issue>7</issue>
          , pp.
          <fpage>800</fpage>
          -
          <lpage>812</lpage>
          , Mar.
          <year>2018</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref39">
        <mixed-citation>
          [39]
          <string-name>
            <given-names>T.</given-names>
            <surname>Azim</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            <surname>Karpathiotakis</surname>
          </string-name>
          ,
          <article-title>and</article-title>
          <string-name>
            <given-names>A.</given-names>
            <surname>Ailamaki</surname>
          </string-name>
          , “Recache:
          <article-title>Reactive caching for fast analytics over heterogeneous data</article-title>
          ,
          <source>” VLDB Endowment</source>
          , vol.
          <volume>11</volume>
          , no.
          <issue>3</issue>
          ,
          <year>2017</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref40">
        <mixed-citation>
          [40]
          <string-name>
            <given-names>K.</given-names>
            <surname>Dursun</surname>
          </string-name>
          ,
          <string-name>
            <given-names>C.</given-names>
            <surname>Binnig</surname>
          </string-name>
          ,
          <string-name>
            <given-names>U.</given-names>
            <surname>Cetintemel</surname>
          </string-name>
          , and T. Kraska, “
          <article-title>Revisiting reuse in main memory database systems,”</article-title>
          <source>in Proc. of ACM SIGMOD</source>
          ,
          <year>2017</year>
          , pp.
          <fpage>1275</fpage>
          -
          <lpage>1289</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref41">
        <mixed-citation>
          [41]
          <string-name>
            <given-names>A.</given-names>
            <surname>Floratou</surname>
          </string-name>
          ,
          <string-name>
            <given-names>N.</given-names>
            <surname>Megiddo</surname>
          </string-name>
          ,
          <string-name>
            <given-names>N.</given-names>
            <surname>Potti</surname>
          </string-name>
          ,
          <string-name>
            <given-names>F.</given-names>
            <surname>Özcan</surname>
          </string-name>
          ,
          <string-name>
            <given-names>U.</given-names>
            <surname>Kale</surname>
          </string-name>
          , and J.
          <string-name>
            <surname>Schmitz-Hermes</surname>
          </string-name>
          , “
          <article-title>Adaptive caching in big sql using the hdfs cache,”</article-title>
          <source>in Proc. of ACM SoCC</source>
          ,
          <year>2016</year>
          , pp.
          <fpage>321</fpage>
          -
          <lpage>333</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref42">
        <mixed-citation>
          [42]
          <string-name>
            <given-names>M. G.</given-names>
            <surname>Ivanova</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M. L.</given-names>
            <surname>Kersten</surname>
          </string-name>
          ,
          <string-name>
            <given-names>N. J.</given-names>
            <surname>Nes</surname>
          </string-name>
          , and
          <string-name>
            <given-names>R. A.</given-names>
            <surname>Gonçalves</surname>
          </string-name>
          , “
          <article-title>An architecture for recycling intermediates in a column-store,”</article-title>
          <source>ACM Trans. on Database Systems</source>
          , vol.
          <volume>35</volume>
          , no.
          <issue>4</issue>
          , p.
          <fpage>24</fpage>
          ,
          <year>2010</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref43">
        <mixed-citation>
          [43]
          <string-name>
            <given-names>F.</given-names>
            <surname>Nagel</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.</given-names>
            <surname>Boncz</surname>
          </string-name>
          , and
          <string-name>
            <given-names>S. D.</given-names>
            <surname>Viglas</surname>
          </string-name>
          , “
          <article-title>Recycling in pipelined query evaluation,”</article-title>
          <source>in Proc. of IEEE ICDE</source>
          ,
          <year>2013</year>
          , pp.
          <fpage>338</fpage>
          -
          <lpage>349</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref44">
        <mixed-citation>
          [44]
          <string-name>
            <given-names>R. C.</given-names>
            <surname>Merkle</surname>
          </string-name>
          , “
          <article-title>Protocols for public key cryptosystems</article-title>
          ,
          <source>” IEEE Symposium on Security and Privacy</source>
          , p.
          <fpage>122</fpage>
          ,
          <year>1980</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref45">
        <mixed-citation>
          [45]
          <string-name>
            <given-names>P.</given-names>
            <surname>Sinha</surname>
          </string-name>
          and
          <string-name>
            <given-names>A. A.</given-names>
            <surname>Zoltners</surname>
          </string-name>
          , “
          <article-title>The multiple-choice knapsack problem</article-title>
          ,
          <source>” Operations Research</source>
          , vol.
          <volume>27</volume>
          , no.
          <issue>3</issue>
          , pp.
          <fpage>503</fpage>
          -
          <lpage>515</lpage>
          ,
          <year>1979</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref46">
        <mixed-citation>
          [46]
          <string-name>
            <given-names>H.</given-names>
            <surname>Kellerer</surname>
          </string-name>
          ,
          <string-name>
            <given-names>U.</given-names>
            <surname>Pferschy</surname>
          </string-name>
          , and
          <string-name>
            <given-names>D.</given-names>
            <surname>Pisinger</surname>
          </string-name>
          ,
          <article-title>Introduction to NP-Completeness of knapsack problems</article-title>
          . Springer,
          <year>2004</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref47">
        <mixed-citation>
          [47] “
          <article-title>Spark sql performance test</article-title>
          ,” https://github.com/databricks/spark-sql-perf.
        </mixed-citation>
      </ref>
      <ref id="ref48">
        <mixed-citation>
          [48]
          <string-name>
            <given-names>P.</given-names>
            <surname>Michiardi</surname>
          </string-name>
          ,
          <string-name>
            <given-names>D.</given-names>
            <surname>Carra</surname>
          </string-name>
          , and
          <string-name>
            <given-names>S.</given-names>
            <surname>Migliorini</surname>
          </string-name>
          , “
          <article-title>Cache-based multi-query optimization for data-intensive scalable computing frameworks</article-title>
          ,” arXiv preprint arXiv:
          <year>1805</year>
          .08650,
          <year>2018</year>
          .
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>