<html>
  <head>

    <meta http-equiv="content-type" content="text/html; charset=utf-8">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <blockquote type="cite"><a
        href="https://gcc.gnu.org/wiki/Visibility"><a class="moz-txt-link-freetext" href="https://gcc.gnu.org/wiki/Visibility">https://gcc.gnu.org/wiki/Visibility</a></a>
      says "However, -fvisibility-inlines-hidden can be used with no
      source alterations, unless you need to override it for inlines
      where address identity is important either for the function itself
      <b>or any function local static data.</b>" (Clearly this is
      somewhat bogus: if the addresses of function local statics are
      different, their contents may also be different.)</blockquote>
    <blockquote type="cite">The behavior of this switch is not quite the
      same as marking the methods as hidden directly, because it <b>does
        not affect static variables local to the function</b> or cause
      the compiler to deduce that the function is defined in only one
      shared object.</blockquote>
    <br>
    Thanks for your detailed explanation.<br>
    <br>
    One more strange thing, remove the -fvisibility-inlines-hidden flag
    not works with some codes of our project.<br>
    I can't reproduce for a simple demo for now. Another flag we use is
    -fvisibility-ms-compat, before adding it for gcc, all works fine.<br>
    Now both gcc and clang are broken. (Since the counter code enables
    in debug build only, it's not so important for now)<br>
    <br>
    I will remove -fvisibility-ms-compat rebuild with clang and test
    again.<br>
    <br>
    <div class="moz-signature">-- <br>
      <i>Regards</i></div>
  </body>
</html>