Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8309685

Fix -Wconversion warnings in assembler and register code

XMLWordPrintable

    • b04

        Turning on -Wconversion and off -Werror and filtering for the most numerous -Wconversion warnings shows that many come from a few specific .hpp files where the warning is reported for all files that include the file.

        6054 /scratch/cphillim/hg/21more-conversion/src/hotspot/share/compiler/oopMap.hpp
        5075 /scratch/cphillim/hg/21more-conversion/src/hotspot/cpu/x86/vmreg_x86.hpp
        4068 /scratch/cphillim/hg/21more-conversion/src/hotspot/cpu/x86/register_x86.hpp
        2836 /scratch/cphillim/hg/21more-conversion/src/hotspot/cpu/x86/macroAssembler_x86.hpp
        1594 /scratch/cphillim/hg/21more-conversion/src/hotspot/cpu/x86/assembler_x86.hpp
        1368 /scratch/cphillim/hg/21more-conversion/src/hotspot/share/runtime/registerMap.hpp
        941 /scratch/cphillim/hg/21more-conversion/src/hotspot/cpu/x86/assembler_x86.cpp

        With a few checked_cast<>, direct casts, narrowing return types, and promoting argument types can eliminate these warnings.

              coleenp Coleen Phillimore
              coleenp Coleen Phillimore
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Created:
                Updated:
                Resolved: