[llvm-bugs] [Bug 32965] New: ODRHash hashes type sugar

via llvm-bugs llvm-bugs at lists.llvm.org
Mon May 8 06:33:41 PDT 2017


https://bugs.llvm.org/show_bug.cgi?id=32965

            Bug ID: 32965
           Summary: ODRHash hashes type sugar
           Product: clang
           Version: unspecified
          Hardware: PC
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Modules
          Assignee: unassignedclangbugs at nondot.org
          Reporter: vvasilev at cern.ch
                CC: dgregor at apple.com, llvm-bugs at lists.llvm.org

Created attachment 18416
  --> https://bugs.llvm.org/attachment.cgi?id=18416&action=edit
A standalone reproducer

r301989 caused regression in our builds. We spent some time reducing and
understanding the example.

To use reproduce it open test.sh rewire your compiler and run it. The output
is:

rm -fr pcms/* ; "/Users/vvassilev/workspace/llvm-git/obj/bin/clang++" -cc1
-triple x86_64-unknown-linux-gnu -fsyntax-only -disable-free -main-file-name
TGQt.cxx -mrelocation-model pic -pic-level 2 -mthread-model posix
-mdisable-fp-elim -fmath-errno -masm-verbose -mconstructor-aliases
-munwind-tables -fuse-init-array -target-cpu x86-64  -dwarf-column-info
-debug-info-kind=limited -dwarf-version=4 -debugger-tuning=gdb -resource-dir
`pwd`/cvmfs/sft.cern.ch/lcg/contrib/llvm/builds/x86_64-slc6-gcc62-opt/clang_build_302187/lib/clang/5.0.0
-D QT_CORE_LIB -D QT_GUI_LIB -I
./mnt/build/jenkins/workspace/root-nightly-cxxmodules/BUILDTYPE/Debug/COMPILER/clang_gcc62/LABEL/slc6/build/include
-internal-isystem
`pwd`/afs/cern.ch/sw/lcg/contrib/gcc/6.2/x86_64-slc6/include/c++/6.2.0
-internal-isystem
`pwd`/afs/cern.ch/sw/lcg/contrib/gcc/6.2/x86_64-slc6/include/c++/6.2.0/x86_64-pc-linux-gnu
-internal-isystem
`pwd`/afs/cern.ch/sw/lcg/contrib/gcc/6.2/x86_64-slc6/include/c++/6.2.0/backward
-internal-isystem
`pwd`/cvmfs/sft.cern.ch/lcg/contrib/llvm/builds/x86_64-slc6-gcc62-opt/clang_build_302187/lib/clang/5.0.0/include
-internal-externc-isystem `pwd`/usr/include -Wshadow -Wall -W
-Woverloaded-virtual -Wc++11-narrowing -Wsign-compare -Wsometimes-uninitialized
-Wconditional-uninitialized -Wheader-guard -Warray-bounds -Wcomment
-Wtautological-compare -Wstrncat-size -Wloop-analysis -Wbool-conversion
-Wno-module-import-in-extern-c -Wno-deprecated-register -Wno-deprecated
-Wno-uninitialized -std=c++11 -fno-autolink -fdebug-compilation-dir
./build/jenkins/workspace/root-nightly-cxxmodules/BUILDTYPE/Debug/COMPILER/clang_gcc62/LABEL/slc6/build/standalone
-ferror-limit 19 -fmessage-length 114 -pthread -fmodules -fimplicit-module-maps
-fmodules-cache-path=./pcms/ -fobjc-runtime=gcc -fcxx-exceptions -fexceptions
-fdiagnostics-show-option -fdiagnostics-show-note-include-stack
-fcolor-diagnostics -fmodules-local-submodule-visibility -x c++
./mnt/build/jenkins/workspace/root-nightly-cxxmodules/BUILDTYPE/Debug/COMPILER/clang_gcc62/LABEL/slc6/build/TGQt.cxx
-nostdsysteminc -Rmodule-build
./mnt/build/jenkins/workspace/root-nightly-cxxmodules/BUILDTYPE/Debug/COMPILER/clang_gcc62/LABEL/slc6/build/TGQt.cxx:27:10:
remark: 
      building module 'libGQt.so' as
     
'/Users/vvassilev/workspace/reproducers/PR_ODRVisitor2/standalone/pcms/1LGRIN2OWEDGY/libGQt.so-3TBZLKNN4S8RG.pcm'
      [-Rmodule-build]
#include "TGQt.h"
         ^
./mnt/build/jenkins/workspace/root-nightly-cxxmodules/BUILDTYPE/Debug/COMPILER/clang_gcc62/LABEL/slc6/build/TGQt.cxx:27:10:
remark: 
      finished building module 'libGQt.so' [-Rmodule-build]
In file included from
./mnt/build/jenkins/workspace/root-nightly-cxxmodules/BUILDTYPE/Debug/COMPILER/clang_gcc62/LABEL/slc6/build/TGQt.cxx:22:
./mnt/build/jenkins/workspace/root-nightly-cxxmodules/BUILDTYPE/Debug/COMPILER/clang_gcc62/LABEL/slc6/build/include/qstring1.h:9:8:
error: 
      'QString' has different definitions in different modules; first
difference is defined here found method
      'vsprintf' with 2nd parameter of type '__va_list_tag *' decayed from
'va_list' (aka '__builtin_va_list')
  void vsprintf(const char *format, va_list ap);
  ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In module 'libGQt.so' imported from
./mnt/build/jenkins/workspace/root-nightly-cxxmodules/BUILDTYPE/Debug/COMPILER/clang_gcc62/LABEL/slc6/build/TGQt.cxx:27:
./mnt/build/jenkins/workspace/root-nightly-cxxmodules/BUILDTYPE/Debug/COMPILER/clang_gcc62/LABEL/slc6/build/include/qstring1.h:9:8:
note: 
      but in 'libGQt.so.TGQt.h' found method 'vsprintf' with 2nd parameter of
type '__va_list_tag *' decayed from
      'va_list' (aka '__builtin_va_list')
  void vsprintf(const char *format, va_list ap);
  ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20170508/efc50ca8/attachment-0001.html>


More information about the llvm-bugs mailing list