Tests fail on CentOS 6.9 (binutils is 2.20 where addr2line does not support -a flag)

オープン
#338 コメント 9 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
35/100
issue の種類
バグ
明瞭さ
明確に書かれている
活発さ
停滞
技術スタック
centos, go, linux

調査の方向性

失敗は internal/binutils/addr2liner.go の 92 行目付近に起因しており、報告されたアサーションは binutils_test.go:252 にあります。まず、CentOS 6.9 上で binutils 2.20 を使用して TestObjFile のサブテストを実行し、addr2line がどのように呼び出されているかを調べてください。インストールされている addr2line に -a フラグがなくてもテストがパスすれば完了です。

索引モデルが issue の本文から書いたものです。

説明

Priority: p3 type: bug

xref: https://github.com/golang/go/issues/23888

What version of pprof are you using?

a74ae6fb3cd7047c79272e3ea0814b08154a2d3c

What operating system and processor architecture are you using?

CentOS 6.9, x86_64

What did you do?

Compiled go from source, tests failed, came to this repo, tried running the tests, was able to reproduce the exact same failure.

What did you expect to see?

It'd be great if the tests had passed!

What did you see instead?

The following tests failed:

--- FAIL: TestObjFile (0.02s)
    --- FAIL: TestObjFile/fake_mapping (0.01s)
        binutils_test.go:252: SourceLine: unexpected error write |1: broken pipe
    --- FAIL: TestObjFile/fixed_load_address (0.01s)
        binutils_test.go:252: SourceLine: unexpected error write |1: broken pipe
    --- FAIL: TestObjFile/simulated_ASLR_address (0.01s)
        binutils_test.go:252: SourceLine: unexpected error write |1: broken pipe
Why do these tests fail?

The code at https://github.com/google/pprof/blob/a74ae6fb3cd7047c79272e3ea0814b08154a2d3c/internal/binutils/addr2liner.go#L92 assumes that the -a flag is available to the binary addr2line, which is available if the binutils version is >=2.21 ; but the latest version available on CentOS 6.9 is 2.20

主要言語
Go
スター
9.3k
フォーク
687
平均マージ
4日 17時間
マージ済み PR(30日)
14

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

google/pprof のほかの issue

google/pprof の issue をすべて見る

似ている issue

Go の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。