DragonFly BSD
DragonFly kernel List (threaded) for 2005-09
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

Re: Different versions of system calls in assembly language

From: joerg@xxxxxxxxxxxxxxxxx
Date: Thu, 29 Sep 2005 14:51:05 +0200
Mail-followup-to: kernel@crater.dragonflybsd.org

On Thu, Sep 29, 2005 at 03:38:03AM +0100, Jonathon McKitrick wrote:
> I'm continuing my foray into assembly language programming, and today I ran
> into a problem calling mmap.  The problem came from the fact that the version
> I was apparently calling (libc?) was expecting an additional 'pad' argument.

What do you want to do? If you generate the complete call directly, e.g.
with int $0x80, you have to be aware of the necessary padding. But that
practise is not recommented, since it makes the programs much less
portable. You can run into problems when a syscall is eliminated and
only emulated in userland, for example.


[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]