Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 0 additions & 34 deletions be/src/codegen/doris_ir.h

This file was deleted.

31 changes: 0 additions & 31 deletions be/src/common/hdfs.h

This file was deleted.

32 changes: 1 addition & 31 deletions be/src/common/logging.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,34 +15,8 @@
// specific language governing permissions and limitations
// under the License.

#ifndef IMPALA_COMMON_LOGGING_H
#define IMPALA_COMMON_LOGGING_H
#pragma once

// This is a wrapper around the glog header. When we are compiling to IR,
// we don't want to pull in the glog headers. Pulling them in causes linking
// issues when we try to dynamically link the codegen'd functions.
#ifdef IR_COMPILE
#include <iostream>
#define DCHECK(condition) \
while (false) std::cout
#define DCHECK_EQ(a, b) \
while (false) std::cout
#define DCHECK_NE(a, b) \
while (false) std::cout
#define DCHECK_GT(a, b) \
while (false) std::cout
#define DCHECK_LT(a, b) \
while (false) std::cout
#define DCHECK_GE(a, b) \
while (false) std::cout
#define DCHECK_LE(a, b) \
while (false) std::cout
// Similar to how glog defines DCHECK for release.
#define LOG(level) \
while (false) std::cout
#define VLOG(level) \
while (false) std::cout
#else
// GLOG defines this based on the system but doesn't check if it's already
// been defined. undef it first to avoid warnings.
// glog MUST be included before gflags. Instead of including them,
Expand All @@ -52,7 +26,6 @@
// function to get the stack trace.
#include <glog/logging.h>
#undef MutexLock
#endif

// Define VLOG levels. We want display per-row info less than per-file which
// is less than per-query. For now per-connection is the same as per-query.
Expand All @@ -67,7 +40,6 @@
#define VLOG_NOTICE VLOG(3)
#define VLOG_CRITICAL VLOG(1)


#define VLOG_CONNECTION_IS_ON VLOG_IS_ON(1)
#define VLOG_RPC_IS_ON VLOG_IS_ON(8)
#define VLOG_QUERY_IS_ON VLOG_IS_ON(1)
Expand All @@ -78,12 +50,10 @@
#define VLOG_NOTICE_IS_ON VLOG_IS_ON(3)
#define VLOG_CRITICAL_IS_ON VLOG_IS_ON(1)


/// Define a wrapper around DCHECK for strongly typed enums that print a useful error
/// message on failure.
#define DCHECK_ENUM_EQ(a, b) \
DCHECK(a == b) << "[ " #a " = " << static_cast<int>(a) << " , " #b " = " \
<< static_cast<int>(b) << " ]"

#include <fmt/format.h>
#endif
5 changes: 0 additions & 5 deletions be/src/exec/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ set(EXECUTABLE_OUTPUT_PATH "${BUILD_DIR}/src/exec")

set(EXEC_FILES
aggregation_node.cpp
aggregation_node_ir.cpp
analytic_eval_node.cpp
blocking_join_node.cpp
broker_scan_node.cpp
Expand All @@ -40,7 +39,6 @@ set(EXEC_FILES
exec_node.cpp
exchange_node.cpp
hash_join_node.cpp
hash_join_node_ir.cpp
hash_table.cpp
local_file_reader.cpp
merge_node.cpp
Expand Down Expand Up @@ -70,7 +68,6 @@ set(EXEC_FILES
es/es_query_builder.cpp
spill_sort_node.cc
union_node.cpp
union_node_ir.cpp
set_operation_node.cpp
intersect_node.cpp
except_node.cpp
Expand All @@ -94,9 +91,7 @@ set(EXEC_FILES
schema_scanner/schema_partitions_scanner.cpp

partitioned_hash_table.cc
partitioned_hash_table_ir.cc
partitioned_aggregation_node.cc
partitioned_aggregation_node_ir.cc
odbc_scan_node.cpp
local_file_writer.cpp
broker_writer.cpp
Expand Down
36 changes: 23 additions & 13 deletions be/src/exec/aggregation_node.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -389,19 +389,6 @@ void AggregationNode::update_tuple(Tuple* tuple, TupleRow* row) {
DCHECK(tuple != nullptr);

AggFnEvaluator::add(_aggregate_evaluators, _agg_fn_ctxs, row, tuple);
#if 0
std::vector<AggFnEvaluator*>::const_iterator evaluator;
int i = 0;
for (evaluator = _aggregate_evaluators.begin();
evaluator != _aggregate_evaluators.end(); ++evaluator, ++i) {
(*evaluator)->choose_update_or_merge(_agg_fn_ctxs[i], row, tuple);
//if (_is_merge) {
// (*evaluator)->merge(_agg_fn_ctxs[i], row, tuple, pool);
//} else {
// (*evaluator)->update(_agg_fn_ctxs[i], row, tuple, pool);
//}
}
#endif
}

Tuple* AggregationNode::finalize_tuple(Tuple* tuple, MemPool* pool) {
Expand Down Expand Up @@ -451,4 +438,27 @@ void AggregationNode::push_down_predicate(RuntimeState* state, std::list<ExprCon
return;
}

void AggregationNode::process_row_batch_no_grouping(RowBatch* batch, MemPool* pool) {
for (int i = 0; i < batch->num_rows(); ++i) {
update_tuple(_singleton_output_tuple, batch->get_row(i));
}
}

void AggregationNode::process_row_batch_with_grouping(RowBatch* batch, MemPool* pool) {
for (int i = 0; i < batch->num_rows(); ++i) {
TupleRow* row = batch->get_row(i);
Tuple* agg_tuple = nullptr;
HashTable::Iterator it = _hash_tbl->find(row);

if (it.at_end()) {
agg_tuple = construct_intermediate_tuple();
_hash_tbl->insert(reinterpret_cast<TupleRow*>(&agg_tuple));
} else {
agg_tuple = it.get_row()->get_tuple(0);
}

update_tuple(agg_tuple, row);
}
}

} // namespace doris
50 changes: 0 additions & 50 deletions be/src/exec/aggregation_node_ir.cpp

This file was deleted.

Loading