Barretenberg
The ZK-SNARK library at the core of Aztec
Loading...
Searching...
No Matches
sload_impl.hpp
Go to the documentation of this file.
1// AUTOGENERATED FILE
2#pragma once
3
6
7namespace bb::avm2 {
8
9template <typename FF_>
10template <typename ContainerOverSubrelations, typename AllEntities>
11void sloadImpl<FF_>::accumulate(ContainerOverSubrelations& evals,
12 const AllEntities& in,
13 [[maybe_unused]] const RelationParameters<FF_>&,
14 [[maybe_unused]] const FF_& scaling_factor)
15{
16 using C = ColumnAndShifts;
17
18 const auto constants_MEM_TAG_FF = FF(0);
19
20 { // SLOAD_FF_OUTPUT_TAG
21 using View = typename std::tuple_element_t<0, ContainerOverSubrelations>::View;
22 auto tmp = static_cast<View>(in.get(C::execution_sel_execute_sload)) *
23 (CView(constants_MEM_TAG_FF) - static_cast<View>(in.get(C::execution_mem_tag_reg_1_)));
24 std::get<0>(evals) += (tmp * scaling_factor);
25 }
26 { // SLOAD_SUCCESS
27 using View = typename std::tuple_element_t<1, ContainerOverSubrelations>::View;
28 auto tmp = static_cast<View>(in.get(C::execution_sel_execute_sload)) *
29 static_cast<View>(in.get(C::execution_sel_opcode_error));
30 std::get<1>(evals) += (tmp * scaling_factor);
31 }
32}
33
34} // namespace bb::avm2
static void accumulate(ContainerOverSubrelations &evals, const AllEntities &in, const RelationParameters< FF > &, const FF &scaling_factor)
ColumnAndShifts
Definition columns.hpp:34
AvmFlavorSettings::FF FF
Definition field.hpp:10
constexpr decltype(auto) get(::tuplet::tuple< T... > &&t) noexcept
Definition tuple.hpp:13
#define CView(v)
Container for parameters used by the grand product (permutation, lookup) Honk relations.