MCPcopy Create free account
hub / github.com/apache/arrow / PS_COMMENT

Method PS_COMMENT

cpp/src/arrow/acero/tpch_node.cc:1253–1267  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1251 }
1252
1253 Status PS_COMMENT(size_t thread_index) {
1254 ThreadLocalData& tld = thread_local_data_[thread_index];
1255 if (!tld.generated_partsupp[PARTSUPP::PS_COMMENT]) {
1256 tld.generated_partsupp[PARTSUPP::PS_COMMENT] = true;
1257 int64_t irow = 0;
1258 int64_t ps_to_generate = kPartSuppRowsPerPart * tld.part_to_generate;
1259 for (size_t ibatch = 0; ibatch < tld.partsupp.size(); ibatch++) {
1260 int64_t num_rows = std::min(batch_size_, ps_to_generate - irow);
1261 ARROW_ASSIGN_OR_RAISE(tld.partsupp[ibatch][PARTSUPP::PS_COMMENT],
1262 g_text.GenerateComments(num_rows, 49, 198, tld.rng));
1263 irow += num_rows;
1264 }
1265 }
1266 return Status::OK();
1267 }
1268
1269 struct ThreadLocalData {
1270 std::vector<Datum> part;

Callers

nothing calls this directly

Calls 4

GenerateCommentsMethod · 0.80
ARROW_ASSIGN_OR_RAISEFunction · 0.70
OKFunction · 0.50
sizeMethod · 0.45

Tested by

no test coverage detected