[llvm-bugs] [Bug 26463] New: Run-time assert while building Chromium

via llvm-bugs llvm-bugs at lists.llvm.org
Wed Feb 3 14:14:00 PST 2016


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

            Bug ID: 26463
           Summary: Run-time assert while building Chromium
           Product: clang
           Version: unspecified
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: release blocker
          Priority: P
         Component: C++
          Assignee: unassignedclangbugs at nondot.org
          Reporter: xiwe at microsoft.com
                CC: dgregor at apple.com, llvm-bugs at lists.llvm.org
    Classification: Unclassified

In my recent attempt to recollect updated Chrome build data on Mac, chrome
starts to fail to build (both out/Release and out/Debug) with additional
throughput data collection switch “-ftime-report” due to multiple occurrence of
assertion below:

Assertion failed: (!Running && "Cannot start a running timer"), function
startTimer, file
/Users/thakis/src/chrome/src/third_party/llvm/lib/Support/Timer.cpp, line 139.

Chrome build.ninja (with additional switches), build failure logs, and
automatically created standalone repros are attached/pasted below. Note this
only repros with “-ftime-report” switch set – chrome builds successfully on Mac
without modifications on build.ninja. But I need that switch to collect
throughput data.

For some reason, the assertion didn’t repro when I ran those automatically
created repro scripts in their folder
/var/folders/8z/77mjhj5j6592xmd2_wq53wrw0000gn/T/. It might because it is some
timing sensitive bug - like perhaps the compiler can't create a timer if there
are too many other compilers running in parallel?

Modified build commands (in build.ninja file), and one occurrence of that
assertion in Chrome build log are pasted below:


Additional switch added to build.ninja (full file attached):
rule cc
  command = $cc -MMD -MF $out.d $defines $includes $cflags $cflags_c
-ftime-report $cflags_pch_c -c $in -o $out
  description = CC $out
  depfile = $out.d
  deps = gcc
rule cc_s
  command = $cc $defines $includes $cflags $cflags_c -ftime-report
$cflags_pch_c -c $in -o $out
  description = CC $out
rule cxx
  command = $cxx -MMD -MF $out.d $defines $includes $cflags $cflags_cc
-ftime-report $cflags_pch_cc -c $in -o $out
  description = CXX $out
  depfile = $out.d
  deps = gcc
rule objc
  command = $cc -MMD -MF $out.d $defines $includes $cflags $cflags_objc
-ftime-report $cflags_pch_objc -c $in -o $out
  description = OBJC $out
  depfile = $out.d
  deps = gcc
rule objcxx
  command = $cxx -MMD -MF $out.d $defines $includes $cflags $cflags_objcc
-ftime-report $cflags_pch_objcc -c $in -o $out
  description = OBJCXX $out
  depfile = $out.d
  deps = gcc

