[llvm-bugs] [Bug 43535] New: LowerTypeTest BitSetBuilder causes Access Violation

via llvm-bugs llvm-bugs at lists.llvm.org
Tue Oct 1 22:45:06 PDT 2019


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

            Bug ID: 43535
           Summary: LowerTypeTest BitSetBuilder causes Access Violation
           Product: lld
           Version: unspecified
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: normal
          Priority: P
         Component: COFF
          Assignee: unassignedbugs at nondot.org
          Reporter: donovan.t.maas at gmail.com
                CC: llvm-bugs at lists.llvm.org

Created attachment 22618
  --> https://bugs.llvm.org/attachment.cgi?id=22618&action=edit
The project file with all of the compilation settings

This happens in LLVM 8.0.1 that ships MSVC 2019 16.3.2, the downloadable
binaries for LLVM 9.0.0, and the custom build for the stack trace that was
cloned and built from commit e3887253165cd6c40accf3ce1534ef0d20ec676b. The OS
is Windows 10 Pro 64Bit Version 1903, Build 18362.356, I am running on an AMD
Ryzen 7 3700X with 16GiB of RAM.

Visual Studio reported that the invalid address was 0x0000000000000008.

When compiling in Release mode the linker crashes and performs a stack dump. It
is able to build without error in Debug mode which leads me to believe it is
caused by some optimization setting. I've included the project file which has
all of the build settings. I have spent several hours fiddling with the
settings of this project and its dependencies and I've yet to identify what is
causing this issue. The differences between Debug and Release are:

UseDebugLibraries: Yes -> No
WholeProgramOptimization: No -> Yes
Optimization: /Od (Disabled) -> /O2 (Maximum Speed)
InlineFunctionExpansion: Default -> /Ob2 (Any Suitable)
FavorSizeOrSpeed: Neither -> /Ot (Favor Fast Code)
OmitFramePointers: No -> Yes
RuntimeLibrary: /MTd (Multi-Threaded Debug Static) -> /MT (Multi-Threaded
Release Static)

GenerateDebugInfo: /DEBUG:FASTLINK -> /DEBUG:FULL

Stack Trace:
lld-link.exe!llvm::lowertypetests::BitSetBuilder::build(void)
lld-link.exe!llvm::lowertypetests::isJumpTableCanonical(class llvm::Function *)
lld-link.exe!llvm::LowerTypeTestsPass::run(class llvm::Module &,class
llvm::AnalysisManager<class llvm::Module> &)
lld-link.exe!llvm::FPPassManager::runOnModule(class llvm::Module &)
lld-link.exe!llvm::legacy::PassManager::run(class llvm::Module &)
lld-link.exe!llvm::detail::PassModel<class llvm::Module,class
llvm::VerifierPass,class llvm::PreservedAnalyses,class
llvm::AnalysisManager<class llvm::Module> >::run(class llvm::Module &,class
llvm::AnalysisManager<class llvm::Module> &)
lld-link.exe!llvm::detail::PassModel<class llvm::Module,class
llvm::VerifierPass,class llvm::PreservedAnalyses,class
llvm::AnalysisManager<class llvm::Module> >::name(void)
lld-link.exe!llvm::lto::backend(struct llvm::lto::Config &,class
std::function<class std::unique_ptr<class llvm::lto::NativeObjectStream,struct
std::default_delete<class llvm::lto::NativeObjectStream> > >,unsigned int,class
std::unique_ptr<class llvm::Module,struct std::default_delete<class
llvm::Module> >,class llvm::ModuleSummaryIndex &)
lld-link.exe!llvm::lto::LTO::runRegularLTO(class std::function<class
std::unique_ptr<class llvm::lto::NativeObjectStream,struct
std::default_delete<class llvm::lto::NativeObjectStream> > >)
lld-link.exe!llvm::lto::LTO::run(class std::function<class
std::unique_ptr<class llvm::lto::NativeObjectStream,struct
std::default_delete<class llvm::lto::NativeObjectStream> > >,class
std::function<class std::function<class std::unique_ptr<class
llvm::lto::NativeObjectStream,struct std::default_delete<class
llvm::lto::NativeObjectStream> > > >)
lld-link.exe!lld::coff::BitcodeCompiler::compile(void)
lld-link.exe!lld::coff::SymbolTable::addCombinedLTOObjects(void)
lld-link.exe!lld::coff::LinkerDriver::link(class llvm::ArrayRef<char const *>)
lld-link.exe!lld::coff::link(class llvm::ArrayRef<char const *>,bool,class
llvm::raw_ostream &)
lld-link.exe!main()
[Inline Frame] lld-link.exe!invoke_main() Line 78
    at
d:\agent\_work\3\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl(78)
lld-link.exe!__scrt_common_main_seh() Line 288
    at
d:\agent\_work\3\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl(288)
kernel32.dll!BaseThreadInitThunk()
ntdll.dll!RtlUserThreadStart()

-- 
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/20191002/89d1e331/attachment.html>


More information about the llvm-bugs mailing list