RFR: 8307147: [x86] Dangling pointer warning for Assembler::_attributes [v3]

Kim Barrett kbarrett at openjdk.org
Thu May 4 02:12:57 UTC 2023


> Please review this change to work around a false positive -Wdangling-pointer
> warning from gcc13.1.  The approach being taken is to suppress the warning,
> with a comment describing why it's a false positive.  Also a little code
> restructuring to make it more obvious.
> 
> I tried various code modifications to avoid the warning, but they were either
> obscure, large and instrusive, or didn't seem reliably future-proof against
> further changes in gcc's analysis.  And that's just for the attempts that
> worked.
> 
> Testing:
> mach5 tier1-3 with gcc11.2 (current default in Oracle's CI)
> 
> Local (linux-x64) tier1 with gcc13.1, and verified the relevant warnings are
> not reported.  This required disabling compiler warnings as errors, as there
> are other new warnings from gcc13.1: JDK-8307210 and JDK-8307196.

Kim Barrett has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains four additional commits since the last revision:

 - Merge branch 'master' into instr-attr5
 - improve wording per aph
 - suppress x86 InstructionAttr warning
 - warning disable pragma

-------------

Changes:
  - all: https://git.openjdk.org/jdk/pull/13751/files
  - new: https://git.openjdk.org/jdk/pull/13751/files/530f4f65..0d030549

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=13751&range=02
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=13751&range=01-02

  Stats: 6344 lines in 250 files changed: 3934 ins; 1123 del; 1287 mod
  Patch: https://git.openjdk.org/jdk/pull/13751.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/13751/head:pull/13751

PR: https://git.openjdk.org/jdk/pull/13751


More information about the hotspot-dev mailing list