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

Build warning in methodData.cpp memset zero-length parameter

    XMLWordPrintable

Details

    • b06

    Backports

      Description

        Seen in our CI on Fedora 12 with gcc 8.3:

        ```
        void Copy::pd_zero_to_bytes(void*, size_t)' at /home/ubuntu/client_home/workspace/build-user-branch-linux_x86_64/SapMachine/src/hotspot/cpu/x86/copy_x86.hpp:59:15,
            inlined from 'static void Copy::zero_to_bytes(void*, size_t)' at /home/ubuntu/client_home/workspace/build-user-branch-linux_x86_64/SapMachine/src/hotspot/share/utilities/copy.hpp:298:21,
            inlined from 'void MethodData::initialize()' at

        /home/ubuntu/client_home/workspace/build-user-branch-linux_x86_64/SapMachine/src/hotspot/share/oops/methodData.cpp:1248:22:
        /opt/devkits/devkit-fedora-gcc-12-8.3.0/x86_64-linux-gnu/sysroot/usr/include/bits/string3.h:82:30: error: call to '__warn_memset_zero_len' declared with attribute warning: memset used with constant zero length parameter; this could be due to transposed parameters [-Werror]
               __warn_memset_zero_len ();
               ~~~~~~~~~~~~~~~~~~~~~~~^~
        ```

        Attachments

          Issue Links

            Activity

              People

                stuefe Thomas Stuefe
                stuefe Thomas Stuefe
                Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved: