From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 5F22E3858D37; Mon, 12 Feb 2024 14:45:25 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 5F22E3858D37 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1707749125; bh=TA4yOcL41B0qiwuhGKucHu2vJpSYCh2SgYgsk99q3x0=; h=From:To:Subject:Date:In-Reply-To:References:From; b=el5LkZPcmxvrit6ikrKbvfzb8Rn4HJ64xiMZVz0zAviO87OsnNtI2iyRwyfl/kYso CSm7LpA1OzARbzf7oa7llK7/RtffO4mod9OZ8HPf6KG8aWu6iELRapGGr9i+LzLmDG n+aQgjpeJNKGWPPdiyxGZWCpj1QoNWVenX5Lff/U= From: "jakub at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/113874] GNU2 TLS descriptor calls do not follow psABI on x86_64-linux-gnu Date: Mon, 12 Feb 2024 14:45:24 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: target X-Bugzilla-Version: 13.2.1 X-Bugzilla-Keywords: ABI, wrong-code X-Bugzilla-Severity: normal X-Bugzilla-Who: jakub at gcc dot gnu.org X-Bugzilla-Status: RESOLVED X-Bugzilla-Resolution: MOVED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D113874 --- Comment #25 from Jakub Jelinek --- (In reply to H.J. Lu from comment #23) > > And i386/dl-tlsdesc.S needs to save/restore 387 and SSE regs? >=20 > i386 doesn't preserve them in _dl_runtime_resolve nor _dl_tlsdesc_dynamic. That is different. _dl_runtime_resolve happens only at the start of calls = to functions, if in all supported ia32 ABIs all of i387 state is unsupported u= pon entering functions, then there is no need to save anything. While _dl_tlsdesc_dynamic can happen anywhere from within functions and doe= sn't clobber any registers except ax which gets the value, so I think it needs t= o be saved for that case.=