Repository: incubatorimpala
Updated Branches:
refs/heads/master 26a3d04b8 > 541180105
IMPALA4164: Avoid overly aggressive inlining in LLVM IR
When generating IR functions during codegen, we used to
always tag the functions with the "AlwaysInline" attribute.
That potentially leads to excessive inlining, causing very
long optimization / compilation time with marginal performance
benefit at runtime. One of the reasons for doing it was that
the "targetcpu" and "targetfeatures" attributes were
missing in the generated IR functions so the LLVM inliner
considers them incompatible with the crosscompiled functions.
As a result, the inliner will not inline the generated IR
functions into crosscompiled functions and vice versa unless
the "AlwaysInline" attributes exist.
This change fixes the problem above by setting the "targetcpu"
and "targetfeatures" attributes of all IR functions to match
that of of the host's CPUs so both generated IR functions and
crosscompiled functions will have the same values for those
attributes. With these attributes set, we now rely on the
inliner of LLVM to determine whether a function is worth being
inlined. With this change, the codegen time of a query with very
long predicate went from 15s to 4s and the overall runtime went
from 19s to 8s.
ChangeId: I2d87ae8d222b415587e7320cb9072e4a8d6615ce
Reviewedon: http://gerrit.cloudera.org:8080/6941
Reviewedby: Michael Ho <kwho@cloudera.com>
Testedby: Impala Public Jenkins
Project: http://gitwipus.apache.org/repos/asf/incubatorimpala/repo
Commit: http://gitwipus.apache.org/repos/asf/incubatorimpala/commit/91237051
Tree: http://gitwipus.apache.org/repos/asf/incubatorimpala/tree/91237051
Diff: http://gitwipus.apache.org/repos/asf/incubatorimpala/diff/91237051
Branch: refs/heads/master
Commit: 91237051af9fd02f8aba5987e25f21ca98b33e52
Parents: 26a3d04
Author: Michael Ho <kwho@cloudera.com>
Authored: Fri May 19 00:12:45 2017 0700
Committer: Impala Public Jenkins <impalapublicjenkins@gerrit.cloudera.org>
Committed: Thu Jun 8 00:16:12 2017 +0000

be/src/codegen/llvmcodegen.cc  30 ++
be/src/codegen/llvmcodegen.h  14 +
.../queries/primitive_long_predicate.test  182 +++++++++++++++++++
3 files changed, 214 insertions(+), 12 deletions()

http://gitwipus.apache.org/repos/asf/incubatorimpala/blob/91237051/be/src/codegen/llvmcodegen.cc

diff git a/be/src/codegen/llvmcodegen.cc b/be/src/codegen/llvmcodegen.cc
index cdc0c53..1a4fd8b 100644
 a/be/src/codegen/llvmcodegen.cc
