Skip to content

Commit

Permalink
fix: compiler hints
Browse files Browse the repository at this point in the history
  • Loading branch information
ludamad0 committed Oct 19, 2023
1 parent 6c0d8ae commit 60fd533
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 19 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,6 @@
#include "barretenberg/stdlib/primitives/packed_byte_array/packed_byte_array.hpp"
#include "barretenberg/stdlib/primitives/witness/witness.hpp"

// TODO(AD): put this into a header
#if defined(__clang__)
#define BBERG_INSTRUMENT [[clang::xray_always_instrument]]
#define BBERG_NOINLINE [[clang::noinline]]
#else
#define BBERG_INSTRUMENT
#define BBERG_NOINLINE
#endif

using namespace proof_system;

template <typename Builder> void generate_sha256_test_circuit(Builder& builder, size_t num_iterations)
Expand Down
7 changes: 0 additions & 7 deletions barretenberg/cpp/src/barretenberg/common/inline.hpp

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
#include <thread>
#include <vector>

#include "barretenberg/common/compiler_hints.hpp"

namespace {

class ThreadPool {
Expand Down Expand Up @@ -50,7 +52,7 @@ class ThreadPool {
std::condition_variable complete_condition_;
bool stop = false;

[[clang::xray_never_instrument]] void worker_loop(size_t thread_index);
BBERG_NO_INSTRUMENT void worker_loop(size_t thread_index);

void do_iterations()
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#pragma once
#include "barretenberg/common/assert.hpp"
#include "barretenberg/common/inline.hpp"
#include "barretenberg/common/compiler_hints.hpp"
#include "barretenberg/numeric/random/engine.hpp"
#include "barretenberg/numeric/uint128/uint128.hpp"
#include "barretenberg/numeric/uint256/uint256.hpp"
Expand Down
2 changes: 1 addition & 1 deletion barretenberg/cpp/src/barretenberg/ecc/groups/element.hpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#pragma once

#include "affine_element.hpp"
#include "barretenberg/common/inline.hpp"
#include "barretenberg/common/compiler_hints.hpp"
#include "barretenberg/common/mem.hpp"
#include "barretenberg/numeric/random/engine.hpp"
#include "barretenberg/numeric/uint256/uint256.hpp"
Expand Down

0 comments on commit 60fd533

Please sign in to comment.