From 677c55c5813e42ced757a59f35c72129b5d75059 Mon Sep 17 00:00:00 2001 From: Daniel Kales <11509575+dkales@users.noreply.github.com> Date: Fri, 16 Feb 2024 13:03:19 +0100 Subject: [PATCH] fix: remove unneeded includes --- .../components/boolean/logic_ops.hpp | 19 ++++++++++++------- .../components/comparison/argminmax.hpp | 1 - .../comparison/fixed_comparison.hpp | 1 - .../components/fields/basic_arith.hpp | 1 - .../components/fixedpoint/abs.hpp | 1 - .../components/fixedpoint/ceil.hpp | 4 ++-- .../components/fixedpoint/cmp_set.hpp | 1 - .../components/fixedpoint/conversion.hpp | 13 ++++++++----- .../components/fixedpoint/division.hpp | 4 ++-- .../components/fixedpoint/dot_product.hpp | 1 - .../components/fixedpoint/erf.hpp | 4 ++-- .../components/fixedpoint/exp.hpp | 7 ++++--- .../components/fixedpoint/floor.hpp | 4 ++-- .../components/fixedpoint/gather.hpp | 7 ++++--- .../components/fixedpoint/log.hpp | 4 ++-- .../components/fixedpoint/mul_rescale.hpp | 4 ++-- .../components/fixedpoint/neg.hpp | 4 ++-- .../components/fixedpoint/remainder.hpp | 1 - .../components/fixedpoint/sqrt.hpp | 1 - .../components/fixedpoint/trigonometric.hpp | 1 - .../components/handle_component.hpp | 3 ++- .../components/integer/mul_div.hpp | 1 - 22 files changed, 44 insertions(+), 43 deletions(-) diff --git a/mlir-assigner/include/mlir-assigner/components/boolean/logic_ops.hpp b/mlir-assigner/include/mlir-assigner/components/boolean/logic_ops.hpp index 27bdca7..aa40c89 100644 --- a/mlir-assigner/include/mlir-assigner/components/boolean/logic_ops.hpp +++ b/mlir-assigner/include/mlir-assigner/components/boolean/logic_ops.hpp @@ -32,7 +32,6 @@ #include #include -#include // TODO: check if there is a new mechanism for this in nil upstream #include #include @@ -50,7 +49,8 @@ namespace nil { circuit_proxy> &bp, assignment_proxy> &assignment, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::logic_and< crypto3::zk::snark::plonk_constraint_system>; typename component_type::input_type input; @@ -72,7 +72,8 @@ namespace nil { circuit_proxy> &bp, assignment_proxy> &assignment, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::logic_or< crypto3::zk::snark::plonk_constraint_system>; @@ -94,7 +95,8 @@ namespace nil { circuit_proxy> &bp, assignment_proxy> &assignment, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::logic_xor< crypto3::zk::snark::plonk_constraint_system>; typename component_type::input_type input; @@ -115,7 +117,8 @@ namespace nil { circuit_proxy> &bp, assignment_proxy> &assignment, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::bitwise_and< crypto3::zk::snark::plonk_constraint_system, BlueprintFieldType, basic_non_native_policy>; @@ -136,7 +139,8 @@ namespace nil { circuit_proxy> &bp, assignment_proxy> &assignment, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::bitwise_or< crypto3::zk::snark::plonk_constraint_system, BlueprintFieldType, basic_non_native_policy>; @@ -157,7 +161,8 @@ namespace nil { circuit_proxy> &bp, assignment_proxy> &assignment, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::bitwise_xor< crypto3::zk::snark::plonk_constraint_system, BlueprintFieldType, basic_non_native_policy>; diff --git a/mlir-assigner/include/mlir-assigner/components/comparison/argminmax.hpp b/mlir-assigner/include/mlir-assigner/components/comparison/argminmax.hpp index 431973c..d896ef0 100644 --- a/mlir-assigner/include/mlir-assigner/components/comparison/argminmax.hpp +++ b/mlir-assigner/include/mlir-assigner/components/comparison/argminmax.hpp @@ -10,7 +10,6 @@ #include #include -#include // TODO: check if there is a new mechanism for this in nil upstream #include #include diff --git a/mlir-assigner/include/mlir-assigner/components/comparison/fixed_comparison.hpp b/mlir-assigner/include/mlir-assigner/components/comparison/fixed_comparison.hpp index ee6efe0..e667bb9 100644 --- a/mlir-assigner/include/mlir-assigner/components/comparison/fixed_comparison.hpp +++ b/mlir-assigner/include/mlir-assigner/components/comparison/fixed_comparison.hpp @@ -32,7 +32,6 @@ #include #include -#include // TODO: check if there is a new mechanism for this in nil upstream #include diff --git a/mlir-assigner/include/mlir-assigner/components/fields/basic_arith.hpp b/mlir-assigner/include/mlir-assigner/components/fields/basic_arith.hpp index 24609c7..f6369c9 100644 --- a/mlir-assigner/include/mlir-assigner/components/fields/basic_arith.hpp +++ b/mlir-assigner/include/mlir-assigner/components/fields/basic_arith.hpp @@ -5,7 +5,6 @@ #include #include -#include #include #include diff --git a/mlir-assigner/include/mlir-assigner/components/fixedpoint/abs.hpp b/mlir-assigner/include/mlir-assigner/components/fixedpoint/abs.hpp index 2c9146d..294a5c0 100644 --- a/mlir-assigner/include/mlir-assigner/components/fixedpoint/abs.hpp +++ b/mlir-assigner/include/mlir-assigner/components/fixedpoint/abs.hpp @@ -8,7 +8,6 @@ #include #include #include -#include // TODO: check if there is a new mechanism for this in nil upstream #include #include diff --git a/mlir-assigner/include/mlir-assigner/components/fixedpoint/ceil.hpp b/mlir-assigner/include/mlir-assigner/components/fixedpoint/ceil.hpp index 27bda76..442a48e 100644 --- a/mlir-assigner/include/mlir-assigner/components/fixedpoint/ceil.hpp +++ b/mlir-assigner/include/mlir-assigner/components/fixedpoint/ceil.hpp @@ -8,7 +8,6 @@ #include #include #include -#include // TODO: check if there is a new mechanism for this in nil upstream #include #include @@ -25,7 +24,8 @@ namespace nil { circuit_proxy> &bp, assignment_proxy> &assignment, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::fix_ceil< crypto3::zk::snark::plonk_constraint_system, BlueprintFieldType, basic_non_native_policy>; diff --git a/mlir-assigner/include/mlir-assigner/components/fixedpoint/cmp_set.hpp b/mlir-assigner/include/mlir-assigner/components/fixedpoint/cmp_set.hpp index 50d3909..0a8df2d 100644 --- a/mlir-assigner/include/mlir-assigner/components/fixedpoint/cmp_set.hpp +++ b/mlir-assigner/include/mlir-assigner/components/fixedpoint/cmp_set.hpp @@ -8,7 +8,6 @@ #include #include -#include // TODO: check if there is a new mechanism for this in nil upstream #include #include diff --git a/mlir-assigner/include/mlir-assigner/components/fixedpoint/conversion.hpp b/mlir-assigner/include/mlir-assigner/components/fixedpoint/conversion.hpp index 63e0734..e10a821 100644 --- a/mlir-assigner/include/mlir-assigner/components/fixedpoint/conversion.hpp +++ b/mlir-assigner/include/mlir-assigner/components/fixedpoint/conversion.hpp @@ -9,7 +9,6 @@ #include #include -#include // TODO: check if there is a new mechanism for this in nil upstream #include #include @@ -26,7 +25,8 @@ namespace nil { circuit_proxy> &bp, assignment_proxy> &assignment, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::int_to_fix< crypto3::zk::snark::plonk_constraint_system, BlueprintFieldType, basic_non_native_policy>; @@ -51,7 +51,8 @@ namespace nil { &bp, assignment_proxy> &assignment, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::fix_to_int< crypto3::zk::snark::plonk_constraint_system, BlueprintFieldType, basic_non_native_policy>; @@ -84,7 +85,8 @@ namespace nil { circuit_proxy> &bp, assignment_proxy> &assignment, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::fix_to_int< crypto3::zk::snark::plonk_constraint_system, BlueprintFieldType, basic_non_native_policy>; @@ -112,7 +114,8 @@ namespace nil { circuit_proxy> &bp, assignment_proxy> &assignment, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::fix_to_int< crypto3::zk::snark::plonk_constraint_system, BlueprintFieldType, basic_non_native_policy>; diff --git a/mlir-assigner/include/mlir-assigner/components/fixedpoint/division.hpp b/mlir-assigner/include/mlir-assigner/components/fixedpoint/division.hpp index b2eb186..0299192 100644 --- a/mlir-assigner/include/mlir-assigner/components/fixedpoint/division.hpp +++ b/mlir-assigner/include/mlir-assigner/components/fixedpoint/division.hpp @@ -7,7 +7,6 @@ #include #include -#include // TODO: check if there is a new mechanism for this in nil upstream #include #include @@ -24,7 +23,8 @@ namespace nil { circuit_proxy> &bp, assignment_proxy> &assignment, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::fix_div< crypto3::zk::snark::plonk_constraint_system, BlueprintFieldType, basic_non_native_policy>; diff --git a/mlir-assigner/include/mlir-assigner/components/fixedpoint/dot_product.hpp b/mlir-assigner/include/mlir-assigner/components/fixedpoint/dot_product.hpp index 619b542..ffdc467 100644 --- a/mlir-assigner/include/mlir-assigner/components/fixedpoint/dot_product.hpp +++ b/mlir-assigner/include/mlir-assigner/components/fixedpoint/dot_product.hpp @@ -11,7 +11,6 @@ #include #include #include -#include // TODO: check if there is a new mechanism for this in nil upstream #include #include diff --git a/mlir-assigner/include/mlir-assigner/components/fixedpoint/erf.hpp b/mlir-assigner/include/mlir-assigner/components/fixedpoint/erf.hpp index b9c8374..fef7299 100644 --- a/mlir-assigner/include/mlir-assigner/components/fixedpoint/erf.hpp +++ b/mlir-assigner/include/mlir-assigner/components/fixedpoint/erf.hpp @@ -7,7 +7,6 @@ #include #include -#include // TODO: check if there is a new mechanism for this in nil upstream #include @@ -22,7 +21,8 @@ namespace nil { circuit_proxy> &bp, assignment_proxy> &assignment, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::fix_erf< crypto3::zk::snark::plonk_constraint_system, BlueprintFieldType, basic_non_native_policy>; diff --git a/mlir-assigner/include/mlir-assigner/components/fixedpoint/exp.hpp b/mlir-assigner/include/mlir-assigner/components/fixedpoint/exp.hpp index 65060e5..9fe3c70 100644 --- a/mlir-assigner/include/mlir-assigner/components/fixedpoint/exp.hpp +++ b/mlir-assigner/include/mlir-assigner/components/fixedpoint/exp.hpp @@ -8,7 +8,6 @@ #include #include #include -#include // TODO: check if there is a new mechanism for this in nil upstream #include #include @@ -26,7 +25,8 @@ namespace nil { circuit_proxy> &bp, assignment_proxy> &assignment, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::fix_exp_ranged< crypto3::zk::snark::plonk_constraint_system, BlueprintFieldType, basic_non_native_policy>; @@ -48,7 +48,8 @@ namespace nil { circuit_proxy> &bp, assignment_proxy> &assignment, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::fix_exp< crypto3::zk::snark::plonk_constraint_system, BlueprintFieldType, basic_non_native_policy>; diff --git a/mlir-assigner/include/mlir-assigner/components/fixedpoint/floor.hpp b/mlir-assigner/include/mlir-assigner/components/fixedpoint/floor.hpp index b21183f..704431c 100644 --- a/mlir-assigner/include/mlir-assigner/components/fixedpoint/floor.hpp +++ b/mlir-assigner/include/mlir-assigner/components/fixedpoint/floor.hpp @@ -7,7 +7,6 @@ #include #include -#include // TODO: check if there is a new mechanism for this in nil upstream #include #include @@ -25,7 +24,8 @@ namespace nil { circuit_proxy> &bp, assignment_proxy> &assignment, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::fix_floor< crypto3::zk::snark::plonk_constraint_system, BlueprintFieldType, basic_non_native_policy>; diff --git a/mlir-assigner/include/mlir-assigner/components/fixedpoint/gather.hpp b/mlir-assigner/include/mlir-assigner/components/fixedpoint/gather.hpp index ba3cdc6..a9bf32d 100644 --- a/mlir-assigner/include/mlir-assigner/components/fixedpoint/gather.hpp +++ b/mlir-assigner/include/mlir-assigner/components/fixedpoint/gather.hpp @@ -8,7 +8,6 @@ #include #include -#include // TODO: check if there is a new mechanism for this in nil upstream #include #include @@ -25,10 +24,12 @@ namespace nil { assignment_proxy> &assignment, crypto3::zk::snark::plonk_variable &nextIndex, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::fix_gather_acc< crypto3::zk::snark::plonk_constraint_system, - BlueprintFieldType, basic_non_native_policy>; + BlueprintFieldType, + basic_non_native_policy>; using input_type = typename component_type::input_type; input_type input; diff --git a/mlir-assigner/include/mlir-assigner/components/fixedpoint/log.hpp b/mlir-assigner/include/mlir-assigner/components/fixedpoint/log.hpp index 30229b3..af367cd 100644 --- a/mlir-assigner/include/mlir-assigner/components/fixedpoint/log.hpp +++ b/mlir-assigner/include/mlir-assigner/components/fixedpoint/log.hpp @@ -8,7 +8,6 @@ #include #include #include -#include // TODO: check if there is a new mechanism for this in nil upstream #include #include @@ -25,7 +24,8 @@ namespace nil { circuit_proxy> &bp, assignment_proxy> &assignment, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::fix_log< crypto3::zk::snark::plonk_constraint_system, BlueprintFieldType, basic_non_native_policy>; diff --git a/mlir-assigner/include/mlir-assigner/components/fixedpoint/mul_rescale.hpp b/mlir-assigner/include/mlir-assigner/components/fixedpoint/mul_rescale.hpp index 4bdaa70..0919f7d 100644 --- a/mlir-assigner/include/mlir-assigner/components/fixedpoint/mul_rescale.hpp +++ b/mlir-assigner/include/mlir-assigner/components/fixedpoint/mul_rescale.hpp @@ -7,7 +7,6 @@ #include #include -#include // TODO: check if there is a new mechanism for this in nil upstream #include #include @@ -23,7 +22,8 @@ namespace nil { circuit_proxy> &bp, assignment_proxy> &assignment, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::fix_mul_rescale< crypto3::zk::snark::plonk_constraint_system, BlueprintFieldType, basic_non_native_policy>; diff --git a/mlir-assigner/include/mlir-assigner/components/fixedpoint/neg.hpp b/mlir-assigner/include/mlir-assigner/components/fixedpoint/neg.hpp index 186f47d..7fac670 100644 --- a/mlir-assigner/include/mlir-assigner/components/fixedpoint/neg.hpp +++ b/mlir-assigner/include/mlir-assigner/components/fixedpoint/neg.hpp @@ -7,7 +7,6 @@ #include #include -#include #include #include @@ -23,7 +22,8 @@ namespace nil { circuit_proxy> &bp, assignment_proxy> &assignment, - const common_component_parameters> &compParams) { + const common_component_parameters< + crypto3::zk::snark::plonk_variable> &compParams) { using component_type = components::fix_neg< crypto3::zk::snark::plonk_constraint_system, BlueprintFieldType, basic_non_native_policy>; diff --git a/mlir-assigner/include/mlir-assigner/components/fixedpoint/remainder.hpp b/mlir-assigner/include/mlir-assigner/components/fixedpoint/remainder.hpp index 0b34cd4..2568ece 100644 --- a/mlir-assigner/include/mlir-assigner/components/fixedpoint/remainder.hpp +++ b/mlir-assigner/include/mlir-assigner/components/fixedpoint/remainder.hpp @@ -7,7 +7,6 @@ #include #include -#include // TODO: check if there is a new mechanism for this in nil upstream #include #include diff --git a/mlir-assigner/include/mlir-assigner/components/fixedpoint/sqrt.hpp b/mlir-assigner/include/mlir-assigner/components/fixedpoint/sqrt.hpp index 49d7487..5cfe7f0 100644 --- a/mlir-assigner/include/mlir-assigner/components/fixedpoint/sqrt.hpp +++ b/mlir-assigner/include/mlir-assigner/components/fixedpoint/sqrt.hpp @@ -8,7 +8,6 @@ #include #include -#include // TODO: check if there is a new mechanism for this in nil upstream #include #include diff --git a/mlir-assigner/include/mlir-assigner/components/fixedpoint/trigonometric.hpp b/mlir-assigner/include/mlir-assigner/components/fixedpoint/trigonometric.hpp index f898291..3c56105 100644 --- a/mlir-assigner/include/mlir-assigner/components/fixedpoint/trigonometric.hpp +++ b/mlir-assigner/include/mlir-assigner/components/fixedpoint/trigonometric.hpp @@ -5,7 +5,6 @@ #include #include -#include // TODO: check if there is a new mechanism for this in nil upstream #include #include diff --git a/mlir-assigner/include/mlir-assigner/components/handle_component.hpp b/mlir-assigner/include/mlir-assigner/components/handle_component.hpp index 2677784..37c8b08 100644 --- a/mlir-assigner/include/mlir-assigner/components/handle_component.hpp +++ b/mlir-assigner/include/mlir-assigner/components/handle_component.hpp @@ -66,7 +66,8 @@ #include #include #include -#include + +#include #define PREPARE_UNARY_INPUT(OP) \ prepare_unary_operation_input( \ diff --git a/mlir-assigner/include/mlir-assigner/components/integer/mul_div.hpp b/mlir-assigner/include/mlir-assigner/components/integer/mul_div.hpp index 5b31c41..5090d85 100644 --- a/mlir-assigner/include/mlir-assigner/components/integer/mul_div.hpp +++ b/mlir-assigner/include/mlir-assigner/components/integer/mul_div.hpp @@ -5,7 +5,6 @@ #include #include -#include #include #include