Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[C++][Benchmarking] Can't build with Google Benchmark 1.8.0 #35458

Closed
kou opened this issue May 6, 2023 · 0 comments · Fixed by #35459
Closed

[C++][Benchmarking] Can't build with Google Benchmark 1.8.0 #35458

kou opened this issue May 6, 2023 · 0 comments · Fixed by #35459

Comments

@kou
Copy link
Member

kou commented May 6, 2023

Describe the enhancement requested

https://github.com/apache/arrow/actions/runs/4897907287/jobs/8746494685?pr=35454#step:6:1881

 In file included from /arrow/cpp/src/arrow/builder_benchmark.cc:32:
/arrow/cpp/src/arrow/util/benchmark_util.h:150:8: error: 'void arrow::MemoryPoolMemoryManager::Stop(benchmark::MemoryManager::Result*)' marked 'override', but does not override
  150 |   void Stop(benchmark::MemoryManager::Result* result) override {
      |        ^~~~
/arrow/cpp/src/arrow/util/benchmark_util.h:201:36: error: cannot declare field 'arrow::BenchmarkMemoryTracker::manager_' to be of abstract type 'arrow::MemoryPoolMemoryManager'
  201 |   ::arrow::MemoryPoolMemoryManager manager_;
      |                                    ^~~~~~~~
/arrow/cpp/src/arrow/util/benchmark_util.h:142:7: note:   because the following virtual functions are pure within 'arrow::MemoryPoolMemoryManager':
  142 | class MemoryPoolMemoryManager : public benchmark::MemoryManager {
      |       ^~~~~~~~~~~~~~~~~~~~~~~
In file included from /arrow/cpp/src/arrow/builder_benchmark.cc:27:
/opt/conda/envs/arrow/include/benchmark/benchmark.h:408:16: note:     'virtual void benchmark::MemoryManager::Stop(benchmark::MemoryManager::Result&)'
  408 |   virtual void Stop(Result& result) = 0;
      |                ^~~~

google/benchmark@9714eb8 is related.

Component(s)

Benchmarking, C++

kou added a commit to kou/arrow that referenced this issue May 6, 2023
… later

Google Benchmark 1.6.1 added `benchmark::MemoryManager::Stop(Result&)`
and deprecated `benchmark::MemoryManager::Stop(Result*)`.

Google Benchmark 1.8.0 dropped deprecated
`benchmark::MemoryManager::Stop(Result*)`.

We can always use `benchmark::MemoryManager::Stop(Result&)` by
requiring Google Benchmark 1.6.1 or later.
@kou kou closed this as completed in #35459 May 9, 2023
kou added a commit that referenced this issue May 9, 2023
…#35459)

### Rationale for this change

Google Benchmark 1.6.1 added `benchmark::MemoryManager::Stop(Result&)` and deprecated `benchmark::MemoryManager::Stop(Result*)`.

Google Benchmark 1.8.0 dropped deprecated
`benchmark::MemoryManager::Stop(Result*)`.

Google Benchmark deprecated `DoNotOptimize(const &)`:
google/benchmark#1493

### What changes are included in this PR?

We can always use `benchmark::MemoryManager::Stop(Result&)` by requiring Google Benchmark 1.6.1 or later.

Don't use deprecated `DoNotOptimize(const &)`.

### Are these changes tested?

Yes.

### Are there any user-facing changes?

No.
* Closes: #35458

Authored-by: Sutou Kouhei <kou@clear-code.com>
Signed-off-by: Sutou Kouhei <kou@clear-code.com>
@kou kou added this to the 13.0.0 milestone May 9, 2023
liujiacheng777 pushed a commit to LoongArch-Python/arrow that referenced this issue May 11, 2023
… later (apache#35459)

### Rationale for this change

Google Benchmark 1.6.1 added `benchmark::MemoryManager::Stop(Result&)` and deprecated `benchmark::MemoryManager::Stop(Result*)`.

Google Benchmark 1.8.0 dropped deprecated
`benchmark::MemoryManager::Stop(Result*)`.

Google Benchmark deprecated `DoNotOptimize(const &)`:
google/benchmark#1493

### What changes are included in this PR?

We can always use `benchmark::MemoryManager::Stop(Result&)` by requiring Google Benchmark 1.6.1 or later.

Don't use deprecated `DoNotOptimize(const &)`.

### Are these changes tested?

Yes.

### Are there any user-facing changes?

No.
* Closes: apache#35458

Authored-by: Sutou Kouhei <kou@clear-code.com>
Signed-off-by: Sutou Kouhei <kou@clear-code.com>
ArgusLi pushed a commit to Bit-Quill/arrow that referenced this issue May 15, 2023
… later (apache#35459)

### Rationale for this change

Google Benchmark 1.6.1 added `benchmark::MemoryManager::Stop(Result&)` and deprecated `benchmark::MemoryManager::Stop(Result*)`.

Google Benchmark 1.8.0 dropped deprecated
`benchmark::MemoryManager::Stop(Result*)`.

Google Benchmark deprecated `DoNotOptimize(const &)`:
google/benchmark#1493

### What changes are included in this PR?

We can always use `benchmark::MemoryManager::Stop(Result&)` by requiring Google Benchmark 1.6.1 or later.

Don't use deprecated `DoNotOptimize(const &)`.

### Are these changes tested?

Yes.

### Are there any user-facing changes?

No.
* Closes: apache#35458

Authored-by: Sutou Kouhei <kou@clear-code.com>
Signed-off-by: Sutou Kouhei <kou@clear-code.com>
rtpsw pushed a commit to rtpsw/arrow that referenced this issue May 16, 2023
… later (apache#35459)

### Rationale for this change

Google Benchmark 1.6.1 added `benchmark::MemoryManager::Stop(Result&)` and deprecated `benchmark::MemoryManager::Stop(Result*)`.

Google Benchmark 1.8.0 dropped deprecated
`benchmark::MemoryManager::Stop(Result*)`.

Google Benchmark deprecated `DoNotOptimize(const &)`:
google/benchmark#1493

### What changes are included in this PR?

We can always use `benchmark::MemoryManager::Stop(Result&)` by requiring Google Benchmark 1.6.1 or later.

Don't use deprecated `DoNotOptimize(const &)`.

### Are these changes tested?

Yes.

### Are there any user-facing changes?

No.
* Closes: apache#35458

Authored-by: Sutou Kouhei <kou@clear-code.com>
Signed-off-by: Sutou Kouhei <kou@clear-code.com>
@raulcd raulcd modified the milestones: 13.0.0, 12.0.1 May 31, 2023
raulcd pushed a commit that referenced this issue May 31, 2023
…#35459)

### Rationale for this change

Google Benchmark 1.6.1 added `benchmark::MemoryManager::Stop(Result&)` and deprecated `benchmark::MemoryManager::Stop(Result*)`.

Google Benchmark 1.8.0 dropped deprecated
`benchmark::MemoryManager::Stop(Result*)`.

Google Benchmark deprecated `DoNotOptimize(const &)`:
google/benchmark#1493

### What changes are included in this PR?

We can always use `benchmark::MemoryManager::Stop(Result&)` by requiring Google Benchmark 1.6.1 or later.

Don't use deprecated `DoNotOptimize(const &)`.

### Are these changes tested?

Yes.

### Are there any user-facing changes?

No.
* Closes: #35458

Authored-by: Sutou Kouhei <kou@clear-code.com>
Signed-off-by: Sutou Kouhei <kou@clear-code.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants