Skip to content

Generate DWARF version 4 max#34777

Merged
kitaisreal merged 3 commits intomasterfrom
dwarf-4
Feb 21, 2022
Merged

Generate DWARF version 4 max#34777
kitaisreal merged 3 commits intomasterfrom
dwarf-4

Conversation

@alexey-milovidov
Copy link
Copy Markdown
Member

Changelog category (leave one):

  • Build/Testing/Packaging Improvement

Changelog entry (a user-readable short description of the changes that goes to CHANGELOG.md):
Limit DWARF version for debug info by 4 max, because our internal stack symbolizer cannot parse DWARF version 5. This makes sense if you compile ClickHouse with clang-15.

I compiled ClickHouse and get this:

$ clickhouse-local 
ClickHouse local version 22.3.1.1.

milovidov-nix :) SELECT throwIf(1)

SELECT throwIf(1)

Query id: 32a0fec4-2093-4240-978e-a2fe9976358c

Exception on client:
Code: 465. DB::Exception: invalid info version. (CANNOT_PARSE_DWARF)

@robot-clickhouse robot-clickhouse added the pr-build Pull request with build/testing/packaging improvement label Feb 20, 2022
@kitaisreal kitaisreal self-assigned this Feb 21, 2022
@kitaisreal
Copy link
Copy Markdown
Contributor

@Mergifyio update

@mergify
Copy link
Copy Markdown
Contributor

mergify bot commented Feb 21, 2022

update

✅ Branch has been successfully updated

@kitaisreal kitaisreal merged commit af4cf03 into master Feb 21, 2022
@kitaisreal kitaisreal deleted the dwarf-4 branch February 21, 2022 09:58
@azat azat mentioned this pull request Feb 21, 2022
azat added a commit to azat/ClickHouse that referenced this pull request May 24, 2022
This should fix DWARF version for ASM sources (from ClickHouse#34754):

    $ llvm-dwarfdump -r 1 clickhouse | grep Compile -A10 | grep -A10 'version = 0x0005'
    ...
    --
    0x1de11022: Compile Unit: length = 0x000000e7, format = DWARF32, version = 0x0005, unit_type = DW_UT_compile, abbr_offset = 0x551dc0, addr_size = 0x08 (next unit at 0x1de1110d)

    0x1de1102e: DW_TAG_compile_unit
                  DW_AT_stmt_list   (0x057e3442)
                  DW_AT_low_pc      (0x00000000101cde0c)
                  DW_AT_high_pc     (0x00000000101cde5e)
                  DW_AT_name        ("/ClickHouse/contrib/libunwind/src/UnwindRegistersSave.S")
                  DW_AT_comp_dir    ("/fasttest-workspace/build")
                  DW_AT_producer    ("Ubuntu clang version 14.0.1-++20220426083040+0e27d08cdeb3-1~exp1~20220426083051.129")
                  DW_AT_language    (DW_LANG_Mips_Assembler)
    ...

Follow-up for: ClickHouse#34777 (cc @alexey-milovidov)
Signed-off-by: Azat Khuzhin <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-build Pull request with build/testing/packaging improvement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants