mirror of
https://github.com/zama-ai/concrete.git
synced 2026-02-08 11:35:02 -05:00
fix(compiler): increase the maximum number of DFR task inputs to 50. Split generated switches in separate files.
This commit is contained in:
@@ -260,417 +260,9 @@ struct GenericComputeServer : component_base<GenericComputeServer> {
|
||||
std::vector<void *> outputs;
|
||||
|
||||
switch (inputs.output_sizes.size()) {
|
||||
case 1: {
|
||||
void *output;
|
||||
_dfr_checked_aligned_alloc(&output, 512, inputs.output_sizes[0]);
|
||||
switch (inputs.params.size()) {
|
||||
case 0:
|
||||
wfn(output);
|
||||
break;
|
||||
case 1:
|
||||
wfn(output, inputs.params[0]);
|
||||
break;
|
||||
case 2:
|
||||
wfn(output, inputs.params[0], inputs.params[1]);
|
||||
break;
|
||||
case 3:
|
||||
wfn(output, inputs.params[0], inputs.params[1], inputs.params[2]);
|
||||
break;
|
||||
case 4:
|
||||
wfn(output, inputs.params[0], inputs.params[1], inputs.params[2],
|
||||
inputs.params[3]);
|
||||
break;
|
||||
case 5:
|
||||
wfn(output, inputs.params[0], inputs.params[1], inputs.params[2],
|
||||
inputs.params[3], inputs.params[4]);
|
||||
break;
|
||||
case 6:
|
||||
wfn(output, inputs.params[0], inputs.params[1], inputs.params[2],
|
||||
inputs.params[3], inputs.params[4], inputs.params[5]);
|
||||
break;
|
||||
case 7:
|
||||
wfn(output, inputs.params[0], inputs.params[1], inputs.params[2],
|
||||
inputs.params[3], inputs.params[4], inputs.params[5],
|
||||
inputs.params[6]);
|
||||
break;
|
||||
case 8:
|
||||
wfn(output, inputs.params[0], inputs.params[1], inputs.params[2],
|
||||
inputs.params[3], inputs.params[4], inputs.params[5],
|
||||
inputs.params[6], inputs.params[7]);
|
||||
break;
|
||||
case 9:
|
||||
wfn(output, inputs.params[0], inputs.params[1], inputs.params[2],
|
||||
inputs.params[3], inputs.params[4], inputs.params[5],
|
||||
inputs.params[6], inputs.params[7], inputs.params[8]);
|
||||
break;
|
||||
case 10:
|
||||
wfn(output, inputs.params[0], inputs.params[1], inputs.params[2],
|
||||
inputs.params[3], inputs.params[4], inputs.params[5],
|
||||
inputs.params[6], inputs.params[7], inputs.params[8],
|
||||
inputs.params[9]);
|
||||
break;
|
||||
case 11:
|
||||
wfn(output, inputs.params[0], inputs.params[1], inputs.params[2],
|
||||
inputs.params[3], inputs.params[4], inputs.params[5],
|
||||
inputs.params[6], inputs.params[7], inputs.params[8],
|
||||
inputs.params[9], inputs.params[10]);
|
||||
break;
|
||||
case 12:
|
||||
wfn(output, inputs.params[0], inputs.params[1], inputs.params[2],
|
||||
inputs.params[3], inputs.params[4], inputs.params[5],
|
||||
inputs.params[6], inputs.params[7], inputs.params[8],
|
||||
inputs.params[9], inputs.params[10], inputs.params[11]);
|
||||
break;
|
||||
case 13:
|
||||
wfn(output, inputs.params[0], inputs.params[1], inputs.params[2],
|
||||
inputs.params[3], inputs.params[4], inputs.params[5],
|
||||
inputs.params[6], inputs.params[7], inputs.params[8],
|
||||
inputs.params[9], inputs.params[10], inputs.params[11],
|
||||
inputs.params[12]);
|
||||
break;
|
||||
case 14:
|
||||
wfn(output, inputs.params[0], inputs.params[1], inputs.params[2],
|
||||
inputs.params[3], inputs.params[4], inputs.params[5],
|
||||
inputs.params[6], inputs.params[7], inputs.params[8],
|
||||
inputs.params[9], inputs.params[10], inputs.params[11],
|
||||
inputs.params[12], inputs.params[13]);
|
||||
break;
|
||||
case 15:
|
||||
wfn(output, inputs.params[0], inputs.params[1], inputs.params[2],
|
||||
inputs.params[3], inputs.params[4], inputs.params[5],
|
||||
inputs.params[6], inputs.params[7], inputs.params[8],
|
||||
inputs.params[9], inputs.params[10], inputs.params[11],
|
||||
inputs.params[12], inputs.params[13], inputs.params[14]);
|
||||
break;
|
||||
case 16:
|
||||
wfn(output, inputs.params[0], inputs.params[1], inputs.params[2],
|
||||
inputs.params[3], inputs.params[4], inputs.params[5],
|
||||
inputs.params[6], inputs.params[7], inputs.params[8],
|
||||
inputs.params[9], inputs.params[10], inputs.params[11],
|
||||
inputs.params[12], inputs.params[13], inputs.params[14],
|
||||
inputs.params[15]);
|
||||
break;
|
||||
case 17:
|
||||
wfn(output, inputs.params[0], inputs.params[1], inputs.params[2],
|
||||
inputs.params[3], inputs.params[4], inputs.params[5],
|
||||
inputs.params[6], inputs.params[7], inputs.params[8],
|
||||
inputs.params[9], inputs.params[10], inputs.params[11],
|
||||
inputs.params[12], inputs.params[13], inputs.params[14],
|
||||
inputs.params[15], inputs.params[16]);
|
||||
break;
|
||||
case 18:
|
||||
wfn(output, inputs.params[0], inputs.params[1], inputs.params[2],
|
||||
inputs.params[3], inputs.params[4], inputs.params[5],
|
||||
inputs.params[6], inputs.params[7], inputs.params[8],
|
||||
inputs.params[9], inputs.params[10], inputs.params[11],
|
||||
inputs.params[12], inputs.params[13], inputs.params[14],
|
||||
inputs.params[15], inputs.params[16], inputs.params[17]);
|
||||
break;
|
||||
case 19:
|
||||
wfn(output, inputs.params[0], inputs.params[1], inputs.params[2],
|
||||
inputs.params[3], inputs.params[4], inputs.params[5],
|
||||
inputs.params[6], inputs.params[7], inputs.params[8],
|
||||
inputs.params[9], inputs.params[10], inputs.params[11],
|
||||
inputs.params[12], inputs.params[13], inputs.params[14],
|
||||
inputs.params[15], inputs.params[16], inputs.params[17],
|
||||
inputs.params[18]);
|
||||
break;
|
||||
case 20:
|
||||
wfn(output, inputs.params[0], inputs.params[1], inputs.params[2],
|
||||
inputs.params[3], inputs.params[4], inputs.params[5],
|
||||
inputs.params[6], inputs.params[7], inputs.params[8],
|
||||
inputs.params[9], inputs.params[10], inputs.params[11],
|
||||
inputs.params[12], inputs.params[13], inputs.params[14],
|
||||
inputs.params[15], inputs.params[16], inputs.params[17],
|
||||
inputs.params[18], inputs.params[19]);
|
||||
break;
|
||||
default:
|
||||
HPX_THROW_EXCEPTION(hpx::no_success,
|
||||
"GenericComputeServer::execute_task",
|
||||
"Error: number of task parameters not supported.");
|
||||
}
|
||||
outputs = {output};
|
||||
break;
|
||||
}
|
||||
case 2: {
|
||||
void *output1, *output2;
|
||||
_dfr_checked_aligned_alloc(&output1, 512, inputs.output_sizes[0]);
|
||||
_dfr_checked_aligned_alloc(&output2, 512, inputs.output_sizes[1]);
|
||||
switch (inputs.params.size()) {
|
||||
case 0:
|
||||
wfn(output1, output2);
|
||||
break;
|
||||
case 1:
|
||||
wfn(output1, output2, inputs.params[0]);
|
||||
break;
|
||||
case 2:
|
||||
wfn(output1, output2, inputs.params[0], inputs.params[1]);
|
||||
break;
|
||||
case 3:
|
||||
wfn(output1, output2, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], output1, output2);
|
||||
break;
|
||||
case 4:
|
||||
wfn(output1, output2, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3]);
|
||||
break;
|
||||
case 5:
|
||||
wfn(output1, output2, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4]);
|
||||
break;
|
||||
case 6:
|
||||
wfn(output1, output2, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], output1, output2);
|
||||
break;
|
||||
case 7:
|
||||
wfn(output1, output2, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6]);
|
||||
break;
|
||||
case 8:
|
||||
wfn(output1, output2, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7]);
|
||||
break;
|
||||
case 9:
|
||||
wfn(output1, output2, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], output1, output2);
|
||||
break;
|
||||
case 10:
|
||||
wfn(output1, output2, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9]);
|
||||
break;
|
||||
case 11:
|
||||
wfn(output1, output2, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10]);
|
||||
break;
|
||||
case 12:
|
||||
wfn(output1, output2, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10],
|
||||
inputs.params[11], output1, output2);
|
||||
break;
|
||||
case 13:
|
||||
wfn(output1, output2, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10],
|
||||
inputs.params[11], inputs.params[12]);
|
||||
break;
|
||||
case 14:
|
||||
wfn(output1, output2, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10],
|
||||
inputs.params[11], inputs.params[12], inputs.params[13]);
|
||||
break;
|
||||
case 15:
|
||||
wfn(output1, output2, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10],
|
||||
inputs.params[11], inputs.params[12], inputs.params[13],
|
||||
inputs.params[14], output1, output2);
|
||||
break;
|
||||
case 16:
|
||||
wfn(output1, output2, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10],
|
||||
inputs.params[11], inputs.params[12], inputs.params[13],
|
||||
inputs.params[14], inputs.params[15]);
|
||||
break;
|
||||
case 17:
|
||||
wfn(output1, output2, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10],
|
||||
inputs.params[11], inputs.params[12], inputs.params[13],
|
||||
inputs.params[14], inputs.params[15], inputs.params[16]);
|
||||
break;
|
||||
case 18:
|
||||
wfn(output1, output2, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10],
|
||||
inputs.params[11], inputs.params[12], inputs.params[13],
|
||||
inputs.params[14], inputs.params[15], inputs.params[16],
|
||||
inputs.params[17], output1, output2);
|
||||
break;
|
||||
case 19:
|
||||
wfn(output1, output2, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10],
|
||||
inputs.params[11], inputs.params[12], inputs.params[13],
|
||||
inputs.params[14], inputs.params[15], inputs.params[16],
|
||||
inputs.params[17], inputs.params[18]);
|
||||
break;
|
||||
case 20:
|
||||
wfn(output1, output2, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10],
|
||||
inputs.params[11], inputs.params[12], inputs.params[13],
|
||||
inputs.params[14], inputs.params[15], inputs.params[16],
|
||||
inputs.params[17], inputs.params[18], inputs.params[19]);
|
||||
break;
|
||||
default:
|
||||
HPX_THROW_EXCEPTION(hpx::no_success,
|
||||
"GenericComputeServer::execute_task",
|
||||
"Error: number of task parameters not supported.");
|
||||
}
|
||||
outputs = {output1, output2};
|
||||
break;
|
||||
}
|
||||
case 3: {
|
||||
void *output1, *output2, *output3;
|
||||
_dfr_checked_aligned_alloc(&output1, 512, inputs.output_sizes[0]);
|
||||
_dfr_checked_aligned_alloc(&output2, 512, inputs.output_sizes[1]);
|
||||
_dfr_checked_aligned_alloc(&output2, 512, inputs.output_sizes[2]);
|
||||
switch (inputs.params.size()) {
|
||||
case 0:
|
||||
wfn(output1, output2, output3);
|
||||
break;
|
||||
case 1:
|
||||
wfn(output1, output2, output3, inputs.params[0]);
|
||||
break;
|
||||
case 2:
|
||||
wfn(output1, output2, output3, inputs.params[0], inputs.params[1]);
|
||||
break;
|
||||
case 3:
|
||||
wfn(output1, output2, output3, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], output1, output2, output3);
|
||||
break;
|
||||
case 4:
|
||||
wfn(output1, output2, output3, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3]);
|
||||
break;
|
||||
case 5:
|
||||
wfn(output1, output2, output3, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4]);
|
||||
break;
|
||||
case 6:
|
||||
wfn(output1, output2, output3, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], output1, output2, output3);
|
||||
break;
|
||||
case 7:
|
||||
wfn(output1, output2, output3, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6]);
|
||||
break;
|
||||
case 8:
|
||||
wfn(output1, output2, output3, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7]);
|
||||
break;
|
||||
case 9:
|
||||
wfn(output1, output2, output3, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], output1, output2, output3);
|
||||
break;
|
||||
case 10:
|
||||
wfn(output1, output2, output3, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9]);
|
||||
break;
|
||||
case 11:
|
||||
wfn(output1, output2, output3, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10]);
|
||||
break;
|
||||
case 12:
|
||||
wfn(output1, output2, output3, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10],
|
||||
inputs.params[11], output1, output2, output3);
|
||||
break;
|
||||
case 13:
|
||||
wfn(output1, output2, output3, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10],
|
||||
inputs.params[11], inputs.params[12]);
|
||||
break;
|
||||
case 14:
|
||||
wfn(output1, output2, output3, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10],
|
||||
inputs.params[11], inputs.params[12], inputs.params[13]);
|
||||
break;
|
||||
case 15:
|
||||
wfn(output1, output2, output3, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10],
|
||||
inputs.params[11], inputs.params[12], inputs.params[13],
|
||||
inputs.params[14], output1, output2, output3);
|
||||
break;
|
||||
case 16:
|
||||
wfn(output1, output2, output3, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10],
|
||||
inputs.params[11], inputs.params[12], inputs.params[13],
|
||||
inputs.params[14], inputs.params[15]);
|
||||
break;
|
||||
case 17:
|
||||
wfn(output1, output2, output3, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10],
|
||||
inputs.params[11], inputs.params[12], inputs.params[13],
|
||||
inputs.params[14], inputs.params[15], inputs.params[16]);
|
||||
break;
|
||||
case 18:
|
||||
wfn(output1, output2, output3, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10],
|
||||
inputs.params[11], inputs.params[12], inputs.params[13],
|
||||
inputs.params[14], inputs.params[15], inputs.params[16],
|
||||
inputs.params[17], output1, output2, output3);
|
||||
break;
|
||||
case 19:
|
||||
wfn(output1, output2, output3, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10],
|
||||
inputs.params[11], inputs.params[12], inputs.params[13],
|
||||
inputs.params[14], inputs.params[15], inputs.params[16],
|
||||
inputs.params[17], inputs.params[18]);
|
||||
break;
|
||||
case 20:
|
||||
wfn(output1, output2, output3, inputs.params[0], inputs.params[1],
|
||||
inputs.params[2], inputs.params[3], inputs.params[4],
|
||||
inputs.params[5], inputs.params[6], inputs.params[7],
|
||||
inputs.params[8], inputs.params[9], inputs.params[10],
|
||||
inputs.params[11], inputs.params[12], inputs.params[13],
|
||||
inputs.params[14], inputs.params[15], inputs.params[16],
|
||||
inputs.params[17], inputs.params[18], inputs.params[19]);
|
||||
break;
|
||||
default:
|
||||
HPX_THROW_EXCEPTION(hpx::no_success,
|
||||
"GenericComputeServer::execute_task",
|
||||
"Error: number of task parameters not supported.");
|
||||
}
|
||||
outputs = {output1, output2, output3};
|
||||
break;
|
||||
}
|
||||
|
||||
#include "concretelang/Runtime/generated/dfr_task_work_function_calls.h"
|
||||
|
||||
default:
|
||||
HPX_THROW_EXCEPTION(hpx::no_success, "GenericComputeServer::execute_task",
|
||||
"Error: number of task outputs not supported.");
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,32 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Param ranges $1 - $2 for the number of inputs (e.g., 0 50)
|
||||
|
||||
p1=""
|
||||
p2=""
|
||||
p3=""
|
||||
for i in $(eval echo {$1..$2}); do
|
||||
if ((i == 1)); then
|
||||
p1="$p1 hpx::shared_future<void *> param$(($i-1))"
|
||||
p2="$p2 param$(($i-1)).get()"
|
||||
p3="$p3, *((dfr_refcounted_future_p)refcounted_futures[$(($i-1))])->future"
|
||||
fi
|
||||
if ((i > 1)); then
|
||||
p1="$p1, hpx::shared_future<void *> param$(($i-1))"
|
||||
p2="$p2, param$(($i-1)).get()"
|
||||
p3="$p3, *((dfr_refcounted_future_p)refcounted_futures[$(($i-1))])->future"
|
||||
fi
|
||||
echo "case $i:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx]($p1)"
|
||||
echo "-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {$p2};"
|
||||
echo " mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
} $p3));
|
||||
break;
|
||||
"
|
||||
done;
|
||||
@@ -0,0 +1,34 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Param ranges $1 - $2 for the number of outputs (e.g., 1 3)
|
||||
# $3 - $4 for inputs (e.g., 0 50)
|
||||
|
||||
for i in $(eval echo {$1..$2}); do
|
||||
outs=""
|
||||
echo "case $i: {"
|
||||
for j in $(eval echo {1..$i}); do
|
||||
echo " void *output$j;
|
||||
_dfr_checked_aligned_alloc(&output$j, 512, inputs.output_sizes[$(($j-1))]);"
|
||||
if ((j == 1)); then
|
||||
outs="$outs output$j"
|
||||
else
|
||||
outs="$outs, output$j"
|
||||
fi
|
||||
done;
|
||||
echo " switch (inputs.params.size()) {"
|
||||
|
||||
ins=""
|
||||
for j in $(eval echo {$3..$4}); do
|
||||
if ((j > 0)); then
|
||||
ins="$ins, inputs.params[$(($j - 1))]"
|
||||
fi
|
||||
echo "case $j:
|
||||
wfn($outs$ins); break;"
|
||||
done
|
||||
echo " default:
|
||||
HPX_THROW_EXCEPTION(hpx::no_success,
|
||||
\"GenericComputeServer::execute_task\",
|
||||
\"Error: number of task parameters not supported.\");
|
||||
}"
|
||||
echo "outputs = {$outs}; break;}"
|
||||
done;
|
||||
@@ -139,736 +139,8 @@ void _dfr_create_async_task(wfnptr wfn, void *ctx, size_t num_params,
|
||||
mlir::concretelang::dfr::GenericComputeClient *gcc_target =
|
||||
&mlir::concretelang::dfr::gcc[_dfr_find_next_execution_locality()];
|
||||
switch (num_params) {
|
||||
case 0:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target,
|
||||
ctx]() -> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
}));
|
||||
break;
|
||||
|
||||
case 1:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {param0.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future));
|
||||
break;
|
||||
|
||||
case 2:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0,
|
||||
hpx::shared_future<void *> param1)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {param0.get(), param1.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[1])->future));
|
||||
break;
|
||||
|
||||
case 3:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0,
|
||||
hpx::shared_future<void *> param1,
|
||||
hpx::shared_future<void *> param2)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {param0.get(), param1.get(),
|
||||
param2.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[1])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[2])->future));
|
||||
break;
|
||||
|
||||
case 4:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0,
|
||||
hpx::shared_future<void *> param1,
|
||||
hpx::shared_future<void *> param2,
|
||||
hpx::shared_future<void *> param3)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {param0.get(), param1.get(),
|
||||
param2.get(), param3.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[1])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[2])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[3])->future));
|
||||
break;
|
||||
|
||||
case 5:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0,
|
||||
hpx::shared_future<void *> param1,
|
||||
hpx::shared_future<void *> param2,
|
||||
hpx::shared_future<void *> param3,
|
||||
hpx::shared_future<void *> param4)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {param0.get(), param1.get(),
|
||||
param2.get(), param3.get(),
|
||||
param4.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[1])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[2])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[3])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[4])->future));
|
||||
break;
|
||||
|
||||
case 6:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0,
|
||||
hpx::shared_future<void *> param1,
|
||||
hpx::shared_future<void *> param2,
|
||||
hpx::shared_future<void *> param3,
|
||||
hpx::shared_future<void *> param4,
|
||||
hpx::shared_future<void *> param5)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {param0.get(), param1.get(),
|
||||
param2.get(), param3.get(),
|
||||
param4.get(), param5.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[1])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[2])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[3])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[4])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[5])->future));
|
||||
break;
|
||||
|
||||
case 7:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0,
|
||||
hpx::shared_future<void *> param1,
|
||||
hpx::shared_future<void *> param2,
|
||||
hpx::shared_future<void *> param3,
|
||||
hpx::shared_future<void *> param4,
|
||||
hpx::shared_future<void *> param5,
|
||||
hpx::shared_future<void *> param6)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {
|
||||
param0.get(), param1.get(), param2.get(), param3.get(),
|
||||
param4.get(), param5.get(), param6.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[1])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[2])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[3])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[4])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[5])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[6])->future));
|
||||
break;
|
||||
|
||||
case 8:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0,
|
||||
hpx::shared_future<void *> param1,
|
||||
hpx::shared_future<void *> param2,
|
||||
hpx::shared_future<void *> param3,
|
||||
hpx::shared_future<void *> param4,
|
||||
hpx::shared_future<void *> param5,
|
||||
hpx::shared_future<void *> param6,
|
||||
hpx::shared_future<void *> param7)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {
|
||||
param0.get(), param1.get(), param2.get(), param3.get(),
|
||||
param4.get(), param5.get(), param6.get(), param7.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[1])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[2])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[3])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[4])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[5])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[6])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[7])->future));
|
||||
break;
|
||||
|
||||
case 9:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0,
|
||||
hpx::shared_future<void *> param1,
|
||||
hpx::shared_future<void *> param2,
|
||||
hpx::shared_future<void *> param3,
|
||||
hpx::shared_future<void *> param4,
|
||||
hpx::shared_future<void *> param5,
|
||||
hpx::shared_future<void *> param6,
|
||||
hpx::shared_future<void *> param7,
|
||||
hpx::shared_future<void *> param8)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {
|
||||
param0.get(), param1.get(), param2.get(),
|
||||
param3.get(), param4.get(), param5.get(),
|
||||
param6.get(), param7.get(), param8.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[1])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[2])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[3])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[4])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[5])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[6])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[7])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[8])->future));
|
||||
break;
|
||||
|
||||
case 10:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0,
|
||||
hpx::shared_future<void *> param1,
|
||||
hpx::shared_future<void *> param2,
|
||||
hpx::shared_future<void *> param3,
|
||||
hpx::shared_future<void *> param4,
|
||||
hpx::shared_future<void *> param5,
|
||||
hpx::shared_future<void *> param6,
|
||||
hpx::shared_future<void *> param7,
|
||||
hpx::shared_future<void *> param8,
|
||||
hpx::shared_future<void *> param9)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {
|
||||
param0.get(), param1.get(), param2.get(), param3.get(),
|
||||
param4.get(), param5.get(), param6.get(), param7.get(),
|
||||
param8.get(), param9.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[1])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[2])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[3])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[4])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[5])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[6])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[7])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[8])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[9])->future));
|
||||
break;
|
||||
|
||||
case 11:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0,
|
||||
hpx::shared_future<void *> param1,
|
||||
hpx::shared_future<void *> param2,
|
||||
hpx::shared_future<void *> param3,
|
||||
hpx::shared_future<void *> param4,
|
||||
hpx::shared_future<void *> param5,
|
||||
hpx::shared_future<void *> param6,
|
||||
hpx::shared_future<void *> param7,
|
||||
hpx::shared_future<void *> param8,
|
||||
hpx::shared_future<void *> param9,
|
||||
hpx::shared_future<void *> param10)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {
|
||||
param0.get(), param1.get(), param2.get(), param3.get(),
|
||||
param4.get(), param5.get(), param6.get(), param7.get(),
|
||||
param8.get(), param9.get(), param10.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[1])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[2])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[3])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[4])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[5])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[6])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[7])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[8])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[9])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[10])->future));
|
||||
break;
|
||||
|
||||
case 12:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0,
|
||||
hpx::shared_future<void *> param1,
|
||||
hpx::shared_future<void *> param2,
|
||||
hpx::shared_future<void *> param3,
|
||||
hpx::shared_future<void *> param4,
|
||||
hpx::shared_future<void *> param5,
|
||||
hpx::shared_future<void *> param6,
|
||||
hpx::shared_future<void *> param7,
|
||||
hpx::shared_future<void *> param8,
|
||||
hpx::shared_future<void *> param9,
|
||||
hpx::shared_future<void *> param10,
|
||||
hpx::shared_future<void *> param11)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {
|
||||
param0.get(), param1.get(), param2.get(), param3.get(),
|
||||
param4.get(), param5.get(), param6.get(), param7.get(),
|
||||
param8.get(), param9.get(), param10.get(), param11.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[1])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[2])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[3])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[4])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[5])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[6])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[7])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[8])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[9])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[10])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[11])->future));
|
||||
break;
|
||||
|
||||
case 13:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0,
|
||||
hpx::shared_future<void *> param1,
|
||||
hpx::shared_future<void *> param2,
|
||||
hpx::shared_future<void *> param3,
|
||||
hpx::shared_future<void *> param4,
|
||||
hpx::shared_future<void *> param5,
|
||||
hpx::shared_future<void *> param6,
|
||||
hpx::shared_future<void *> param7,
|
||||
hpx::shared_future<void *> param8,
|
||||
hpx::shared_future<void *> param9,
|
||||
hpx::shared_future<void *> param10,
|
||||
hpx::shared_future<void *> param11,
|
||||
hpx::shared_future<void *> param12)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {
|
||||
param0.get(), param1.get(), param2.get(), param3.get(),
|
||||
param4.get(), param5.get(), param6.get(), param7.get(),
|
||||
param8.get(), param9.get(), param10.get(), param11.get(),
|
||||
param12.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[1])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[2])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[3])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[4])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[5])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[6])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[7])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[8])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[9])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[10])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[11])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[12])->future));
|
||||
break;
|
||||
|
||||
case 14:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0,
|
||||
hpx::shared_future<void *> param1,
|
||||
hpx::shared_future<void *> param2,
|
||||
hpx::shared_future<void *> param3,
|
||||
hpx::shared_future<void *> param4,
|
||||
hpx::shared_future<void *> param5,
|
||||
hpx::shared_future<void *> param6,
|
||||
hpx::shared_future<void *> param7,
|
||||
hpx::shared_future<void *> param8,
|
||||
hpx::shared_future<void *> param9,
|
||||
hpx::shared_future<void *> param10,
|
||||
hpx::shared_future<void *> param11,
|
||||
hpx::shared_future<void *> param12,
|
||||
hpx::shared_future<void *> param13)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {
|
||||
param0.get(), param1.get(), param2.get(), param3.get(),
|
||||
param4.get(), param5.get(), param6.get(), param7.get(),
|
||||
param8.get(), param9.get(), param10.get(), param11.get(),
|
||||
param12.get(), param13.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[1])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[2])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[3])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[4])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[5])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[6])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[7])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[8])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[9])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[10])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[11])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[12])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[13])->future));
|
||||
break;
|
||||
|
||||
case 15:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0,
|
||||
hpx::shared_future<void *> param1,
|
||||
hpx::shared_future<void *> param2,
|
||||
hpx::shared_future<void *> param3,
|
||||
hpx::shared_future<void *> param4,
|
||||
hpx::shared_future<void *> param5,
|
||||
hpx::shared_future<void *> param6,
|
||||
hpx::shared_future<void *> param7,
|
||||
hpx::shared_future<void *> param8,
|
||||
hpx::shared_future<void *> param9,
|
||||
hpx::shared_future<void *> param10,
|
||||
hpx::shared_future<void *> param11,
|
||||
hpx::shared_future<void *> param12,
|
||||
hpx::shared_future<void *> param13,
|
||||
hpx::shared_future<void *> param14)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {
|
||||
param0.get(), param1.get(), param2.get(), param3.get(),
|
||||
param4.get(), param5.get(), param6.get(), param7.get(),
|
||||
param8.get(), param9.get(), param10.get(), param11.get(),
|
||||
param12.get(), param13.get(), param14.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[1])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[2])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[3])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[4])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[5])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[6])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[7])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[8])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[9])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[10])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[11])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[12])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[13])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[14])->future));
|
||||
break;
|
||||
|
||||
case 16:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0,
|
||||
hpx::shared_future<void *> param1,
|
||||
hpx::shared_future<void *> param2,
|
||||
hpx::shared_future<void *> param3,
|
||||
hpx::shared_future<void *> param4,
|
||||
hpx::shared_future<void *> param5,
|
||||
hpx::shared_future<void *> param6,
|
||||
hpx::shared_future<void *> param7,
|
||||
hpx::shared_future<void *> param8,
|
||||
hpx::shared_future<void *> param9,
|
||||
hpx::shared_future<void *> param10,
|
||||
hpx::shared_future<void *> param11,
|
||||
hpx::shared_future<void *> param12,
|
||||
hpx::shared_future<void *> param13,
|
||||
hpx::shared_future<void *> param14,
|
||||
hpx::shared_future<void *> param15)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {
|
||||
param0.get(), param1.get(), param2.get(), param3.get(),
|
||||
param4.get(), param5.get(), param6.get(), param7.get(),
|
||||
param8.get(), param9.get(), param10.get(), param11.get(),
|
||||
param12.get(), param13.get(), param14.get(), param15.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[1])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[2])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[3])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[4])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[5])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[6])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[7])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[8])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[9])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[10])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[11])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[12])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[13])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[14])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[15])->future));
|
||||
break;
|
||||
|
||||
case 17:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0,
|
||||
hpx::shared_future<void *> param1,
|
||||
hpx::shared_future<void *> param2,
|
||||
hpx::shared_future<void *> param3,
|
||||
hpx::shared_future<void *> param4,
|
||||
hpx::shared_future<void *> param5,
|
||||
hpx::shared_future<void *> param6,
|
||||
hpx::shared_future<void *> param7,
|
||||
hpx::shared_future<void *> param8,
|
||||
hpx::shared_future<void *> param9,
|
||||
hpx::shared_future<void *> param10,
|
||||
hpx::shared_future<void *> param11,
|
||||
hpx::shared_future<void *> param12,
|
||||
hpx::shared_future<void *> param13,
|
||||
hpx::shared_future<void *> param14,
|
||||
hpx::shared_future<void *> param15,
|
||||
hpx::shared_future<void *> param16)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {
|
||||
param0.get(), param1.get(), param2.get(), param3.get(),
|
||||
param4.get(), param5.get(), param6.get(), param7.get(),
|
||||
param8.get(), param9.get(), param10.get(), param11.get(),
|
||||
param12.get(), param13.get(), param14.get(), param15.get(),
|
||||
param16.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[1])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[2])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[3])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[4])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[5])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[6])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[7])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[8])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[9])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[10])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[11])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[12])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[13])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[14])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[15])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[16])->future));
|
||||
break;
|
||||
|
||||
case 18:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0,
|
||||
hpx::shared_future<void *> param1,
|
||||
hpx::shared_future<void *> param2,
|
||||
hpx::shared_future<void *> param3,
|
||||
hpx::shared_future<void *> param4,
|
||||
hpx::shared_future<void *> param5,
|
||||
hpx::shared_future<void *> param6,
|
||||
hpx::shared_future<void *> param7,
|
||||
hpx::shared_future<void *> param8,
|
||||
hpx::shared_future<void *> param9,
|
||||
hpx::shared_future<void *> param10,
|
||||
hpx::shared_future<void *> param11,
|
||||
hpx::shared_future<void *> param12,
|
||||
hpx::shared_future<void *> param13,
|
||||
hpx::shared_future<void *> param14,
|
||||
hpx::shared_future<void *> param15,
|
||||
hpx::shared_future<void *> param16,
|
||||
hpx::shared_future<void *> param17)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {
|
||||
param0.get(), param1.get(), param2.get(), param3.get(),
|
||||
param4.get(), param5.get(), param6.get(), param7.get(),
|
||||
param8.get(), param9.get(), param10.get(), param11.get(),
|
||||
param12.get(), param13.get(), param14.get(), param15.get(),
|
||||
param16.get(), param17.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[1])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[2])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[3])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[4])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[5])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[6])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[7])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[8])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[9])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[10])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[11])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[12])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[13])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[14])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[15])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[16])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[17])->future));
|
||||
break;
|
||||
|
||||
case 19:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0,
|
||||
hpx::shared_future<void *> param1,
|
||||
hpx::shared_future<void *> param2,
|
||||
hpx::shared_future<void *> param3,
|
||||
hpx::shared_future<void *> param4,
|
||||
hpx::shared_future<void *> param5,
|
||||
hpx::shared_future<void *> param6,
|
||||
hpx::shared_future<void *> param7,
|
||||
hpx::shared_future<void *> param8,
|
||||
hpx::shared_future<void *> param9,
|
||||
hpx::shared_future<void *> param10,
|
||||
hpx::shared_future<void *> param11,
|
||||
hpx::shared_future<void *> param12,
|
||||
hpx::shared_future<void *> param13,
|
||||
hpx::shared_future<void *> param14,
|
||||
hpx::shared_future<void *> param15,
|
||||
hpx::shared_future<void *> param16,
|
||||
hpx::shared_future<void *> param17,
|
||||
hpx::shared_future<void *> param18)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {
|
||||
param0.get(), param1.get(), param2.get(), param3.get(),
|
||||
param4.get(), param5.get(), param6.get(), param7.get(),
|
||||
param8.get(), param9.get(), param10.get(), param11.get(),
|
||||
param12.get(), param13.get(), param14.get(), param15.get(),
|
||||
param16.get(), param17.get(), param18.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[1])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[2])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[3])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[4])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[5])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[6])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[7])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[8])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[9])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[10])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[11])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[12])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[13])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[14])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[15])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[16])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[17])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[18])->future));
|
||||
break;
|
||||
|
||||
case 20:
|
||||
oodf = std::move(hpx::dataflow(
|
||||
[wfnname, param_sizes, param_types, output_sizes, output_types,
|
||||
gcc_target, ctx](hpx::shared_future<void *> param0,
|
||||
hpx::shared_future<void *> param1,
|
||||
hpx::shared_future<void *> param2,
|
||||
hpx::shared_future<void *> param3,
|
||||
hpx::shared_future<void *> param4,
|
||||
hpx::shared_future<void *> param5,
|
||||
hpx::shared_future<void *> param6,
|
||||
hpx::shared_future<void *> param7,
|
||||
hpx::shared_future<void *> param8,
|
||||
hpx::shared_future<void *> param9,
|
||||
hpx::shared_future<void *> param10,
|
||||
hpx::shared_future<void *> param11,
|
||||
hpx::shared_future<void *> param12,
|
||||
hpx::shared_future<void *> param13,
|
||||
hpx::shared_future<void *> param14,
|
||||
hpx::shared_future<void *> param15,
|
||||
hpx::shared_future<void *> param16,
|
||||
hpx::shared_future<void *> param17,
|
||||
hpx::shared_future<void *> param18,
|
||||
hpx::shared_future<void *> param19)
|
||||
-> hpx::future<mlir::concretelang::dfr::OpaqueOutputData> {
|
||||
std::vector<void *> params = {
|
||||
param0.get(), param1.get(), param2.get(), param3.get(),
|
||||
param4.get(), param5.get(), param6.get(), param7.get(),
|
||||
param8.get(), param9.get(), param10.get(), param11.get(),
|
||||
param12.get(), param13.get(), param14.get(), param15.get(),
|
||||
param16.get(), param17.get(), param18.get(), param19.get()};
|
||||
mlir::concretelang::dfr::OpaqueInputData oid(
|
||||
wfnname, params, param_sizes, param_types, output_sizes,
|
||||
output_types, ctx);
|
||||
return gcc_target->execute_task(oid);
|
||||
},
|
||||
*((dfr_refcounted_future_p)refcounted_futures[0])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[1])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[2])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[3])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[4])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[5])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[6])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[7])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[8])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[9])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[10])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[11])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[12])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[13])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[14])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[15])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[16])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[17])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[18])->future,
|
||||
*((dfr_refcounted_future_p)refcounted_futures[19])->future));
|
||||
break;
|
||||
#include "concretelang/Runtime/generated/dfr_dataflow_inputs_cases.h"
|
||||
|
||||
default:
|
||||
HPX_THROW_EXCEPTION(hpx::no_success, "_dfr_create_async_task",
|
||||
|
||||
Reference in New Issue
Block a user