[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug ld/30375] New: C++ std::cout's rdbuf gives ridiculous address on wi
From: |
euloanty at live dot com |
Subject: |
[Bug ld/30375] New: C++ std::cout's rdbuf gives ridiculous address on windows with dynamic linking |
Date: |
Fri, 21 Apr 2023 06:06:42 +0000 |
https://sourceware.org/bugzilla/show_bug.cgi?id=30375
Bug ID: 30375
Summary: C++ std::cout's rdbuf gives ridiculous address on
windows with dynamic linking
Product: binutils
Version: 2.41 (HEAD)
Status: UNCONFIRMED
Severity: critical
Priority: P2
Component: ld
Assignee: unassigned at sourceware dot org
Reporter: euloanty at live dot com
Target Milestone: ---
struct foo
{
foo()
{
__builtin_puts("hello\n");
}
};
foo f{};
#include<iostream>
foo death{};
int main()
{
__builtin_puts("before crashing\n");
__builtin_printf("%p\n",std::cout.rdbuf());
__builtin_puts("crashing\n");
}
Here is an example:
>g++ -o hw hw.cc -Ofast -s -I../include
>hw
hello
hello
before crashing
6156746547736C54
crashing
Using lld:
>g++ -o hw hw.cc -Ofast -s -I../include -fuse-ld=lld
>hw
hello
hello
before crashing
00007FFFA97A4C00
crashing
>g++ -o hw hw.cc -Ofast -s -I../include -static
D:\msys64\home\unlvs\projects\fast_io\.temp>hw
hello
hello
before crashing
00007FF62687E8C0
crashing
What happens here??
--
You are receiving this mail because:
You are on the CC list for the bug.
- [Bug ld/30375] New: C++ std::cout's rdbuf gives ridiculous address on windows with dynamic linking,
euloanty at live dot com <=
- [Bug ld/30375] C++ std::cout's rdbuf gives ridiculous address on windows with dynamic linking, euloanty at live dot com, 2023/04/21
- [Bug ld/30375] C++ std::cout's rdbuf gives ridiculous address on windows with dynamic linking, euloanty at live dot com, 2023/04/21
- [Bug ld/30375] C++ std::cout's rdbuf gives ridiculous address on windows with dynamic linking, euloanty at live dot com, 2023/04/21
- [Bug ld/30375] C++ std::cout's rdbuf gives ridiculous address on windows with dynamic linking with ld, euloanty at live dot com, 2023/04/21
- [Bug ld/30375] C++ std::cout's rdbuf gives ridiculous address on windows with dynamic linking with ld, euloanty at live dot com, 2023/04/21
- [Bug ld/30375] C++ std::cout's rdbuf gives ridiculous address on windows with dynamic linking with ld, euloanty at live dot com, 2023/04/21