Failure part of build log (full log is too large to be attached)
[7349/20094] CXX obj/sdch/open-vcdiff/src/sdch.codetable.o
[7350/20094] CXX obj/sdch/open-vcdiff/src/sdch.decodetable.o
FAILED: ../../third_party/llvm-build/Release+Asserts/bin/clang++ -MMD -MF
obj/sdch/open-vcdiff/src/sdch.addrcache.o.d -DV8_DEPRECATION_WARNINGS
-DCLD_VERSION=2 -D__ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORE=0
-DCHROMIUM_BUILD -DCR_CLANG_REVISION=257955-1 -DUSE_LIBJPEG_TURBO=1
-DENABLE_ONE_CLICK_SIGNIN -DENABLE_WEBRTC=1 -DENABLE_MEDIA_ROUTER=1
-DENABLE_PEPPER_CDMS -DENABLE_CONFIGURATION_POLICY -DENABLE_NOTIFICATIONS
-DENABLE_HIDPI=1 -DDONT_EMBED_BUILD_METADATA -DFIELDTRIAL_TESTING_ENABLED
-DENABLE_TASK_MANAGER=1 -DENABLE_EXTENSIONS=1 -DENABLE_PDF=1
-DENABLE_PLUGIN_INSTALLATION=1 -DENABLE_PLUGINS=1 -DENABLE_SESSION_SERVICE=1
-DENABLE_THEMES=1 -DENABLE_AUTOFILL_DIALOG=1 -DENABLE_BACKGROUND=1
-DENABLE_PRINTING=1 -DENABLE_BASIC_PRINTING=1 -DENABLE_PRINT_PREVIEW=1
-DENABLE_SPELLCHECK=1 -DUSE_BROWSER_SPELLCHECKER=1
-DENABLE_CAPTIVE_PORTAL_DETECTION=1 -DENABLE_APP_LIST=1 -DENABLE_SETTINGS_APP=1
-DENABLE_SUPERVISED_USERS=1 -DENABLE_SERVICE_DISCOVERY=1
-DV8_USE_EXTERNAL_STARTUP_DATA -DFULL_SAFE_BROWSING -DSAFE_BROWSING_CSD
-DSAFE_BROWSING_DB_LOCAL -DOPEN_VCDIFF_USE_AUTO_PTR -DUSE_LIBPCI=1
-DUSE_OPENSSL=1 -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -DNDEBUG
-DNVALGRIND -DDYNAMIC_ANNOTATIONS_ENABLED=0 -D_FORTIFY_SOURCE=2 -Igen
-I../../sdch/open-vcdiff/src -I../../sdch/mac -I../.. -I../../third_party/zlib
-isysroot
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk
-O2 -gdwarf-2 -fvisibility=hidden -Werror -mmacosx-version-min=10.6 -arch
x86_64 -Wall -Wextra -Wno-unused-parameter -Wno-missing-field-initializers
-Wno-selector-type-mismatch -Wpartial-availability -Wheader-hygiene
-Wfor-loop-analysis -Wno-char-subscripts -Wno-unneeded-internal-declaration
-Wno-covered-switch-default -Wstring-conversion -Wno-c++11-narrowing
-Wno-deprecated-register -Wno-inconsistent-missing-override
-Wno-shift-negative-value -std=c++11 -stdlib=libc++ -fno-rtti -fno-exceptions
-fvisibility-inlines-hidden -fno-threadsafe-statics -Xclang -load -Xclang
/Users/peptest/tp/chromium/src/third_party/llvm-build/Release+Asserts/lib/libFindBadConstructs.dylib
-Xclang -add-plugin -Xclang find-bad-constructs -Xclang
-plugin-arg-find-bad-constructs -Xclang check-templates -fcolor-diagnostics
-fno-strict-aliasing -ftime-report -include obj/sdch/sdch.logging_forward.h-cc
-c ../../sdch/open-vcdiff/src/addrcache.cc -o
obj/sdch/open-vcdiff/src/sdch.addrcache.o
Assertion failed: (!Running && "Cannot start a running timer"), function
startTimer, file
/Users/thakis/src/chrome/src/third_party/llvm/lib/Support/Timer.cpp, line 139.
0  clang                    0x000000010138957b
llvm::sys::PrintStackTrace(llvm::raw_ostream&) + 43
1  clang                    0x0000000101388786 llvm::sys::RunSignalHandlers() +
70
2  clang                    0x0000000101389e61 void*
llvm::object_creator<std::__1::vector<std::__1::basic_string<char,
std::__1::char_traits<char>, std::__1::allocator<char> >,
std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>,
std::__1::allocator<char> > > > >() + 929
3  libsystem_platform.dylib 0x00007fff9680452a _sigtramp + 26
4  clang                    0x0000000103903a6e clang::Stmt::StatisticsEnabled +
29945
5  clang                    0x0000000101389aa6 abort + 22
6  clang                    0x0000000101389a81 __assert_rtn + 81
7  clang                    0x000000010134ae9c llvm::Timer::startTimer() + 108
8  clang                    0x000000010170fe15
clang::EmitObjAction::EmitObjAction(llvm::LLVMContext*) + 533
9  clang                    0x000000010195f14c
clang::MultiplexConsumer::HandleInterestingDecl(clang::DeclGroupRef) + 44
10 clang                    0x0000000101fa7c2b
clang::ASTReader::PassInterestingDeclsToConsumer() + 251
11 clang                    0x0000000101fb282f
clang::ASTReader::FinishedDeserializing() + 799
12 clang                    0x0000000102944bf7
clang::DeclContext::LoadLexicalDeclsFromExternalStorage() const + 407
13 clang                    0x0000000102945947
clang::DeclContext::decls_begin() const + 23
14 clang                    0x00000001015d74ec
clang::CodeGen::CGDebugInfo::CollectRecordFields(clang::RecordDecl const*,
llvm::DIFile*, llvm::SmallVectorImpl<llvm::Metadata*>&, llvm::DICompositeType*)
+ 124
15 clang                    0x00000001015daad1
clang::CodeGen::CGDebugInfo::CreateTypeDefinition(clang::RecordType const*) +
513
16 clang                    0x00000001015d2f4f
clang::CodeGen::CGDebugInfo::getOrCreateType(clang::QualType, llvm::DIFile*) +
79
17 clang                    0x00000001015d64dc
clang::CodeGen::CGDebugInfo::CreateType(clang::TypedefType const*,
llvm::DIFile*) + 60
18 clang                    0x00000001015d2f4f
clang::CodeGen::CGDebugInfo::getOrCreateType(clang::QualType, llvm::DIFile*) +
79
19 clang                    0x00000001015d6792
clang::CodeGen::CGDebugInfo::CreateType(clang::FunctionType const*,
llvm::DIFile*) + 258
20 clang                    0x00000001015d2f4f
clang::CodeGen::CGDebugInfo::getOrCreateType(clang::QualType, llvm::DIFile*) +
79
21 clang                    0x00000001015d77d7
clang::CodeGen::CGDebugInfo::getOrCreateMethodType(clang::CXXMethodDecl const*,
llvm::DIFile*) + 87
22 clang                    0x00000001015d7eb6
clang::CodeGen::CGDebugInfo::CreateCXXMemberFunction(clang::CXXMethodDecl
const*, llvm::DIFile*, llvm::DIType*) + 86
23 clang                    0x00000001015d86a4
clang::CodeGen::CGDebugInfo::CollectCXXMemberFunctions(clang::CXXRecordDecl
const*, llvm::DIFile*, llvm::SmallVectorImpl<llvm::Metadata*>&, llvm::DIType*)
+ 388
24 clang                    0x00000001015daae9
clang::CodeGen::CGDebugInfo::CreateTypeDefinition(clang::RecordType const*) +
537
25 clang                    0x00000001015d2f4f
clang::CodeGen::CGDebugInfo::getOrCreateType(clang::QualType, llvm::DIFile*) +
79
26 clang                    0x00000001015d2bb8
clang::CodeGen::CGDebugInfo::getContextDescriptor(clang::Decl const*,
llvm::DIScope*) + 312
27 clang                    0x00000001015d65fd
clang::CodeGen::CGDebugInfo::CreateType(clang::TypedefType const*,
llvm::DIFile*) + 349
28 clang                    0x00000001015d2f4f
clang::CodeGen::CGDebugInfo::getOrCreateType(clang::QualType, llvm::DIFile*) +
79
29 clang                    0x00000001015d64dc
clang::CodeGen::CGDebugInfo::CreateType(clang::TypedefType const*,
llvm::DIFile*) + 60
30 clang                    0x00000001015d2f4f
clang::CodeGen::CGDebugInfo::getOrCreateType(clang::QualType, llvm::DIFile*) +
79
31 clang                    0x00000001015d6911
clang::CodeGen::CGDebugInfo::createFieldType(llvm::StringRef, clang::QualType,
unsigned long long, clang::SourceLocation, clang::AccessSpecifier, unsigned
long long, llvm::DIFile*, llvm::DIScope*, clang::RecordDecl const*) + 49
32 clang                    0x00000001015d7388
clang::CodeGen::CGDebugInfo::CollectRecordNormalField(clang::FieldDecl const*,
unsigned long long, llvm::DIFile*, llvm::SmallVectorImpl<llvm::Metadata*>&,
llvm::DIType*, clang::RecordDecl const*) + 392
33 clang                    0x00000001015d763c
clang::CodeGen::CGDebugInfo::CollectRecordFields(clang::RecordDecl const*,
llvm::DIFile*, llvm::SmallVectorImpl<llvm::Metadata*>&, llvm::DICompositeType*)
+ 460
34 clang                    0x00000001015daad1
clang::CodeGen::CGDebugInfo::CreateTypeDefinition(clang::RecordType const*) +
513
35 clang                    0x00000001015d2f4f
clang::CodeGen::CGDebugInfo::getOrCreateType(clang::QualType, llvm::DIFile*) +
79
36 clang                    0x00000001015d89a2
clang::CodeGen::CGDebugInfo::CollectCXXBases(clang::CXXRecordDecl const*,
llvm::DIFile*, llvm::SmallVectorImpl<llvm::Metadata*>&, llvm::DIType*) + 642
37 clang                    0x00000001015daaa8
clang::CodeGen::CGDebugInfo::CreateTypeDefinition(clang::RecordType const*) +
472
38 clang                    0x00000001015d2f4f
clang::CodeGen::CGDebugInfo::getOrCreateType(clang::QualType, llvm::DIFile*) +
79
39 clang                    0x00000001015d6911
clang::CodeGen::CGDebugInfo::createFieldType(llvm::StringRef, clang::QualType,
unsigned long long, clang::SourceLocation, clang::AccessSpecifier, unsigned
long long, llvm::DIFile*, llvm::DIScope*, clang::RecordDecl const*) + 49
40 clang                    0x00000001015d7388
clang::CodeGen::CGDebugInfo::CollectRecordNormalField(clang::FieldDecl const*,
unsigned long long, llvm::DIFile*, llvm::SmallVectorImpl<llvm::Metadata*>&,
llvm::DIType*, clang::RecordDecl const*) + 392
41 clang                    0x00000001015d763c
clang::CodeGen::CGDebugInfo::CollectRecordFields(clang::RecordDecl const*,
llvm::DIFile*, llvm::SmallVectorImpl<llvm::Metadata*>&, llvm::DICompositeType*)
+ 460
42 clang                    0x00000001015daad1
clang::CodeGen::CGDebugInfo::CreateTypeDefinition(clang::RecordType const*) +
513
43 clang                    0x00000001015d2f4f
clang::CodeGen::CGDebugInfo::getOrCreateType(clang::QualType, llvm::DIFile*) +
79
44 clang                    0x0000000101725349
clang::CodeGen::CodeGenModule::EmitGlobalDefinition(clang::GlobalDecl,
llvm::GlobalValue*) + 249
45 clang                    0x000000010177ea51
clang::CodeGen::CreateItaniumCXXABI(clang::CodeGen::CodeGenModule&) + 27473
46 clang                    0x000000010172eeab
clang::CodeGen::CodeGenModule::EmitNamespace(clang::NamespaceDecl const*) + 91
47 clang                    0x00000001017a670f
clang::CreateLLVMCodeGen(clang::DiagnosticsEngine&,
std::__1::basic_string<char, std::__1::char_traits<char>,
std::__1::allocator<char> > const&, clang::HeaderSearchOptions const&,
clang::PreprocessorOptions const&, clang::CodeGenOptions const&,
llvm::LLVMContext&, clang::CoverageSourceInfo*) + 1151
48 clang                    0x000000010170fe25
clang::EmitObjAction::EmitObjAction(llvm::LLVMContext*) + 549
49 clang                    0x000000010195f060
clang::MultiplexConsumer::HandleTopLevelDecl(clang::DeclGroupRef) + 48
50 clang                    0x0000000101ec2eb2 clang::ParseAST(clang::Sema&,
bool, bool) + 482
51 clang                    0x0000000101925636 clang::FrontendAction::Execute()
+ 54
52 clang                    0x00000001018e9cb1
clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) + 1089
53 clang                    0x000000010197e6df
clang::ExecuteCompilerInvocation(clang::CompilerInstance*) + 4127
54 clang                    0x00000001000068b3 cc1_main(llvm::ArrayRef<char
const*>, char const*, void*) + 1363
55 clang                    0x0000000100005263 main + 11667
56 clang                    0x0000000100002464 start + 52
57 clang                    0x00000000000000c6 start + 4294958230
Stack dump:
0.            Program arguments:
/Users/peptest/tp/chromium/src/third_party/llvm-build/Release+Asserts/bin/clang
-cc1 -triple x86_64-apple-macosx10.6.0 -Wdeprecated-objc-isa-usage
-Werror=deprecated-objc-isa-usage -emit-obj -disable-free -main-file-name
addrcache.cc -mrelocation-model pic -pic-level 2 -mthread-model posix
-mdisable-fp-elim -relaxed-aliasing -masm-verbose -munwind-tables -target-cpu
core2 -target-linker-version 253.6 -dwarf-column-info
-debug-info-kind=standalone -dwarf-version=2 -debugger-tuning=lldb
-coverage-file
/Users/peptest/tp/chromium/src/out/Release/obj/sdch/open-vcdiff/src/sdch.addrcache.o
-resource-dir
/Users/peptest/tp/chromium/src/third_party/llvm-build/Release+Asserts/bin/../lib/clang/3.9.0
-dependency-file obj/sdch/open-vcdiff/src/sdch.addrcache.o.d -MT
obj/sdch/open-vcdiff/src/sdch.addrcache.o -isysroot
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk
-include-pch obj/sdch/sdch.logging_forward.h-cc.gch -D V8_DEPRECATION_WARNINGS
-D CLD_VERSION=2 -D __ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORE=0 -D
CHROMIUM_BUILD -D CR_CLANG_REVISION=257955-1 -D USE_LIBJPEG_TURBO=1 -D
ENABLE_ONE_CLICK_SIGNIN -D ENABLE_WEBRTC=1 -D ENABLE_MEDIA_ROUTER=1 -D
ENABLE_PEPPER_CDMS -D ENABLE_CONFIGURATION_POLICY -D ENABLE_NOTIFICATIONS -D
ENABLE_HIDPI=1 -D DONT_EMBED_BUILD_METADATA -D FIELDTRIAL_TESTING_ENABLED -D
ENABLE_TASK_MANAGER=1 -D ENABLE_EXTENSIONS=1 -D ENABLE_PDF=1 -D
ENABLE_PLUGIN_INSTALLATION=1 -D ENABLE_PLUGINS=1 -D ENABLE_SESSION_SERVICE=1 -D
ENABLE_THEMES=1 -D ENABLE_AUTOFILL_DIALOG=1 -D ENABLE_BACKGROUND=1 -D
ENABLE_PRINTING=1 -D ENABLE_BASIC_PRINTING=1 -D ENABLE_PRINT_PREVIEW=1 -D
ENABLE_SPELLCHECK=1 -D USE_BROWSER_SPELLCHECKER=1 -D
ENABLE_CAPTIVE_PORTAL_DETECTION=1 -D ENABLE_APP_LIST=1 -D ENABLE_SETTINGS_APP=1
-D ENABLE_SUPERVISED_USERS=1 -D ENABLE_SERVICE_DISCOVERY=1 -D
V8_USE_EXTERNAL_STARTUP_DATA -D FULL_SAFE_BROWSING -D SAFE_BROWSING_CSD -D
SAFE_BROWSING_DB_LOCAL -D OPEN_VCDIFF_USE_AUTO_PTR -D USE_LIBPCI=1 -D
USE_OPENSSL=1 -D __STDC_CONSTANT_MACROS -D __STDC_FORMAT_MACROS -D NDEBUG -D
NVALGRIND -D DYNAMIC_ANNOTATIONS_ENABLED=0 -D _FORTIFY_SOURCE=2 -I gen -I
../../sdch/open-vcdiff/src -I ../../sdch/mac -I ../.. -I ../../third_party/zlib
-stdlib=libc++ -O2 -Werror -Wall -Wextra -Wno-unused-parameter
-Wno-missing-field-initializers -Wno-selector-type-mismatch
-Wpartial-availability -Wheader-hygiene -Wfor-loop-analysis
-Wno-char-subscripts -Wno-unneeded-internal-declaration
-Wno-covered-switch-default -Wstring-conversion -Wno-c++11-narrowing
-Wno-deprecated-register -Wno-inconsistent-missing-override
-Wno-shift-negative-value -std=c++11 -fdeprecated-macro -fdebug-compilation-dir
/Users/peptest/tp/chromium/src/out/Release -ferror-limit 19 -fmessage-length 0
-fvisibility hidden -fvisibility-inlines-hidden -ftime-report -stack-protector
1 -fblocks -fno-rtti -fno-threadsafe-statics -fobjc-runtime=macosx-10.6.0
-fencode-extended-block-signature -fmax-type-align=16 -fdiagnostics-show-option
-fcolor-diagnostics -vectorize-loops -vectorize-slp -load
/Users/peptest/tp/chromium/src/third_party/llvm-build/Release+Asserts/lib/libFindBadConstructs.dylib
-add-plugin find-bad-constructs -plugin-arg-find-bad-constructs check-templates
-o obj/sdch/open-vcdiff/src/sdch.addrcache.o -x c++
../../sdch/open-vcdiff/src/addrcache.cc 
1.            <eof> parser at end of file
2.            ../../sdch/open-vcdiff/src/addrcache.cc:34:11: LLVM IR generation
of declaration 'open_vcdiff'
3.            ../../sdch/open-vcdiff/src/addrcache.cc:46:21: Generating code
for declaration 'open_vcdiff::VCDiffAddressCache::VCDiffAddressCache'
4.           
/Users/peptest/tp/chromium/src/third_party/llvm-build/Release+Asserts/bin/../include/c++/v1/type_traits:460:27:
LLVM IR generation of declaration 'std::__1::integral_constant::operator
type-parameter-0-0'
clang: error: unable to execute command: Illegal instruction: 4
clang: error: clang frontend command failed due to signal (use -v to see
invocation)
clang version 3.9.0 (trunk 257955)
Target: x86_64-apple-darwin15.0.0
Thread model: posix
InstalledDir:
/Users/peptest/tp/chromium/src/out/Release/../../third_party/llvm-build/Release+Asserts/bin
clang: note: diagnostic msg: PLEASE submit a bug report to
http://llvm.org/bugs/ and include the crash backtrace, preprocessed source, and
associated run script.
clang: note: diagnostic msg: 
********************

PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT:
Preprocessed source(s) and associated run script(s) are located at:
clang: note: diagnostic msg:
/var/folders/8z/77mjhj5j6592xmd2_wq53wrw0000gn/T/addrcache-91f433.cpp
clang: note: diagnostic msg:
/var/folders/8z/77mjhj5j6592xmd2_wq53wrw0000gn/T/addrcache-91f433.sh
clang: note: diagnostic msg:

-- 
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/20160203/a997d259/attachment-0001.html>


More information about the llvm-bugs mailing list