From: "Martin v. Loewis" <martin@loewis.home.cs.tu-berlin.de>
To: yz@mailhost.telecruz.com
Cc: help-gcc@gnu.org
Subject: Re: GCC ASM(): Urgent!
Date: Sat, 01 Apr 2000 00:00:00 -0000 [thread overview]
Message-ID: <200003010850.JAA00667@loewis.home.cs.tu-berlin.de> (raw)
Message-ID: <20000401000000.j6A7P-FHwmYZ88x61F0fnk9wxm2eXTkOu4DmGs0vvKU@z> (raw)
In-Reply-To: <38BC7BDD.8C3DFF6C@telecruz.com>
> 1. What does .frame,.mask and .fmask means?
I don't know anything about MIPS assembly, but looking at
config/mips/mips.c, it appears that
.frame defines how the stack frame is organized, with the parameters
<register holding the frame pointer>, <size of the frame pointer>
<register holding the return value>
.mask and .fmask describe what registers are saved:
.mask <mask of gp registers saved>,<offset from vfp to store gp registers>
.fmask <mask of saved fp registers>,<offset from vfp to store fp registers>
> 2. Which registers are protected? Which registers I can use in my ASM()
> routine?
I can't answer this question.
> 3. How to support Mips R3900 instruction like MULT rd,rs,rt?
According to mips.h and mips.md, this is generated when
/* Generate three-operand multiply instructions for both SImode and DImode. */
#define GENERATE_MULT3 (TARGET_MIPS3900 \
&& !TARGET_MIPS16)
So it should be should be used if not on a 16bit target.
> 4. In GCC book within a macro "\" gives operator value, but the example
> gives compile error:
> .macro mname rd
> .word \ rd
> .endm
Again, I don't know.
> 5. How to debug and trace in the asm() instructions in a .C file?
What exactly do you mean by trace? Please use the option --save-temps;
this will produce a .s file, which contains the generated assembler
code for inspection.
Hope this helps,
Martin
next prev parent reply other threads:[~2000-04-01 0:00 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2000-02-29 18:10 YZ Dai
2000-03-01 0:59 ` Martin v. Loewis [this message]
2000-04-01 0:00 ` Martin v. Loewis
2000-03-01 11:34 ` Alexandre Oliva
2000-04-01 0:00 ` Alexandre Oliva
2000-04-01 0:00 ` YZ Dai
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=200003010850.JAA00667@loewis.home.cs.tu-berlin.de \
--to=martin@loewis.home.cs.tu-berlin.de \
--cc=help-gcc@gnu.org \
--cc=yz@mailhost.telecruz.com \
/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: link
Be 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).