This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: I really need help!
- To: mrs at windriver dot com (mike stump)
- Subject: Re: I really need help!
- From: Joern Rennecke <amylaar at onetel dot net dot uk>
- Date: Mon, 22 Oct 2001 13:58:40 +0100 (BST)
- Cc: gavinux at yahoo dot com, gcc at gcc dot gnu dot org
mike stump wrote:
>
> > Date: Wed, 17 Oct 2001 17:47:49 -0700 (PDT)
> > From: Gavin Li <gavinux@yahoo.com>
> > To: gcc@gcc.gnu.org
>
> > I am not sure if I should send this mail to here.
>
> Kinda _not_ what this list is for.
>
> > void start(void)
> > {
> > asm ("movl %esp, 0x5000");
> > }
>
> > My question is how can I get ride of the first two ASM
> > instructions?
>
> Go cheat off of newlib, or libc, or glibc, or netbsd, or freebsd...
>
> > I want the compiler to compile my inlined ASM instruction as the
> > first instruction in the start() function, and the other function
> > just as general output.
>
> Trivial:
>
> void mystart() {
> asm("start:");
> asm("movl %esp, 0x5000");
> }
>
> or learn to code in assembler.
Another option would be to implement the naked function attribute for i386,
or making naked [functions] attribute an attribute that has a default
implementation for all targets.
--
Joern Rennecke | gcc expert for hire
amylaar@onetel.net.uk | send enquiries to: jwr_jobs@onetel.net.uk