google / fleetbench

Benchmarking suite for Google workloads
Apache License 2.0
111 stars 9 forks source link

Issue while bulding KMaxStackDepth #14

Closed atharvabhanage12 closed 1 year ago

atharvabhanage12 commented 1 year ago

Kindly assist me where is the actual issue? Using bazel 6.3.2

`Compiling tcmalloc/transfer_cache.cc failed: (Exit 1): gcc failed: error executing command (from target @com_google_tcmalloc//tcmalloc:common) /bin/gcc -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 '-D_FORTIFY_SOURCE=1' ... (remaining 40 arguments skipped)

Use --sandbox_debug to see verbose messages from the sandbox and retain the sandbox build root for debugging In file included from external/com_google_tcmalloc/tcmalloc/internal/lifetime_tracker.h:21,                 from external/com_google_tcmalloc/tcmalloc/huge_page_filler.h:33,                 from external/com_google_tcmalloc/tcmalloc/huge_region.h:24,                 from external/com_google_tcmalloc/tcmalloc/huge_page_aware_allocator.h:26,                 from external/com_google_tcmalloc/tcmalloc/page_allocator.h:25,                 from external/com_google_tcmalloc/tcmalloc/static_vars.h:39,                 from external/com_google_tcmalloc/tcmalloc/transfer_cache.cc:35: external/com_google_tcmalloc/tcmalloc/internal/lifetime_predictions.h:179:20: error: declaration of 'const int tcmalloc::tcmalloc_internal::LifetimeDatabase::kMaxStackDepth' changes meaning of 'kMaxStackDepth' [-Wchanges-meaning] 179 |   static const int kMaxStackDepth = 64;      |                    ^~~~~~ external/com_google_tcmalloc/tcmalloc/internal/lifetime_predictions.h:107:18: note: used here to mean 'constexpr const int tcmalloc::tcmallocinternal::kMaxStackDepth' 107 |     void* stack[kMaxStackDepth];      |                  ^~~~~~ In file included from external/com_google_tcmalloc/tcmalloc/common.h:37,                 from external/com_google_tcmalloc/tcmalloc/central_freelist.h:28,                 from external/com_google_tcmalloc/tcmalloc/transfer_cache.h:35,                 from external/com_google_tcmalloc/tcmalloc/transfer_cache.cc:15: external/com_google_tcmalloc/tcmalloc/internal/logging.h:49:22: note: declared here   49 | static constexpr int kMaxStackDepth = 64;      |                      ^~~~~~ Target //fleetbench/tcmalloc:empirical_driver failed to build Use --verbose_failures to see the command lines of failed build steps. INFO: Elapsed time: 17.559s, Critical Path: 4.14s INFO: 116 processes: 22 internal, 94 processwrapper-sandbox. FAILED: Build did NOT complete successfully ERROR: Build failed. Not running target `

rjogrady commented 1 year ago

-Wchanges-meaning is a new warning with gcc 13. Currently we have only verified Fleetbench with gcc 12.

However, the code that causes the warning has been removed in the upstream version of tcmalloc. I've upgraded our tcmalloc dependency to the latest and built with gcc 13 - I think it should be working for you now if you pull latest. Thanks for reporting it!

atharvabhanage12 commented 1 year ago

This is the new error. DEBUG: /private/var/tmp/_bazel_athbha01/d016f079ed8063c5398a942b18f70a7b/external/rules_python/python/pip.bzl:47:10: pip_install is deprecated. Please switch to pip_parse. pip_install will be removed in a future release. INFO: Repository libpfm instantiated at: Desktop/bechmark_fleetbech/fleetbench/WORKSPACE:110:13: in Repository rule http_archive defined at: /private/var/tmp/_bazel_athbha01/d016f079ed8063c5398a942b18f70a7b/external/bazel_tools/tools/build_defs/repo/http.bzl:372:31: in WARNING: Download from https://sourceforge.net/projects/perfmon2/files/libpfm4/libpfm-4.11.0.tar.gz/download failed: class com.google.devtools.build.lib.bazel.repository.downloader.UnrecoverableHttpException Checksum was 251a85b3bac687974f360d3796048c20ded3bf0bd69e0d1cfd1db23d013f89ed but wanted 5da5f8872bde14b3634c9688d980f68bda28b510268723cc12973eedbab9fecc ERROR: An error occurred during the fetch of repository 'libpfm': Traceback (most recent call last): File "/private/var/tmp/_bazel_athbha01/d016f079ed8063c5398a942b18f70a7b/external/bazel_tools/tools/build_defs/repo/http.bzl", line 132, column 45, in _http_archive_impl download_info = ctx.download_and_extract( Error in download_and_extract: java.io.IOException: Error downloading [https://sourceforge.net/projects/perfmon2/files/libpfm4/libpfm-4.11.0.tar.gz/download] to /private/var/tmp/_bazel_athbha01/d016f079ed8063c5398a942b18f70a7b/external/libpfm/temp3458073497591957110/download.tar.gz: Checksum was 251a85b3bac687974f360d3796048c20ded3bf0bd69e0d1cfd1db23d013f89ed but wanted 5da5f8872bde14b3634c9688d980f68bda28b510268723cc12973eedbab9fecc ERROR: /Desktop/bechmark_fleetbech/fleetbench/WORKSPACE:110:13: fetching http_archive rule //external:libpfm: Traceback (most recent call last): File "/private/var/tmp/_bazel_athbha01/d016f079ed8063c5398a942b18f70a7b/external/bazel_tools/tools/build_defs/repo/http.bzl", line 132, column 45, in _http_archive_impl download_info = ctx.download_and_extract( Error in download_and_extract: java.io.IOException: Error downloading [https://sourceforge.net/projects/perfmon2/files/libpfm4/libpfm-4.11.0.tar.gz/download] to /private/var/tmp/_bazel_athbha01/d016f079ed8063c5398a942b18f70a7b/external/libpfm/temp3458073497591957110/download.tar.gz: Checksum was 251a85b3bac687974f360d3796048c20ded3bf0bd69e0d1cfd1db23d013f89ed but wanted 5da5f8872bde14b3634c9688d980f68bda28b510268723cc12973eedbab9fecc ERROR: /private/var/tmp/_bazel_athbha01/d016f079ed8063c5398a942b18f70a7b/external/com_google_benchmark/BUILD.bazel:35:11: @com_google_benchmark//:benchmark depends on @libpfm//:libpfm in repository @libpfm which failed to fetch. no such package '@libpfm//': java.io.IOException: Error downloading [https://sourceforge.net/projects/perfmon2/files/libpfm4/libpfm-4.11.0.tar.gz/download] to /private/var/tmp/_bazel_athbha01/d016f079ed8063c5398a942b18f70a7b/external/libpfm/temp3458073497591957110/download.tar.gz: Checksum was 251a85b3bac687974f360d3796048c20ded3bf0bd69e0d1cfd1db23d013f89ed but wanted 5da5f8872bde14b3634c9688d980f68bda28b510268723cc12973eedbab9fecc ERROR: Analysis of target '//fleetbench/tcmalloc:empirical_driver' failed; build aborted: INFO: Elapsed time: 335.156s INFO: 0 processes. FAILED: Build did NOT complete successfully (75 packages loaded, 703 targets configured) ERROR: Build failed. Not running target

rjogrady commented 1 year ago

It looks like Sourceforge is having trouble with downloads. https://downdetector.com/status/sourceforge/

It should resolve itself soon, hopefully.

A workaround for now is to disable libpfm when you build: bazel build --define=pfm=0 fleetbench/tcmalloc:empirical_driver