Changeset 11456


Ignore:
Timestamp:
Dec 3, 2008, 12:04:41 AM (11 years ago)
Author:
gb
Message:

Use syscall() for read/write/open/close on Linux, so that we can
see if this affects performance. (If the C library's handling
of async cancel points affects performance, there may be other
things - like #_poll - that're also negatively affected, but
if that is the culprit, changing read and write should help.)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/working-0711/ccl/lisp-kernel/unix-calls.c

    r11089 r11456  
    3838lisp_read(int fd, void *buf, size_t count)
    3939{
     40#ifdef LINUX
     41  return syscall(SYS_read,fd,buf,count);
     42#else
    4043  return read(fd,buf,count);
     44#endif
    4145}
    4246
     
    4448lisp_write(int fd, void *buf, size_t count)
    4549{
     50#ifdef LINUX
     51  return syscall(SYS_write,fd,buf,count);
     52#else
    4653  return write(fd,buf,count);
     54#endif
    4755}
    4856
     
    5058lisp_open(char *path, int flags, mode_t mode)
    5159{
     60#ifdef LINUX
     61  return syscall(SYS_open,path,flags,mode);
     62#else
    5263  return open(path,flags,mode);
     64#endif
    5365}
    5466
Note: See TracChangeset for help on using the changeset viewer.