https://bugs.llvm.org/show_bug.cgi?id=43472
Bug ID: 43472
Summary: undefined behavior santizer compiler segfault
__int128_t non-type template parameter
Product: clang
Version: 9.0
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: C++
Assignee: unassignedclangb...@nondot.org
Reporter: patrick.a.mo...@gmail.com
CC: blitzrak...@gmail.com, dgre...@apple.com,
erik.pilking...@gmail.com, llvm-bugs@lists.llvm.org,
richard-l...@metafoo.co.uk
Created attachment 22583
--> https://bugs.llvm.org/attachment.cgi?id=22583&action=edit
The preprocessed source of the repro
I'm encountering a segfault in the clang 9.0.0 compiler under code I've
attached:
* It only manifests with -fsanitize=undefined
* It only manifests at -O1 and up (not at -O0)
* It only manifests when the template struct has a typename template parameter
and a non-type template parameter of that type.
* It only manifests when the type argument is __int128_t
* It only manifests when a static member function of the template class
returns an instance of the class **and** a function consumes the value
* If you just cast the return of the static member function to void, the
issue does not reproduce.
* It manifests at standards c++03, c++11, c++14, c++17 and c++2a.
The diagnostic message:
********************
PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT:
Preprocessed source(s) and associated run script(s) are located at:
clang-9: note: diagnostic msg: /tmp/test_fixed_point-11869e.cpp
clang-9: note: diagnostic msg: /tmp/test_fixed_point-11869e.sh
clang-9: note: diagnostic msg:
********************
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs