linux-mips
[Top] [All Lists]

Re: Is r25 saved across syscalls?

To: "Kevin D. Kissell" <kevink@paralogos.com>
Subject: Re: Is r25 saved across syscalls?
From: David Daney <ddaney.cavm@gmail.com>
Date: Mon, 10 Sep 2012 18:27:55 -0700
Cc: linux-mips@linux-mips.org
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=p4PjrGXx3lKLKp2kQnzLpCiIVrj9McRvZZ4761IaWAQ=; b=ucoG0MgH+9kaDRxQSpCOmglFe+uxWtSiMJ9FaJFL5iDrzJ3SfHyIO+6b8XaqnZ+KNv dmjlrgWnH8URWtNYXPXWsskei8jeV1W0/uMW1beTarcYkuW3IEaGyjfn53+ow5quBkUm R77RY5rFkaffAEpfrjexBFGKeZWp6WyGH6/+//Ki5N2k5nkFliTX+kKcSYwzLvHUIOzL Cta6pPKxhFdPpR7PkXHdQp3MUO87gsyWNBQP5Ay21X11oCJvd7TqBMXwQjg85fbKhSPL ehE3GbkPM734PdHeS5fkexap6cGCYg5oFH6fWR7i+Up+VSjKROT+YGOc9rby/AYGwL1B diWw==
In-reply-to: <504E8E27.5030904@paralogos.com>
List-archive: <http://www.linux-mips.org/archives/linux-mips/>
List-help: <mailto:ecartis@linux-mips.org?Subject=help>
List-id: linux-mips <linux-mips.eddie.linux-mips.org>
List-owner: <mailto:ralf@linux-mips.org>
List-post: <mailto:linux-mips@linux-mips.org>
List-software: Ecartis version 1.0.0
List-subscribe: <mailto:ecartis@linux-mips.org?subject=subscribe%20linux-mips>
List-unsubscribe: <mailto:ecartis@linux-mips.org?subject=unsubscribe%20linux-mips>
References: <20120909193008.GA15157@brightrain.aerifal.cx> <20120910170830.GB24448@linux-mips.org> <20120910172248.GN27715@brightrain.aerifal.cx> <alpine.LFD.2.00.1209110059580.8926@eddie.linux-mips.org> <504E8E27.5030904@paralogos.com>
Sender: linux-mips-bounce@linux-mips.org
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:15.0) Gecko/20120828 Thunderbird/15.0
On 09/10/2012 06:04 PM, Kevin D. Kissell wrote:
On 09/10/2012 05:29 PM, Maciej W. Rozycki wrote:
I do wonder however why we have these instructions to save/restore $25
in SAVE_SOME/RESTORE_SOME. This dates back to 2.4 at the very least.
Ralf, any insights?
Hi, guys.  Maybe the fact that it's used for dispatching PIC calls has
something to do with it?


I don't think so. It is call clobbered in all Linux ABIs. So there is never a need to save it. It even has the pseudonym of $t9 indicating that it will get clobbered.

The other call clobbered registers that happen to be saved are for the nefarious uses of the kernel itself (a0..a6 for system call restarting), I think this is just left over cruft.

David Daney


/K.






<Prev in Thread] Current Thread [Next in Thread>