]> git.ipfire.org Git - thirdparty/gcc.git/commit
sparc: Remove TARGET_SUN_TLS
authorRainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
Thu, 15 Jan 2026 12:03:59 +0000 (13:03 +0100)
committerRainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
Thu, 15 Jan 2026 12:03:59 +0000 (13:03 +0100)
commit8f4a39ee10975a20bd7a5bb07f23d9bc3cd7ea96
tree10282b622e7d7ce5bd96114018403afc8f24df97
parente4f3fc66841af8206177d5dabb40caccfea3dc2f
sparc: Remove TARGET_SUN_TLS

All remaining uses of TARGET_SUN_TLS refer to either

* a feature missing in Solaris as:

  Lack of support for R_SPARC_TLS_DTPOFF{32,64}: while Solaris ld
  supports those just fine, I know of no Solaris as syntax for them.

* workarounds for bugs in Solaris as in sparc_tls_got,
  sparc_legitimize_tls_address, and the tls_delay_slot attribute

Therefor this patch replaces all uses of TARGET_SUN_TLS with
!HAVE_GNU_AS.

Bootstrapped without regressions on sparc-sun-solaris2.11,
sparcv9-sun-solaris2.11 (as and gas), and sparc64-unknown-linux-gnu.

2026-01-14  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>

gcc:
* config/sparc/sparc.h (TARGET_SUN_TLS): Remove.
* config/sparc/sol2.h (TARGET_SUN_TLS): Likewise.

* config/sparc/sparc.cc (TARGET_ASM_OUTPUT_DWARF_DTPREL): Guard
with HAVE_GNU_AS.
(sparc_tls_got): Guard with !HAVE_GNU_AS.
(sparc_legitimize_tls_address): Likewise.
* config/sparc/sparc.md ("tls_delay_slot"): Likewise.
("@tie_add<P:mode>"): Likewise.
gcc/config/sparc/sol2.h
gcc/config/sparc/sparc.cc
gcc/config/sparc/sparc.h
gcc/config/sparc/sparc.md