+++ b/be/src/codegen/llvmcodegen.cc
@@ 104,6 +104,7 @@ namespace impala {
bool LlvmCodeGen::llvm_initialized_ = false;
string LlvmCodeGen::cpu_name_;
vector<string> LlvmCodeGen::cpu_attrs_;
+string LlvmCodeGen::target_features_attr_;
CodegenCallGraph LlvmCodeGen::shared_call_graph_;
[[noreturn]] static void LlvmCodegenHandleError(
@@ 134,8 +135,8 @@ Status LlvmCodeGen::InitializeLlvm(bool load_backend) {
cpu_name_ = llvm::sys::getHostCPUName().str();
LOG(INFO) << "CPU class for runtime code generation: " << cpu_name_;
GetHostCPUAttrs(&cpu_attrs_);
 LOG(INFO) << "CPU flags for runtime code generation: "
 << boost::algorithm::join(cpu_attrs_, ",");
+ target_features_attr_ = boost::algorithm::join(cpu_attrs_, ",");
+ LOG(INFO) << "CPU flags for runtime code generation: " << target_features_attr_;
// Write an empty map file for perf to find.
if (FLAGS_perf_map) CodegenSymbolEmitter::WritePerfMap();
@@ 150,7 +151,7 @@ Status LlvmCodeGen::InitializeLlvm(bool load_backend) {
// Validate the module by verifying that functions for all IRFunction::Type
// can be found.
for (int i = IRFunction::FN_START; i < IRFunction::FN_END; ++i) {
 DCHECK(FN_MAPPINGS[i].fn == i);
+ DCHECK_EQ(FN_MAPPINGS[i].fn, i);
const string& fn_name = FN_MAPPINGS[i].fn_name;
if (init_codegen>module_>getFunction(fn_name) == nullptr) {
return Status(Substitute("Failed to find function $0", fn_name));
@@ 589,6 +590,7 @@ Status LlvmCodeGen::MaterializeFunctionHelper(Function *fn) {
// Materialized functions are marked as not materializable by LLVM.
DCHECK(!fn>isMaterializable());
+ SetCPUAttrs(fn);
const unordered_set<string>* callees = shared_call_graph_.GetCallees(fn>getName());
if (callees != nullptr) {
for (const string& callee : *callees) {
@@ 628,8 +630,6 @@ Function* LlvmCodeGen::GetFunction(IRFunction::Type ir_type, bool clone)
{
LOG(ERROR) << "Unable to locate function " << fn_name;
return NULL;
}
 // Mixing "NoInline" with "AlwaysInline" will lead to compilation failure.
 if (!fn>hasFnAttribute(Attribute::NoInline)) fn>addFnAttr(Attribute::AlwaysInline);
loaded_functions_[ir_type] = fn;
}
Status status = MaterializeFunction(fn);
@@ 692,9 +692,20 @@ bool LlvmCodeGen::VerifyFunction(Function* fn) {
void LlvmCodeGen::SetNoInline(llvm::Function* function) const {
function>removeFnAttr(llvm::Attribute::AlwaysInline);
+ function>removeFnAttr(llvm::Attribute::InlineHint);
function>addFnAttr(llvm::Attribute::NoInline);
}
+void LlvmCodeGen::SetCPUAttrs(llvm::Function* function) {
+ // Set all functions' "targetcpu" and "targetfeatures" to match the
+ // host's CPU's features. It's assumed that the functions don't use CPU
+ // features which the host doesn't support. CreateFromMemory() checks
+ // the features of the host's CPU and loads the module compatible with
+ // the host's CPU.
+ function>addFnAttr("targetcpu", cpu_name_);
+ function>addFnAttr("targetfeatures", target_features_attr_);
+}
+
LlvmCodeGen::FnPrototype::FnPrototype(
LlvmCodeGen* codegen, const string& name, Type* ret_type)
: codegen_(codegen), name_(name), ret_type_(ret_type) {
@@ 951,10 +962,7 @@ Function* LlvmCodeGen::CloneFunction(Function* fn) {
}
Function* LlvmCodeGen::FinalizeFunction(Function* function) {
 if (LIKELY(!function>hasFnAttribute(llvm::Attribute::NoInline))) {
 function>addFnAttr(llvm::Attribute::AlwaysInline);
 }

+ SetCPUAttrs(function);
if (!VerifyFunction(function)) {
function>eraseFromParent(); // deletes function
return NULL;
@@ 1080,7 +1088,9 @@ Status LlvmCodeGen::OptimizeModule() {
pass_builder.OptLevel = 2;
// Don't optimize for code size (this corresponds to O2/O3)
pass_builder.SizeLevel = 0;
 pass_builder.Inliner = createFunctionInliningPass();
+ // Use a threshold equivalent to adding InlineHint on all functions.
+ // This results in slightly better performance than the default threshold (225).
+ pass_builder.Inliner = createFunctionInliningPass(325);
// The TargetIRAnalysis pass is required to provide information about the target
// machine to optimisation passes, e.g. the cost model.
http://gitwipus.apache.org/repos/asf/incubatorimpala/blob/91237051/be/src/codegen/llvmcodegen.h

diff git a/be/src/codegen/llvmcodegen.h b/be/src/codegen/llvmcodegen.h
index 5c26c14..07aae55 100644
 a/be/src/codegen/llvmcodegen.h
+++ b/be/src/codegen/llvmcodegen.h
@@ 407,8 +407,8 @@ class LlvmCodeGen {
llvm::Function* GetFnvHashFunction(int num_bytes = 1);
llvm::Function* GetMurmurHashFunction(int num_bytes = 1);
 /// Set the NoInline attribute on 'function' and remove the AlwaysInline attribute if
 /// present.
+ /// Set the NoInline attribute on 'function' and remove the AlwaysInline and InlineHint
+ /// attributes if present.
void SetNoInline(llvm::Function* function) const;
/// Allocate stack storage for local variables. This is similar to traditional c, where
@@ 570,6 +570,11 @@ class LlvmCodeGen {
/// anyway (they must be explicitly invoked) so it is dead code.
static void StripGlobalCtorsDtors(llvm::Module* module);
+ /// Set the "targetcpu" and "targetfeatures" of 'function' to match the host's CPU's
+ /// features. Having consistent attributes for all materialized functions allows
+ /// generated IR to be inlined into crosscompiled functions' IR and vice versa.
+ static void SetCPUAttrs(llvm::Function* function);
+
// Setup any JIT listeners to process generated machine code object, e.g. to generate
// perf symbol map or disassembly.
void SetupJITListeners();
@@ 640,6 +645,11 @@ class LlvmCodeGen {
static std::string cpu_name_;
static std::vector<std::string> cpu_attrs_;
+ /// Value of "targetfeatures" attribute to be set on all IR functions. Derived from
+ /// 'cpu_attrs_'. Using a consistent value for this attribute among handcrafted IR
+ /// and crosscompiled functions allow them to be inlined into each other.
+ static std::string target_features_attr_;
+
/// A global shared call graph for all IR functions in the main module.
/// Used for determining dependencies when materializing IR functions.
static CodegenCallGraph shared_call_graph_;
http://gitwipus.apache.org/repos/asf/incubatorimpala/blob/91237051/testdata/workloads/targetedperf/queries/primitive_long_predicate.test

diff git a/testdata/workloads/targetedperf/queries/primitive_long_predicate.test b/testdata/workloads/targetedperf/queries/primitive_long_predicate.test
new file mode 100644
index 0000000..b7ae8c8
 /dev/null
+++ b/testdata/workloads/targetedperf/queries/primitive_long_predicate.test
@@ 0,0 +1,182 @@
+====
+ QUERY: primitive_long_predicate
+ Description: A simple scan with extremely long predicate.
+ Target test case: Query generated by BI tools with complex expressions. Aim to
+ exercise long codegen time due to inlining. Intentionally disabled query rewrite
+ in the FE to expose the long expressions to the BE.
+SELECT COUNT(*)
+FROM lineitem
+WHERE ((l_orderkey = 520 AND l_shipdate between "20170101 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 534 AND l_shipdate between "20170102 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 518 AND l_shipdate between "20170103 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 535 AND l_shipdate between "20170104 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 496 AND l_shipdate between "20170105 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 497 AND l_shipdate between "20170106 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 516 AND l_shipdate between "20170107 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 531 AND l_shipdate between "20170108 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 533 AND l_shipdate between "20170109 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 532 AND l_shipdate between "20170110 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 546 AND l_shipdate between "20170111 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 549 AND l_shipdate between "20170112 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 548 AND l_shipdate between "20170113 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 547 AND l_shipdate between "20170114 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 513 AND l_shipdate between "20170115 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 515 AND l_shipdate between "20170116 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 507 AND l_shipdate between "20170117 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 509 AND l_shipdate between "20170118 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 519 AND l_shipdate between "20170119 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 527 AND l_shipdate between "20170120 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 501 AND l_shipdate between "20170121 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 544 AND l_shipdate between "20170122 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 545 AND l_shipdate between "20170123 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 541 AND l_shipdate between "20170124 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 550 AND l_shipdate between "20170125 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 529 AND l_shipdate between "20170126 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 528 AND l_shipdate between "20170127 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 537 AND l_shipdate between "20170128 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 538 AND l_shipdate between "20170129 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 506 AND l_shipdate between "20170130 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 502 AND l_shipdate between "20170131 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 543 AND l_shipdate between "20170301 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 390 AND l_shipdate between "20170302 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 389 AND l_shipdate between "20170303 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 0 AND l_shipdate between "20170304 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 852 AND l_shipdate between "20170305 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 853 AND l_shipdate between "20170306 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 854 AND l_shipdate between "20170307 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 844 AND l_shipdate between "20170308 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 846 AND l_shipdate between "20170309 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 843 AND l_shipdate between "20170310 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 849 AND l_shipdate between "20170311 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 850 AND l_shipdate between "20170312 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 847 AND l_shipdate between "20170313 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 746 AND l_shipdate between "20170314 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 745 AND l_shipdate between "20170315 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 901 AND l_shipdate between "20170316 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 899 AND l_shipdate between "20170317 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 895 AND l_shipdate between "20170318 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 878 AND l_shipdate between "20170319 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 884 AND l_shipdate between "20170320 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 871 AND l_shipdate between "20170321 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 872 AND l_shipdate between "20170322 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 886 AND l_shipdate between "20170323 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 879 AND l_shipdate between "20170324 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 864 AND l_shipdate between "20170325 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 889 AND l_shipdate between "20170326 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 885 AND l_shipdate between "20170327 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 848 AND l_shipdate between "20170328 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 888 AND l_shipdate between "20170329 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 863 AND l_shipdate between "20170330 12:00:00" AND "20170417 02:22:02")
OR
+ (l_orderkey = 930 AND l_shipdate between "20170331 12:00:00" AND "20170417 02:22:03")
OR
+ (l_orderkey = 891 AND l_shipdate between "20170501 12:00:00" AND "20170617 02:22:02")
OR
+ (l_orderkey = 890 AND l_shipdate between "20170502 12:00:00" AND "20170617 02:22:03")
OR
+ (l_orderkey = 926 AND l_shipdate between "20170503 12:00:00" AND "20170617 02:22:02")
OR
+ (l_orderkey = 927 AND l_shipdate between "20170504 12:00:00" AND "20170617 02:22:03")
OR
+ (l_orderkey = 892 AND l_shipdate between "20170505 12:00:00" AND "20170617 02:22:02")
OR
+ (l_orderkey = 925 AND l_shipdate between "20170506 12:00:00" AND "20170617 02:22:03")
OR
+ (l_orderkey = 887 AND l_shipdate between "20170507 12:00:00" AND "20170617 02:22:02")
OR
+ (l_orderkey = 898 AND l_shipdate between "20170508 12:00:00" AND "20170617 02:22:03")
OR
+ (l_orderkey = 902 AND l_shipdate between "20170509 12:00:00" AND "20170617 02:22:02")
OR
+ (l_orderkey = 903 AND l_shipdate between "20170510 12:00:00" AND "20170617 02:22:03")
OR
+ (l_orderkey = 904 AND l_shipdate between "20170511 12:00:00" AND "20170617 02:22:02")
OR
+ (l_orderkey = 897 AND l_shipdate between "20170512 12:00:00" AND "20170617 02:22:03")
OR
+ (l_orderkey = 900 AND l_shipdate between "20170513 12:00:00" AND "20170617 02:22:02")
OR
+ (l_orderkey = 598 AND l_shipdate between "20170514 12:00:00" AND "20170617 02:22:03")
OR
+ (l_orderkey = 597 AND l_shipdate between "20170515 12:00:00" AND "20170617 02:22:02")
OR
+ (l_orderkey = 607 AND l_shipdate between "20170516 12:00:00" AND "20170617 02:22:03")
OR
+ (l_orderkey = 288 AND l_shipdate between "20170101 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 289 AND l_shipdate between "20170102 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 281 AND l_shipdate between "20170103 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 287 AND l_shipdate between "20170104 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 290 AND l_shipdate between "20170105 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 264 AND l_shipdate between "20170106 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 292 AND l_shipdate between "20170107 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 241 AND l_shipdate between "20170108 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 291 AND l_shipdate between "20170109 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 286 AND l_shipdate between "20170110 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 148 AND l_shipdate between "20170111 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 298 AND l_shipdate between "20170112 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 278 AND l_shipdate between "20170113 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 284 AND l_shipdate between "20170114 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 285 AND l_shipdate between "20170115 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 283 AND l_shipdate between "20170116 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 295 AND l_shipdate between "20170117 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 296 AND l_shipdate between "20170118 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 293 AND l_shipdate between "20170119 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 294 AND l_shipdate between "20170120 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 282 AND l_shipdate between "20170121 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 263 AND l_shipdate between "20170122 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 297 AND l_shipdate between "20170123 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 299 AND l_shipdate between "20170124 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 300 AND l_shipdate between "20170125 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 265 AND l_shipdate between "20170126 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 267 AND l_shipdate between "20170127 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 520 AND l_shipdate between "20170128 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 534 AND l_shipdate between "20170129 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 518 AND l_shipdate between "20170130 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 535 AND l_shipdate between "20170131 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 496 AND l_shipdate between "20170201 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 497 AND l_shipdate between "20170202 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 516 AND l_shipdate between "20170203 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 531 AND l_shipdate between "20170204 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 533 AND l_shipdate between "20170205 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 532 AND l_shipdate between "20170206 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 546 AND l_shipdate between "20170207 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 549 AND l_shipdate between "20170208 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 548 AND l_shipdate between "20170209 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 547 AND l_shipdate between "20170210 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 513 AND l_shipdate between "20170211 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 515 AND l_shipdate between "20170212 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 507 AND l_shipdate between "20170213 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 509 AND l_shipdate between "20170214 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 519 AND l_shipdate between "20170215 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 527 AND l_shipdate between "20170216 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 503 AND l_shipdate between "20170217 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 498 AND l_shipdate between "20170218 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 501 AND l_shipdate between "20170219 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 544 AND l_shipdate between "20170220 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 545 AND l_shipdate between "20170221 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 540 AND l_shipdate between "20170222 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 541 AND l_shipdate between "20170223 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 550 AND l_shipdate between "20170224 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 529 AND l_shipdate between "20170225 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 528 AND l_shipdate between "20170301 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 537 AND l_shipdate between "20170302 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 538 AND l_shipdate between "20170303 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 506 AND l_shipdate between "20170304 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 500 AND l_shipdate between "20170305 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 539 AND l_shipdate between "20170306 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 512 AND l_shipdate between "20170307 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 502 AND l_shipdate between "20170308 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 504 AND l_shipdate between "20170309 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 543 AND l_shipdate between "20170310 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 390 AND l_shipdate between "20170311 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 389 AND l_shipdate between "20170312 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 0 AND l_shipdate between "20170313 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 844 AND l_shipdate between "20170314 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 846 AND l_shipdate between "20170315 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 894 AND l_shipdate between "20170316 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 843 AND l_shipdate between "20170317 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 744 AND l_shipdate between "20170401 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 847 AND l_shipdate between "20170402 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 746 AND l_shipdate between "20170403 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 745 AND l_shipdate between "20170404 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 893 AND l_shipdate between "20170405 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 901 AND l_shipdate between "20170406 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 899 AND l_shipdate between "20170407 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 878 AND l_shipdate between "20170408 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 884 AND l_shipdate between "20170409 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 883 AND l_shipdate between "20170410 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 879 AND l_shipdate between "20170411 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 929 AND l_shipdate between "20170412 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 885 AND l_shipdate between "20170413 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 891 AND l_shipdate between "20170414 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 892 AND l_shipdate between "20170415 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 882 AND l_shipdate between "20170416 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 898 AND l_shipdate between "20170417 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 876 AND l_shipdate between "20170418 12:00:00" AND "20170418 02:22:02")
OR
+ (l_orderkey = 743 AND l_shipdate between "20170419 12:00:00" AND "20170618 02:22:02")
OR
+ (l_orderkey = 900 AND l_shipdate between "20170420 12:00:00" AND "20170618 02:22:02"));
+ RESULTS
+ TYPES
+====
