[Bug libstdc++/113202] std::find does not work with the maximum range of pointers
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113202 --- Comment #6 from Carsten Schmidt --- > Why do you think this is a bug? 1. Considering the "possible implementation" of cppreference.com, pointer arithmetic, e.g. ptr-ptr, should not be an issue when searching for the sentinel. 2. Using ranges::find() does not show the observed behavior. 3. Other implementations of the libstdc++, e.g. MSVC, work properly.
[Bug libstdc++/113202] std::find does not work with the maximum range of pointers
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113202 --- Comment #4 from Carsten Schmidt --- NOTE: My .ii file exceeds the size limit, so I attached the originating code instead.
[Bug libstdc++/113202] std::find does not work with the maximum range of pointers
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113202 --- Comment #3 from Carsten Schmidt --- Created attachment 56979 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=56979&action=edit Output when executing the program.
[Bug libstdc++/113202] std::find does not work with the maximum range of pointers
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113202 --- Comment #2 from Carsten Schmidt --- Created attachment 56978 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=56978&action=edit Output of the compilation.
[Bug libstdc++/113202] std::find does not work with the maximum range of pointers
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113202 --- Comment #1 from Carsten Schmidt --- Created attachment 56977 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=56977&action=edit A demonstration of the description.
[Bug libstdc++/113202] New: std::find does not work with the maximum range of pointers
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113202 Bug ID: 113202 Summary: std::find does not work with the maximum range of pointers Product: gcc Version: 13.2.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: libstdc++ Assignee: unassigned at gcc dot gnu.org Reporter: carsten.schmidt-achim at gmx dot de Target Milestone: --- When using std::find() to operate on a range of pointers that is delimited by the maximum pointer value possible, AKA std::numeric_limits::max(), std::find() returns unreasonable results; cf. the attached example. When implementing the same functionality using std::ranges::find(), the returned results are reasonable.
[Bug c++/97217] C++ program compiled with GCC crashes
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97217 --- Comment #4 from Carsten Schmidt --- Sorry for the inconvenience! o the exact version of GCC o the system type o the options given when GCC was configured/built Please confer to file output.txt. o the complete command line that triggers the bug The program needs to be invoked either unittest_array.exe [direction] OR unittest_array.exe [inverse] Both test cases crash the program; other test cases do not seem to be affected. o the compiler output (error messages, warnings, etc.) Again, please confer to file output.txt. o the preprocessed file (*.i*) that triggers the bug Please see the attached archive ii_files.zip.
[Bug c++/97217] C++ program compiled with GCC crashes
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97217 --- Comment #3 from Carsten Schmidt --- Created attachment 49282 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=49282&action=edit Complete output of the compiler run; including version information.
[Bug c++/97217] C++ program compiled with GCC crashes
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97217 --- Comment #2 from Carsten Schmidt --- Created attachment 49281 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=49281&action=edit The *.ii files generated.
[Bug c++/97217] New: C++ program compiled with GCC crashes
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97217 Bug ID: 97217 Summary: C++ program compiled with GCC crashes Product: gcc Version: 10.2.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: carsten.schmidt-achim at gmx dot de Target Milestone: --- Created attachment 49277 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=49277&action=edit Example assembly listing causing the crash. During development of my vector/matrix library using template meta programming, I discovered that my test program crashes on some occasions when being compiled with GCC. When inspecting the assembly code generated by GCC, the instruction crashing the program seems to be unrelated to the data flow of the program. I will attach the generated assembly of one of my test cases, which crashes the program. Please let me know if you would like to investigate further and how I can be of service!