Skip to content

Commit

Permalink
2093 - remove dead code in cbind.cpp for public kernel
Browse files Browse the repository at this point in the history
  • Loading branch information
jeanmon committed Sep 7, 2023
1 parent 99ee337 commit ac094c1
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 26 deletions.
24 changes: 0 additions & 24 deletions circuits/cpp/src/aztec3/circuits/kernel/public/c_bind.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,30 +23,6 @@ using aztec3::circuits::kernel::public_kernel::native_public_kernel_circuit_publ

// WASM Cbinds

WASM_EXPORT size_t public_kernel__init_proving_key(uint8_t const** pk_buf)
{
std::vector<uint8_t> pk_vec(42, 0);

auto* raw_buf = (uint8_t*)malloc(pk_vec.size());
memcpy(raw_buf, (void*)pk_vec.data(), pk_vec.size());
*pk_buf = raw_buf;

return pk_vec.size();
}

WASM_EXPORT size_t public_kernel__init_verification_key(uint8_t const* pk_buf, uint8_t const** vk_buf)
{
std::vector<uint8_t> vk_vec(42, 0);
// TODO(dbanks12): remove when proving key is used
(void)pk_buf; // unused

auto* raw_buf = (uint8_t*)malloc(vk_vec.size());
memcpy(raw_buf, (void*)vk_vec.data(), vk_vec.size());
*vk_buf = raw_buf;

return vk_vec.size();
}

CBIND(public_kernel__sim, [](PublicKernelInputs<NT> public_kernel_inputs) {
DummyBuilder builder = DummyBuilder("public_kernel__sim");
KernelCircuitPublicInputs<NT> const result =
Expand Down
2 changes: 0 additions & 2 deletions circuits/cpp/src/aztec3/circuits/kernel/public/c_bind.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,4 @@
#include <cstddef>
#include <cstdint>

WASM_EXPORT size_t public_kernel__init_proving_key(uint8_t const** pk_buf);
WASM_EXPORT size_t public_kernel__init_verification_key(uint8_t const* pk_buf, uint8_t const** vk_buf);
CBIND_DECL(public_kernel__sim);

0 comments on commit ac094c1

Please sign in to comment.