public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug target/114621] [11/12/13/14 Regression] ICE: in extract_insn, at recog.cc:2812 (unrecognizable insn) with -O -fpie and _Thread_local with large offset Date: Mon, 08 Apr 2024 18:06:55 +0000 [thread overview] Message-ID: <bug-114621-4-TzzmkLTIr4@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-114621-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114621 --- Comment #5 from Jakub Jelinek <jakub at gcc dot gnu.org> --- While for the local exec we happily use something like movq %fs:0, %rax movabsq $b@tpoff+34359738367, %rdx addq %rdx, %rax movzbl (%rax), %eax we normally use instructions like movsbl %fs:b@tpoff+31, %eax Thus, I'd say at least in the normal code models we have a restriction that the static TLS area of the whole program must fit into 2GB. If we want to support something larger, we'd need to use 64-bit relocations consistently for all LE/IE accesses regardless of whether the immediate offset into them is > 2GB or not, because it could just be that some other library has the static TLS area > 2GB and comes earlier, or some other TU etc. x86-64 has both R_X86_64_TPOFF32 and R_X86_64_TPOFF64 relocations, but it wouldn't help if we use the 32-bit ones in say char a; __thread char b[0x100000000L]; __thread char c[32L]; int foo (void) { return c[31L]; } it just won't really link.
next prev parent reply other threads:[~2024-04-08 18:06 UTC|newest] Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top 2024-04-06 19:26 [Bug target/114621] New: " zsojka at seznam dot cz 2024-04-06 19:36 ` [Bug target/114621] [11/12/13/14 Regression] " pinskia at gcc dot gnu.org 2024-04-08 8:04 ` jakub at gcc dot gnu.org 2024-04-08 8:24 ` jakub at gcc dot gnu.org 2024-04-08 17:36 ` jakub at gcc dot gnu.org 2024-04-08 18:06 ` jakub at gcc dot gnu.org [this message] 2024-04-12 13:34 ` law at gcc dot gnu.org 2024-04-12 13:38 ` jakub at gcc dot gnu.org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-114621-4-TzzmkLTIr4@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).