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/100354] [9/10/11/12 regression] aarch64: non-deligitimized UNSPEC UNSPEC_TLS (76) found in variable location Date: Tue, 08 Feb 2022 18:54:50 +0000 [thread overview] Message-ID: <bug-100354-4-YibzQcRI0v@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-100354-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100354 Jakub Jelinek <jakub at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |ktkachov at gcc dot gnu.org, | |rearnsha at gcc dot gnu.org, | |rsandifo at gcc dot gnu.org --- Comment #7 from Jakub Jelinek <jakub at gcc dot gnu.org> --- It could be e.g. done by having the targetm.const_not_ok_for_debug_p target hook not return true for the UNSPEC_TLS case and have some new target hook that would handle emitting debug info for an UNSPEC. Or a way to just quiet the note (I'll repeat it is -fchecking only) would be to use as the operand of UNSPEC_TLS not const0_rtx as it does, but some magic SYMBOL_REF with SYMBOL_REF_TLS_MODEL non-zero on it. Say like: --- gcc/config/aarch64/aarch64.md.jj 2022-01-11 23:11:21.682300103 +0100 +++ gcc/config/aarch64/aarch64.md 2022-02-08 19:51:00.581676457 +0100 @@ -6833,7 +6833,8 @@ (define_insn "ldr_got_tiny_sidi" (define_insn "aarch64_load_tp_hard" [(set (match_operand:DI 0 "register_operand" "=r") - (unspec:DI [(const_int 0)] UNSPEC_TLS))] + (unspec:DI [(match_operand 1 "aarch64_tls_le_symref" "S")] + UNSPEC_TLS))] "" "mrs\\t%0, tpidr_el0" [(set_attr "type" "mrs")] --- gcc/config/aarch64/aarch64.cc.jj 2022-02-04 14:36:54.262615676 +0100 +++ gcc/config/aarch64/aarch64.cc 2022-02-08 19:46:58.206051731 +0100 @@ -18474,7 +18474,9 @@ aarch64_load_tp (rtx target) target = gen_reg_rtx (Pmode); /* Can return in any reg. */ - emit_insn (gen_aarch64_load_tp_hard (target)); + rtx sym = gen_rtx_SYMBOL_REF (Pmode, ""); + SYMBOL_REF_FLAGS (sym) = TLS_MODEL_LOCAL_EXEC << SYMBOL_FLAG_TLS_SHIFT; + emit_insn (gen_aarch64_load_tp_hard (target, sym)); return target; }
next prev parent reply other threads:[~2022-02-08 18:54 UTC|newest] Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-04-30 12:07 [Bug target/100354] New: [9 " nsz at gcc dot gnu.org 2021-04-30 12:48 ` [Bug target/100354] [9/10/11/12 " acoplan at gcc dot gnu.org 2021-05-03 7:29 ` rguenth at gcc dot gnu.org 2021-06-01 8:20 ` rguenth at gcc dot gnu.org 2021-10-25 18:23 ` acoplan at gcc dot gnu.org 2022-01-21 12:16 ` rguenth at gcc dot gnu.org 2022-01-21 12:22 ` jakub at gcc dot gnu.org 2022-02-08 18:27 ` jakub at gcc dot gnu.org 2022-02-08 18:54 ` jakub at gcc dot gnu.org [this message] 2022-05-27 9:45 ` [Bug target/100354] [10/11/12/13 " rguenth at gcc dot gnu.org 2022-06-28 10:44 ` jakub at gcc dot gnu.org 2023-07-07 10:39 ` [Bug target/100354] [11/12/13/14 " rguenth at gcc dot gnu.org 2024-03-11 3:23 ` [Bug target/100354] [11/12/13 " law at gcc dot gnu.org 2024-03-11 3:28 ` [Bug target/100354] [11/12/13/14 " pinskia 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-100354-4-YibzQcRI0v@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).