aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--winsup/cygwin/child_info.h10
-rw-r--r--winsup/cygwin/cygerrno.h11
-rw-r--r--winsup/cygwin/cygheap.cc38
-rw-r--r--winsup/cygwin/cygheap.h16
-rw-r--r--winsup/cygwin/cygheap_malloc.h24
-rw-r--r--winsup/cygwin/cygmalloc.h21
-rw-r--r--winsup/cygwin/cygthread.h4
-rw-r--r--winsup/cygwin/cygtls.h22
-rw-r--r--winsup/cygwin/cygwait.h2
-rw-r--r--winsup/cygwin/dcrt0.cc4
-rw-r--r--winsup/cygwin/debug.cc6
-rw-r--r--winsup/cygwin/debug.h10
-rw-r--r--winsup/cygwin/dtable.h4
-rw-r--r--winsup/cygwin/environ.cc10
-rw-r--r--winsup/cygwin/environ.h12
-rw-r--r--winsup/cygwin/errno.cc8
-rw-r--r--winsup/cygwin/exceptions.cc4
-rw-r--r--winsup/cygwin/fhandler.cc14
-rw-r--r--winsup/cygwin/fhandler.h324
-rw-r--r--winsup/cygwin/fhandler_clipboard.cc4
-rw-r--r--winsup/cygwin/fhandler_console.cc14
-rw-r--r--winsup/cygwin/fhandler_cygdrive.cc2
-rw-r--r--winsup/cygwin/fhandler_dev.cc4
-rw-r--r--winsup/cygwin/fhandler_dev_fd.cc2
-rw-r--r--winsup/cygwin/fhandler_disk_file.cc28
-rw-r--r--winsup/cygwin/fhandler_dsp.cc8
-rw-r--r--winsup/cygwin/fhandler_fifo.cc6
-rw-r--r--winsup/cygwin/fhandler_floppy.cc4
-rw-r--r--winsup/cygwin/fhandler_mqueue.cc4
-rw-r--r--winsup/cygwin/fhandler_netdrive.cc2
-rw-r--r--winsup/cygwin/fhandler_pipe.cc8
-rw-r--r--winsup/cygwin/fhandler_proc.cc2
-rw-r--r--winsup/cygwin/fhandler_process.cc2
-rw-r--r--winsup/cygwin/fhandler_process_fd.cc2
-rw-r--r--winsup/cygwin/fhandler_procnet.cc2
-rw-r--r--winsup/cygwin/fhandler_procsys.cc4
-rw-r--r--winsup/cygwin/fhandler_procsysvipc.cc2
-rw-r--r--winsup/cygwin/fhandler_random.cc2
-rw-r--r--winsup/cygwin/fhandler_raw.cc2
-rw-r--r--winsup/cygwin/fhandler_registry.cc2
-rw-r--r--winsup/cygwin/fhandler_serial.cc4
-rw-r--r--winsup/cygwin/fhandler_signalfd.cc4
-rw-r--r--winsup/cygwin/fhandler_socket.cc4
-rw-r--r--winsup/cygwin/fhandler_socket_inet.cc2
-rw-r--r--winsup/cygwin/fhandler_socket_local.cc4
-rw-r--r--winsup/cygwin/fhandler_socket_unix.cc6
-rw-r--r--winsup/cygwin/fhandler_tape.cc6
-rw-r--r--winsup/cygwin/fhandler_timerfd.cc4
-rw-r--r--winsup/cygwin/fhandler_tty.cc12
-rw-r--r--winsup/cygwin/fhandler_virtual.cc4
-rw-r--r--winsup/cygwin/fhandler_windows.cc2
-rw-r--r--winsup/cygwin/fhandler_zero.cc2
-rw-r--r--winsup/cygwin/heap.cc2
-rw-r--r--winsup/cygwin/include/sys/strace.h12
-rw-r--r--winsup/cygwin/miscfuncs.cc4
-rw-r--r--winsup/cygwin/miscfuncs.h14
-rw-r--r--winsup/cygwin/mount.h2
-rw-r--r--winsup/cygwin/ntea.cc4
-rw-r--r--winsup/cygwin/path.cc12
-rw-r--r--winsup/cygwin/path.h20
-rw-r--r--winsup/cygwin/pinfo.cc2
-rw-r--r--winsup/cygwin/pinfo.h16
-rw-r--r--winsup/cygwin/regparm.h19
-rw-r--r--winsup/cygwin/sec_helper.cc2
-rw-r--r--winsup/cygwin/sec_posixacl.cc8
-rw-r--r--winsup/cygwin/security.h34
-rw-r--r--winsup/cygwin/signal.cc8
-rw-r--r--winsup/cygwin/sigproc.cc18
-rw-r--r--winsup/cygwin/sigproc.h26
-rw-r--r--winsup/cygwin/spawn.cc2
-rw-r--r--winsup/cygwin/sync.h10
-rw-r--r--winsup/cygwin/syscalls.cc4
-rw-r--r--winsup/cygwin/tty.cc2
-rw-r--r--winsup/cygwin/tty.h6
-rw-r--r--winsup/cygwin/window.cc4
-rw-r--r--winsup/cygwin/winf.h10
-rw-r--r--winsup/cygwin/wininfo.h4
-rw-r--r--winsup/cygwin/winsup.h19
78 files changed, 473 insertions, 495 deletions
diff --git a/winsup/cygwin/child_info.h b/winsup/cygwin/child_info.h
index 181db8f..8a8ca25 100644
--- a/winsup/cygwin/child_info.h
+++ b/winsup/cygwin/child_info.h
@@ -78,8 +78,8 @@ public:
~child_info ();
void refresh_cygheap () { cygheap_max = ::cygheap_max; }
void ready (bool);
- bool __reg3 sync (int, HANDLE&, DWORD);
- DWORD __reg2 proc_retry (HANDLE);
+ bool sync (int, HANDLE&, DWORD);
+ DWORD proc_retry (HANDLE);
bool isstraced () const {return !!(flag & _CI_STRACED);}
bool iscygwin () const {return !!(flag & _CI_ISCYGWIN);}
bool saw_ctrl_c () const {return !!(flag & _CI_SAW_CTRL_C);}
@@ -117,7 +117,7 @@ public:
// user stack
char filler[4];
child_info_fork ();
- void __reg1 handle_fork ();
+ void handle_fork ();
bool abort (const char *fmt = NULL, ...);
void alloc_stack ();
};
@@ -158,7 +158,7 @@ public:
void reattach_children ();
void *operator new (size_t, void *p) __attribute__ ((nothrow)) {return p;}
void set (child_info_types ci, bool b) { new (this) child_info_spawn (ci, b);}
- void __reg1 handle_spawn ();
+ void handle_spawn ();
void set_sem (HANDLE _sem)
{
/* Don't leak semaphore handle into exec'ed process. */
@@ -193,7 +193,7 @@ public:
bool get_parent_handle ();
bool has_execed_cygwin () const { return iscygwin () && has_execed (); }
operator HANDLE& () {return hExeced;}
- int __reg3 worker (const char *, const char *const *, const char *const [],
+ int worker (const char *, const char *const *, const char *const [],
int, int = -1, int = -1);
};
diff --git a/winsup/cygwin/cygerrno.h b/winsup/cygwin/cygerrno.h
index 009ae63..b982bc2 100644
--- a/winsup/cygwin/cygerrno.h
+++ b/winsup/cygwin/cygerrno.h
@@ -9,7 +9,6 @@ details. */
#ifndef _CYGERRNO_H
#define _CYGERRNO_H
#include <errno.h>
-#include "regparm.h"
struct errmap_t
{
@@ -18,10 +17,10 @@ struct errmap_t
int e; /* errno version of error */
};
-void __reg3 seterrno_from_win_error (const char *file, int line, DWORD code);
-void __reg3 seterrno_from_nt_status (const char *file, int line, NTSTATUS status);
-int __reg2 geterrno_from_win_error (DWORD code = GetLastError (), int deferrno = 13 /*EACCESS*/);
-int __reg2 geterrno_from_nt_status (NTSTATUS status, int deferrno = 13 /*EACCESS*/);
+void seterrno_from_win_error (const char *file, int line, DWORD code);
+void seterrno_from_nt_status (const char *file, int line, NTSTATUS status);
+int geterrno_from_win_error (DWORD code = GetLastError (), int deferrno = 13 /*EACCESS*/);
+int geterrno_from_nt_status (NTSTATUS status, int deferrno = 13 /*EACCESS*/);
inline void __attribute__ ((always_inline))
seterrno (const char *file, int line)
@@ -42,7 +41,7 @@ __set_errno (const char *fn, int ln, int val)
#define set_errno(val) __set_errno (__PRETTY_FUNCTION__, __LINE__, (val))
int find_winsock_errno (DWORD why);
-void __reg2 __set_winsock_errno (const char *fn, int ln);
+void __set_winsock_errno (const char *fn, int ln);
#define set_winsock_errno() __set_winsock_errno (__FUNCTION__, __LINE__)
#define get_errno() (errno)
diff --git a/winsup/cygwin/cygheap.cc b/winsup/cygwin/cygheap.cc
index b72bc5a..dbd03a0 100644
--- a/winsup/cygwin/cygheap.cc
+++ b/winsup/cygwin/cygheap.cc
@@ -68,7 +68,7 @@ static NO_COPY uint32_t nthreads;
#define MVMAP_OPTIONS (FILE_MAP_WRITE)
extern "C" {
-static void __reg1 _cfree (void *);
+static void _cfree (void *);
static void *__stdcall _csbrk (int);
}
@@ -331,10 +331,10 @@ _csbrk (int sbs)
/* Copyright (C) 1997, 2000 DJ Delorie */
-static void *__reg1 _cmalloc (unsigned size);
-static void *__reg2 _crealloc (void *ptr, unsigned size);
+static void *_cmalloc (unsigned size);
+static void *_crealloc (void *ptr, unsigned size);
-static void *__reg1
+static void *
_cmalloc (unsigned size)
{
_cmalloc_entry *rvc;
@@ -371,7 +371,7 @@ _cmalloc (unsigned size)
return rvc->data;
}
-static void __reg1
+static void
_cfree (void *ptr)
{
cygheap_protect.acquire ();
@@ -382,7 +382,7 @@ _cfree (void *ptr)
cygheap_protect.release ();
}
-static void *__reg2
+static void *
_crealloc (void *ptr, unsigned size)
{
void *newptr;
@@ -461,26 +461,26 @@ crealloc (void *s, size_t n, const char *fn)
return creturn (t, c, n, fn);
}
-extern "C" void *__reg2
+extern "C" void *
crealloc (void *s, size_t n)
{
return crealloc (s, n, NULL);
}
-extern "C" void *__reg2
+extern "C" void *
crealloc_abort (void *s, size_t n)
{
return crealloc (s, n, "crealloc");
}
-extern "C" void __reg1
+extern "C" void
cfree (void *s)
{
assert (!inheap (s));
_cfree (tocygheap (s));
}
-extern "C" void __reg2
+extern "C" void
cfree_and_set (char *&s, char *what)
{
if (s && s != almost_null)
@@ -499,19 +499,19 @@ ccalloc (cygheap_types x, size_t n, size_t size, const char *fn)
return creturn (x, c, n, fn);
}
-extern "C" void *__reg3
+extern "C" void *
ccalloc (cygheap_types x, size_t n, size_t size)
{
return ccalloc (x, n, size, NULL);
}
-extern "C" void *__reg3
+extern "C" void *
ccalloc_abort (cygheap_types x, size_t n, size_t size)
{
return ccalloc (x, n, size, "ccalloc");
}
-extern "C" PWCHAR __reg1
+extern "C" PWCHAR
cwcsdup (PCWSTR s)
{
PWCHAR p = (PWCHAR) cmalloc (HEAP_STR, (wcslen (s) + 1) * sizeof (WCHAR));
@@ -521,7 +521,7 @@ cwcsdup (PCWSTR s)
return p;
}
-extern "C" PWCHAR __reg1
+extern "C" PWCHAR
cwcsdup1 (PCWSTR s)
{
PWCHAR p = (PWCHAR) cmalloc (HEAP_1_STR, (wcslen (s) + 1) * sizeof (WCHAR));
@@ -531,7 +531,7 @@ cwcsdup1 (PCWSTR s)
return p;
}
-extern "C" char *__reg1
+extern "C" char *
cstrdup (const char *s)
{
char *p = (char *) cmalloc (HEAP_STR, strlen (s) + 1);
@@ -541,7 +541,7 @@ cstrdup (const char *s)
return p;
}
-extern "C" char *__reg1
+extern "C" char *
cstrdup1 (const char *s)
{
char *p = (char *) cmalloc (HEAP_1_STR, strlen (s) + 1);
@@ -660,7 +660,7 @@ init_cygheap::add_tls (_cygtls *t)
++nthreads;
}
-HANDLE __reg3
+HANDLE
init_cygheap::remove_tls (_cygtls *t)
{
HANDLE mutex = NULL;
@@ -684,7 +684,7 @@ init_cygheap::remove_tls (_cygtls *t)
return mutex;
}
-threadlist_t __reg2 *
+threadlist_t *
init_cygheap::find_tls (_cygtls *tls)
{
tls_sentry here (INFINITE);
@@ -709,7 +709,7 @@ init_cygheap::find_tls (_cygtls *tls)
return t;
}
-threadlist_t __reg3 *
+threadlist_t *
init_cygheap::find_tls (int sig, bool& issig_wait)
{
debug_printf ("sig %d\n", sig);
diff --git a/winsup/cygwin/cygheap.h b/winsup/cygwin/cygheap.h
index 0bca899..528c61e 100644
--- a/winsup/cygwin/cygheap.h
+++ b/winsup/cygwin/cygheap.h
@@ -191,7 +191,7 @@ public:
return effec_cygsid.string (buf);
}
- const char __reg3 *test_uid (char *&, const char *, size_t);
+ const char *test_uid (char *&, const char *, size_t);
};
/* cwd cache stuff. */
@@ -350,8 +350,8 @@ struct user_heap_info
void *top;
void *max;
SIZE_T chunk;
- void __reg2 *sbrk (ptrdiff_t);
- void __reg1 init ();
+ void *sbrk (ptrdiff_t);
+ void init ();
};
class cygheap_domain_info
@@ -585,11 +585,11 @@ struct init_cygheap: public mini_cygheap
hook_chain hooks;
void close_ctty ();
void init_installation_root ();
- void __reg1 init_tls_list ();;
- void __reg2 add_tls (_cygtls *);
- HANDLE __reg3 remove_tls (_cygtls *);
- threadlist_t __reg2 *find_tls (_cygtls *);
- threadlist_t __reg3 *find_tls (int, bool&);
+ void init_tls_list ();;
+ void add_tls (_cygtls *);
+ HANDLE remove_tls (_cygtls *);
+ threadlist_t *find_tls (_cygtls *);
+ threadlist_t *find_tls (int, bool&);
sigset_t compute_sigblkmask ();
void unlock_tls (threadlist_t *t) { if (t) ReleaseMutex (t->mutex); }
};
diff --git a/winsup/cygwin/cygheap_malloc.h b/winsup/cygwin/cygheap_malloc.h
index 74f0bb6..6950e82 100644
--- a/winsup/cygwin/cygheap_malloc.h
+++ b/winsup/cygwin/cygheap_malloc.h
@@ -38,18 +38,18 @@ enum cygheap_types
};
extern "C" {
-void __reg1 cfree (void *);
-void *__reg2 cmalloc (cygheap_types, size_t);
-void *__reg2 crealloc (void *, size_t);
-void *__reg3 ccalloc (cygheap_types, size_t, size_t);
-void *__reg2 cmalloc_abort (cygheap_types, size_t);
-void *__reg2 crealloc_abort (void *, size_t);
-void *__reg3 ccalloc_abort (cygheap_types, size_t, size_t);
-PWCHAR __reg1 cwcsdup (PCWSTR);
-PWCHAR __reg1 cwcsdup1 (PCWSTR);
-char *__reg1 cstrdup (const char *);
-char *__reg1 cstrdup1 (const char *);
-void __reg2 cfree_and_set (char *&, char * = NULL);
+void cfree (void *);
+void *cmalloc (cygheap_types, size_t);
+void *crealloc (void *, size_t);
+void *ccalloc (cygheap_types, size_t, size_t);
+void *cmalloc_abort (cygheap_types, size_t);
+void *crealloc_abort (void *, size_t);
+void *ccalloc_abort (cygheap_types, size_t, size_t);
+PWCHAR cwcsdup (PCWSTR);
+PWCHAR cwcsdup1 (PCWSTR);
+char *cstrdup (const char *);
+char *cstrdup1 (const char *);
+void cfree_and_set (char *&, char * = NULL);
}
#endif /*_CYGHEAP_MALLOC_H*/
diff --git a/winsup/cygwin/cygmalloc.h b/winsup/cygwin/cygmalloc.h
index a6033c1..9095f9b 100644
--- a/winsup/cygwin/cygmalloc.h
+++ b/winsup/cygwin/cygmalloc.h
@@ -9,17 +9,16 @@ details. */
#ifdef __cplusplus
extern "C" {
#endif
-#include "regparm.h"
-
-void __reg1 dlfree (void *p);
-void __reg1 *dlmalloc (size_t size);
-void __reg2 *dlrealloc (void *p, size_t size);
-void __reg2 *dlcalloc (size_t nmemb, size_t size);
-void __reg2 *dlmemalign (size_t alignment, size_t bytes);
-void __reg1 *dlvalloc (size_t bytes);
-size_t __reg1 dlmalloc_usable_size (void *p);
-int __reg1 dlmalloc_trim (size_t);
-int __reg2 dlmallopt (int p, int v);
+
+void dlfree (void *p);
+void *dlmalloc (size_t size);
+void *dlrealloc (void *p, size_t size);
+void *dlcalloc (size_t nmemb, size_t size);
+void *dlmemalign (size_t alignment, size_t bytes);
+void *dlvalloc (size_t bytes);
+size_t dlmalloc_usable_size (void *p);
+int dlmalloc_trim (size_t);
+int dlmallopt (int p, int v);
void dlmalloc_stats ();
#ifdef __x86_64__
diff --git a/winsup/cygwin/cygthread.h b/winsup/cygwin/cygthread.h
index f3b0bf0..ed57c93 100644
--- a/winsup/cygwin/cygthread.h
+++ b/winsup/cygwin/cygthread.h
@@ -28,7 +28,7 @@ class cygthread
bool is_freerange;
static bool exiting;
HANDLE notify_detached;
- void __reg1 create ();
+ void create ();
static void CALLBACK async_create (ULONG_PTR);
public:
bool terminate_thread ();
@@ -36,7 +36,7 @@ class cygthread
static DWORD WINAPI simplestub (VOID *);
static DWORD main_thread_id;
static const char *name (DWORD = 0);
- void __reg2 callfunc (bool) __attribute__ ((noinline, ));
+ void callfunc (bool) __attribute__ ((noinline, ));
void auto_release () {func = NULL;}
void release (bool);
cygthread (LPTHREAD_START_ROUTINE start, unsigned n, LPVOID param, const char *name, HANDLE notify = NULL)
diff --git a/winsup/cygwin/cygtls.h b/winsup/cygwin/cygtls.h
index bfd3582..d2230a4 100644
--- a/winsup/cygwin/cygtls.h
+++ b/winsup/cygwin/cygtls.h
@@ -203,27 +203,27 @@ public: /* Do NOT remove this public: line, it's a marker for gentls_offsets. */
static void call (DWORD (*) (void *, void *), void *);
void remove (DWORD);
void push (__tlsstack_t addr) {*stackptr++ = (__tlsstack_t) addr;}
- __tlsstack_t __reg1 pop ();
+ __tlsstack_t pop ();
__tlsstack_t retaddr () {return stackptr[-1];}
bool isinitialized () const
{
return initialized == CYGTLS_INITIALIZED;
}
- bool __reg3 interrupt_now (CONTEXT *, siginfo_t&, void *, struct sigaction&);
- void __reg3 interrupt_setup (siginfo_t&, void *, struct sigaction&);
+ bool interrupt_now (CONTEXT *, siginfo_t&, void *, struct sigaction&);
+ void interrupt_setup (siginfo_t&, void *, struct sigaction&);
bool inside_kernel (CONTEXT *);
- void __reg2 signal_debugger (siginfo_t&);
+ void signal_debugger (siginfo_t&);
#ifdef CYGTLS_HANDLE
operator HANDLE () const {return tid ? tid->win32_obj_id : NULL;}
#endif
- int __reg1 call_signal_handler ();
- void __reg1 remove_wq (DWORD);
- void __reg1 fixup_after_fork ();
- void __reg1 lock ();
- void __reg1 unlock ();
- bool __reg1 locked ();
+ int call_signal_handler ();
+ void remove_wq (DWORD);
+ void fixup_after_fork ();
+ void lock ();
+ void unlock ();
+ bool locked ();
HANDLE get_signal_arrived (bool wait_for_lock = true)
{
if (!signal_arrived)
@@ -263,7 +263,7 @@ public: /* Do NOT remove this public: line, it's a marker for gentls_offsets. */
void handle_SIGCONT ();
static void cleanup_early(struct _reent *);
private:
- void __reg3 call2 (DWORD (*) (void *, void *), void *, void *);
+ void call2 (DWORD (*) (void *, void *), void *, void *);
void remove_pending_sigs ();
};
#pragma pack(pop)
diff --git a/winsup/cygwin/cygwait.h b/winsup/cygwin/cygwait.h
index b4270a9..6212c33 100644
--- a/winsup/cygwin/cygwait.h
+++ b/winsup/cygwin/cygwait.h
@@ -27,7 +27,7 @@ extern LARGE_INTEGER cw_nowait_storage;
const unsigned cw_std_mask = cw_cancel | cw_cancel_self | cw_sig;
-DWORD __reg3 cygwait (HANDLE, PLARGE_INTEGER timeout,
+DWORD cygwait (HANDLE, PLARGE_INTEGER timeout,
unsigned = cw_std_mask);
extern inline DWORD __attribute__ ((always_inline))
diff --git a/winsup/cygwin/dcrt0.cc b/winsup/cygwin/dcrt0.cc
index 17d3b66..5fb34d7 100644
--- a/winsup/cygwin/dcrt0.cc
+++ b/winsup/cygwin/dcrt0.cc
@@ -1137,7 +1137,7 @@ __main (void)
sig_dispatch_pending (true);
}
-void __reg1
+void
do_exit (int status)
{
syscall_printf ("do_exit (%d), exit_state %d", status, exit_state);
@@ -1332,7 +1332,7 @@ are unable to find another cygwin DLL.",
}
#ifdef DEBUGGING
-void __reg1
+void
cygbench (const char *s)
{
if (GetEnvironmentVariableA ("CYGWIN_BENCH", NULL, 0))
diff --git a/winsup/cygwin/debug.cc b/winsup/cygwin/debug.cc
index fc2fed4..f21a8c5 100644
--- a/winsup/cygwin/debug.cc
+++ b/winsup/cygwin/debug.cc
@@ -99,7 +99,7 @@ newh ()
return NULL;
}
-void __reg3
+void
modify_handle (const char *func, int ln, HANDLE h, const char *name, bool inh)
{
lock_debug here;
@@ -115,7 +115,7 @@ modify_handle (const char *func, int ln, HANDLE h, const char *name, bool inh)
}
/* Add a handle to the linked list of known handles. */
-void __reg3
+void
add_handle (const char *func, int ln, HANDLE h, const char *name, bool inh)
{
handle_list *hl;
@@ -209,7 +209,7 @@ mark_closed (const char *func, int ln, HANDLE h, const char *name, bool force)
/* Close a known handle. Complain if !force and closing a known handle or
if the name of the handle being closed does not match the registered name. */
-bool __reg3
+bool
close_handle (const char *func, int ln, HANDLE h, const char *name, bool force)
{
bool ret;
diff --git a/winsup/cygwin/debug.h b/winsup/cygwin/debug.h
index d3f7ea3..0fcfa13 100644
--- a/winsup/cygwin/debug.h
+++ b/winsup/cygwin/debug.h
@@ -53,12 +53,12 @@ details. */
# define VerifyHandle(h) verify_handle (__PRETTY_FUNCTION__, __LINE__, (h))
void debug_init ();
-void __reg3 add_handle (const char *, int, HANDLE, const char *, bool = false);
-void __reg3 verify_handle (const char *, int, HANDLE);
-bool __reg3 close_handle (const char *, int, HANDLE, const char *, bool);
+void add_handle (const char *, int, HANDLE, const char *, bool = false);
+void verify_handle (const char *, int, HANDLE);
+bool close_handle (const char *, int, HANDLE, const char *, bool);
extern "C" void console_printf (const char *fmt,...);
-void __reg1 cygbench (const char *s);
-void __reg3 modify_handle (const char *, int, HANDLE, const char *, bool);
+void cygbench (const char *s);
+void modify_handle (const char *, int, HANDLE, const char *, bool);
void setclexec (HANDLE, HANDLE, bool);
void debug_fixup_after_fork_exec ();
diff --git a/winsup/cygwin/dtable.h b/winsup/cygwin/dtable.h
index e1a8461..7803fae 100644
--- a/winsup/cygwin/dtable.h
+++ b/winsup/cygwin/dtable.h
@@ -44,7 +44,7 @@ public:
void vfork_parent_restore ();
void vfork_child_fixup ();
fhandler_base *dup_worker (fhandler_base *oldfh, int flags);
- int extend (size_t, size_t) __reg3;
+ int extend (size_t, size_t);
void fixup_after_fork (HANDLE);
void fixup_close (size_t, fhandler_base *);
@@ -57,7 +57,7 @@ public:
}
int find_unused_handle (size_t start);
int find_unused_handle () { return find_unused_handle (first_fd_for_open);}
- void __reg2 release (int fd);
+ void release (int fd);
void init_std_file_from_handle (int fd, HANDLE handle);
int dup3 (int oldfd, int newfd, int flags);
void fixup_after_exec ();
diff --git a/winsup/cygwin/environ.cc b/winsup/cygwin/environ.cc
index 03f8277..99b220d 100644
--- a/winsup/cygwin/environ.cc
+++ b/winsup/cygwin/environ.cc
@@ -411,7 +411,7 @@ win_env::add_cache (const char *in_posix, const char *in_native)
to the beginning of the environment variable name. *in_posix is any
known posix value for the environment variable. Returns a pointer to
the appropriate conversion structure. */
-win_env * __reg3
+win_env *
getwinenv (const char *env, const char *in_posix, win_env *temp)
{
if (!match_first_char (env, WC))
@@ -863,7 +863,7 @@ environ_init (char **envp, int envc)
int sawTERM = 0;
-char ** __reg2
+char **
win32env_to_cygenv (PWCHAR rawenv, bool posify)
{
tmp_pathbuf tp;
@@ -921,7 +921,7 @@ env_sort (const void *a, const void *b)
return strcmp (*p, *q);
}
-char * __reg3
+char *
getwinenveq (const char *name, size_t namelen, int x)
{
WCHAR name0[namelen - 1];
@@ -956,7 +956,7 @@ struct spenv
bool add_if_exists; /* if true, retrieve value from cache */
const char * (cygheap_user::*from_cygheap) (const char *, size_t);
- char __reg3 *retrieve (bool, const char * const = NULL);
+ char *retrieve (bool, const char * const = NULL);
};
#define env_dontadd almost_null
@@ -1056,7 +1056,7 @@ env_compare (const void *key, const void *memb)
child_info_spawn::worker. If so, we're also fetching the Windows default
environment for the new user, and merge it into the environment we propage
to the child. */
-char ** __reg3
+char **
build_env (const char * const *envp, PWCHAR &envblock, int &envc,
bool no_envblock, HANDLE new_token)
{
diff --git a/winsup/cygwin/environ.h b/winsup/cygwin/environ.h
index 269591a..fc34f1e 100644
--- a/winsup/cygwin/environ.h
+++ b/winsup/cygwin/environ.h
@@ -7,7 +7,7 @@ Cygwin license. Please consult the file "CYGWIN_LICENSE" for
details. */
/* Initialize the environment */
-void __reg2 environ_init (char **, int);
+void environ_init (char **, int);
/* The structure below is used to control conversion to/from posix-style
file specs. Currently, only PATH and HOME are converted, but PATH
@@ -22,7 +22,7 @@ struct win_env
ssize_t (*toposix) (const void *, void *, size_t);
ssize_t (*towin32) (const void *, void *, size_t);
bool immediate;
- void __reg3 add_cache (const char *in_posix, const char *in_native = NULL);
+ void add_cache (const char *in_posix, const char *in_native = NULL);
const char * get_native () const {return native ? native + namelen : NULL;}
const char * get_posix () const {return posix ? posix : NULL;}
struct win_env& operator = (struct win_env& x);
@@ -30,8 +30,8 @@ struct win_env
~win_env ();
};
-win_env * __reg3 getwinenv (const char *name, const char *posix = NULL, win_env * = NULL);
-char * __reg3 getwinenveq (const char *name, size_t len, int);
+win_env *getwinenv (const char *name, const char *posix = NULL, win_env * = NULL);
+char *getwinenveq (const char *name, size_t len, int);
#ifdef __x86_64__
#define update_envptrs()
@@ -42,9 +42,9 @@ void __stdcall update_envptrs ();
extern "C" char **__cygwin_environ, ***main_environ;
extern "C" char __stdcall **cur_environ ();
#endif
-char ** __reg3 build_env (const char * const *envp, PWCHAR &envblock,
+char **build_env (const char * const *envp, PWCHAR &envblock,
int &envc, bool need_envblock, HANDLE new_token);
-char ** __reg2 win32env_to_cygenv (PWCHAR rawenv, bool posify);
+char **win32env_to_cygenv (PWCHAR rawenv, bool posify);
#define ENV_CVT -1
diff --git a/winsup/cygwin/errno.cc b/winsup/cygwin/errno.cc
index 55219cc..f200e5b 100644
--- a/winsup/cygwin/errno.cc
+++ b/winsup/cygwin/errno.cc
@@ -314,7 +314,7 @@ const char *_sys_errlist[] =
int NO_COPY_INIT _sys_nerr = sizeof (_sys_errlist) / sizeof (_sys_errlist[0]);
};
-int __reg2
+int
geterrno_from_win_error (DWORD code, int deferrno)
{
for (int i = 0; errmap[i].w != 0; ++i)
@@ -331,14 +331,14 @@ geterrno_from_win_error (DWORD code, int deferrno)
/* seterrno_from_win_error: Given a Windows error code, set errno
as appropriate. */
-void __reg3
+void
seterrno_from_win_error (const char *file, int line, DWORD code)
{
syscall_printf ("%s:%d windows error %u", file, line, code);
errno = _impure_ptr->_errno = geterrno_from_win_error (code, EACCES);
}
-int __reg2
+int
geterrno_from_nt_status (NTSTATUS status, int deferrno)
{
return geterrno_from_win_error (RtlNtStatusToDosError (status));
@@ -346,7 +346,7 @@ geterrno_from_nt_status (NTSTATUS status, int deferrno)
/* seterrno_from_nt_status: Given a NT status code, set errno
as appropriate. */
-void __reg3
+void
seterrno_from_nt_status (const char *file, int line, NTSTATUS status)
{
DWORD code = RtlNtStatusToDosError (status);
diff --git a/winsup/cygwin/exceptions.cc b/winsup/cygwin/exceptions.cc
index 2fecd52..b8d4650 100644
--- a/winsup/cygwin/exceptions.cc
+++ b/winsup/cygwin/exceptions.cc
@@ -840,7 +840,7 @@ _cygtls::interrupt_now (CONTEXT *cx, siginfo_t& si, void *handler,
return interrupted;
}
-void __reg3
+void
_cygtls::interrupt_setup (siginfo_t& si, void *handler, struct sigaction& siga)
{
push ((__tlsstack_t) sigdelayed);
@@ -1323,7 +1323,7 @@ _cygtls::handle_SIGCONT ()
sig_clear (SIGTTOU);
}
-int __reg1
+int
sigpacket::process ()
{
int rc = 1;
diff --git a/winsup/cygwin/fhandler.cc b/winsup/cygwin/fhandler.cc
index 4fce012..8850735 100644
--- a/winsup/cygwin/fhandler.cc
+++ b/winsup/cygwin/fhandler.cc
@@ -189,7 +189,7 @@ fhandler_base::set_flags (int flags, int supplied_bin)
/* Cover function to ReadFile to achieve (as much as possible) Posix style
semantics and use of errno. */
-void __reg3
+void
fhandler_base::raw_read (void *ptr, size_t& len)
{
NTSTATUS status;
@@ -256,7 +256,7 @@ retry:
/* Cover function to WriteFile to provide Posix interface and semantics
(as much as possible). */
-ssize_t __reg3
+ssize_t
fhandler_base::raw_write (const void *ptr, size_t len)
{
NTSTATUS status;
@@ -812,7 +812,7 @@ fhandler_base::open_setup (int)
an \n. If last char is an \r, look ahead one more char, if \n then
modify \r, if not, remember char.
*/
-void __reg3
+void
fhandler_base::read (void *in_ptr, size_t& len)
{
char *ptr = (char *) in_ptr;
@@ -1145,14 +1145,14 @@ fhandler_base::lseek (off_t offset, int whence)
return res;
}
-ssize_t __reg3
+ssize_t
fhandler_base::pread (void *, size_t, off_t, void *)
{
set_errno (ESPIPE);
return -1;
}
-ssize_t __reg3
+ssize_t
fhandler_base::pwrite (void *, size_t, off_t, void *)
{
set_errno (ESPIPE);
@@ -1250,7 +1250,7 @@ fhandler_base::ioctl (unsigned int cmd, void *buf)
return res;
}
-int __reg2
+int
fhandler_base::fstat (struct stat *buf)
{
if (is_fs_special ())
@@ -1288,7 +1288,7 @@ fhandler_base::fstat (struct stat *buf)
return 0;
}
-int __reg2
+int
fhandler_base::fstatvfs (struct statvfs *sfs)
{
/* If we hit this base implementation, it's some device in /dev.
diff --git a/winsup/cygwin/fhandler.h b/winsup/cygwin/fhandler.h
index 36f6481..a2a4ec1 100644
--- a/winsup/cygwin/fhandler.h
+++ b/winsup/cygwin/fhandler.h
@@ -376,39 +376,39 @@ class fhandler_base
int open_fs (int, mode_t = 0);
# define archetype_usecount(n) _archetype_usecount (__PRETTY_FUNCTION__, __LINE__, (n))
int close_fs () { return fhandler_base::close (); }
- virtual int __reg2 fstat (struct stat *buf);
- void __reg2 stat_fixup (struct stat *buf);
- int __reg2 fstat_fs (struct stat *buf);
+ virtual int fstat (struct stat *buf);
+ void stat_fixup (struct stat *buf);
+ int fstat_fs (struct stat *buf);
private:
- int __reg2 fstat_helper (struct stat *buf);
- int __reg2 fstat_by_nfs_ea (struct stat *buf);
- int __reg2 fstat_by_handle (struct stat *buf);
- int __reg2 fstat_by_name (struct stat *buf);
+ int fstat_helper (struct stat *buf);
+ int fstat_by_nfs_ea (struct stat *buf);
+ int fstat_by_handle (struct stat *buf);
+ int fstat_by_name (struct stat *buf);
public:
- virtual int __reg2 fstatvfs (struct statvfs *buf);
- int __reg2 fstatvfs_by_handle (HANDLE h, struct statvfs *buf);
- int __reg2 utimens_fs (const struct timespec *);
- virtual int __reg1 fchmod (mode_t mode);
- virtual int __reg2 fchown (uid_t uid, gid_t gid);
- virtual int __reg3 facl (int, int, struct acl *);
- virtual struct __acl_t * __reg2 acl_get (uint32_t);
- virtual int __reg3 acl_set (struct __acl_t *, uint32_t);
- virtual ssize_t __reg3 fgetxattr (const char *, void *, size_t);
- virtual int __reg3 fsetxattr (const char *, const void *, size_t, int);
- virtual int __reg3 fadvise (off_t, off_t, int);
- virtual int __reg3 ftruncate (off_t, bool);
- virtual int __reg2 link (const char *);
- virtual int __reg2 utimens (const struct timespec *);
- virtual int __reg1 fsync ();
+ virtual int fstatvfs (struct statvfs *buf);
+ int fstatvfs_by_handle (HANDLE h, struct statvfs *buf);
+ int utimens_fs (const struct timespec *);
+ virtual int fchmod (mode_t mode);
+ virtual int fchown (uid_t uid, gid_t gid);
+ virtual int facl (int, int, struct acl *);
+ virtual struct __acl_t *acl_get (uint32_t);
+ virtual int acl_set (struct __acl_t *, uint32_t);
+ virtual ssize_t fgetxattr (const char *, void *, size_t);
+ virtual int fsetxattr (const char *, const void *, size_t, int);
+ virtual int fadvise (off_t, off_t, int);
+ virtual int ftruncate (off_t, bool);
+ virtual int link (const char *);
+ virtual int utimens (const struct timespec *);
+ virtual int fsync ();
virtual int ioctl (unsigned int cmd, void *);
virtual int fcntl (int cmd, intptr_t);
virtual char const *ttyname () { return get_name (); }
- virtual void __reg3 read (void *ptr, size_t& len);
+ virtual void read (void *ptr, size_t& len);
virtual ssize_t __stdcall write (const void *ptr, size_t len);
virtual ssize_t __stdcall readv (const struct iovec *, int iovcnt, ssize_t tot = -1);
virtual ssize_t __stdcall writev (const struct iovec *, int iovcnt, ssize_t tot = -1);
- virtual ssize_t __reg3 pread (void *, size_t, off_t, void *aio = NULL);
- virtual ssize_t __reg3 pwrite (void *, size_t, off_t, void *aio = NULL);
+ virtual ssize_t pread (void *, size_t, off_t, void *aio = NULL);
+ virtual ssize_t pwrite (void *, size_t, off_t, void *aio = NULL);
virtual off_t lseek (off_t offset, int whence);
virtual int lock (int, struct flock *);
virtual int mand_lock (int, struct flock *);
@@ -453,8 +453,8 @@ public:
virtual class fhandler_mqueue *is_mqueue () { return NULL; }
virtual int is_windows () {return 0; }
- virtual void __reg3 raw_read (void *ptr, size_t& ulen);
- virtual ssize_t __reg3 raw_write (const void *ptr, size_t ulen);
+ virtual void raw_read (void *ptr, size_t& ulen);
+ virtual ssize_t raw_write (const void *ptr, size_t ulen);
/* Virtual accessor functions to hide the fact
that some fd's have two handles. */
@@ -482,16 +482,16 @@ public:
virtual void set_eof () {}
virtual int mkdir (mode_t mode);
virtual int rmdir ();
- virtual __reg2 DIR *opendir (int fd);
- virtual __reg3 int readdir (DIR *, dirent *);
+ virtual DIR *opendir (int fd);
+ virtual int readdir (DIR *, dirent *);
virtual long telldir (DIR *);
virtual void seekdir (DIR *, long);
virtual void rewinddir (DIR *);
virtual int closedir (DIR *);
bool is_fs_special () {return pc.is_fs_special ();}
bool issymlink () {return pc.issymlink ();}
- bool __reg2 device_access_denied (int);
- int __reg3 fhaccess (int flags, bool);
+ bool device_access_denied (int);
+ int fhaccess (int flags, bool);
fhandler_base (void *) {}
@@ -592,7 +592,7 @@ class fhandler_socket: public fhandler_base
virtual ssize_t recvfrom (void *ptr, size_t len, int flags,
struct sockaddr *from, int *fromlen) = 0;
virtual ssize_t recvmsg (struct msghdr *msg, int flags) = 0;
- virtual void __reg3 read (void *ptr, size_t& len) = 0;
+ virtual void read (void *ptr, size_t& len) = 0;
virtual ssize_t __stdcall readv (const struct iovec *, int iovcnt,
ssize_t tot = -1) = 0;
@@ -610,12 +610,12 @@ class fhandler_socket: public fhandler_base
virtual int fcntl (int cmd, intptr_t);
int open (int flags, mode_t mode = 0);
- int __reg2 fstat (struct stat *buf);
- int __reg2 fstatvfs (struct statvfs *buf);
- int __reg1 fchmod (mode_t newmode);
- int __reg2 fchown (uid_t newuid, gid_t newgid);
- int __reg3 facl (int, int, struct acl *);
- int __reg2 link (const char *);
+ int fstat (struct stat *buf);
+ int fstatvfs (struct statvfs *buf);
+ int fchmod (mode_t newmode);
+ int fchown (uid_t newuid, gid_t newgid);
+ int facl (int, int, struct acl *);
+ int link (const char *);
off_t lseek (off_t, int)
{
set_errno (ESPIPE);
@@ -711,7 +711,7 @@ class fhandler_socket_wsock: public fhandler_socket
ssize_t recvfrom (void *ptr, size_t len, int flags,
struct sockaddr *from, int *fromlen);
ssize_t recvmsg (struct msghdr *msg, int flags);
- void __reg3 read (void *ptr, size_t& len);
+ void read (void *ptr, size_t& len);
ssize_t __stdcall readv (const struct iovec *, int iovcnt, ssize_t tot = -1);
ssize_t __stdcall write (const void *ptr, size_t len);
ssize_t __stdcall writev (const struct iovec *, int iovcnt, ssize_t tot = -1);
@@ -856,12 +856,12 @@ class fhandler_socket_local: public fhandler_socket_wsock
int open (int flags, mode_t mode = 0);
int close ();
int fcntl (int cmd, intptr_t);
- int __reg2 fstat (struct stat *buf);
- int __reg2 fstatvfs (struct statvfs *buf);
- int __reg1 fchmod (mode_t newmode);
- int __reg2 fchown (uid_t newuid, gid_t newgid);
- int __reg3 facl (int, int, struct acl *);
- int __reg2 link (const char *);
+ int fstat (struct stat *buf);
+ int fstatvfs (struct statvfs *buf);
+ int fchmod (mode_t newmode);
+ int fchown (uid_t newuid, gid_t newgid);
+ int facl (int, int, struct acl *);
+ int link (const char *);
/* from here on: CLONING */
fhandler_socket_local (void *) {}
@@ -1120,7 +1120,7 @@ class fhandler_socket_unix : public fhandler_socket
ssize_t recvmsg (struct msghdr *msg, int flags);
ssize_t recvfrom (void *ptr, size_t len, int flags,
struct sockaddr *from, int *fromlen);
- void __reg3 read (void *ptr, size_t& len);
+ void read (void *ptr, size_t& len);
ssize_t __stdcall readv (const struct iovec *const iov, int iovcnt,
ssize_t tot = -1);
@@ -1138,12 +1138,12 @@ class fhandler_socket_unix : public fhandler_socket
virtual int ioctl (unsigned int cmd, void *);
virtual int fcntl (int cmd, intptr_t);
- int __reg2 fstat (struct stat *buf);
- int __reg2 fstatvfs (struct statvfs *buf);
- int __reg1 fchmod (mode_t newmode);
- int __reg2 fchown (uid_t newuid, gid_t newgid);
- int __reg3 facl (int, int, struct acl *);
- int __reg2 link (const char *);
+ int fstat (struct stat *buf);
+ int fstatvfs (struct statvfs *buf);
+ int fchmod (mode_t newmode);
+ int fchown (uid_t newuid, gid_t newgid);
+ int facl (int, int, struct acl *);
+ int link (const char *);
/* select.cc */
select_record *select_read (select_stuff *);
@@ -1182,7 +1182,7 @@ class fhandler_pipe_fifo: public fhandler_base
fhandler_pipe_fifo ();
virtual bool reader_closed () { return false; };
- ssize_t __reg3 raw_write (const void *ptr, size_t len);
+ ssize_t raw_write (const void *ptr, size_t len);
};
class fhandler_pipe: public fhandler_pipe_fifo
@@ -1220,13 +1220,13 @@ public:
int dup (fhandler_base *child, int);
void set_close_on_exec (bool val);
int close ();
- void __reg3 raw_read (void *ptr, size_t& len);
+ void raw_read (void *ptr, size_t& len);
int ioctl (unsigned int cmd, void *);
int fcntl (int cmd, intptr_t);
- int __reg2 fstat (struct stat *buf);
- int __reg2 fstatvfs (struct statvfs *buf);
- int __reg3 fadvise (off_t, off_t, int);
- int __reg3 ftruncate (off_t, bool);
+ int fstat (struct stat *buf);
+ int fstatvfs (struct statvfs *buf);
+ int fadvise (off_t, off_t, int);
+ int ftruncate (off_t, bool);
int init (HANDLE, DWORD, mode_t, int64_t);
static int create (fhandler_pipe *[2], unsigned, int);
static DWORD create (LPSECURITY_ATTRIBUTES, HANDLE *, HANDLE *, DWORD,
@@ -1408,7 +1408,7 @@ class fhandler_fifo: public fhandler_pipe_fifo
/* Dynamically growing array in shared memory. */
fifo_client_handler *shared_fc_handler;
- bool __reg2 wait (HANDLE);
+ bool wait (HANDLE);
HANDLE create_pipe_instance ();
NTSTATUS open_pipe (HANDLE&);
NTSTATUS wait_open_pipe (HANDLE&);
@@ -1505,11 +1505,11 @@ public:
int dup (fhandler_base *child, int);
bool isfifo () const { return true; }
void set_close_on_exec (bool val);
- void __reg3 raw_read (void *ptr, size_t& ulen);
+ void raw_read (void *ptr, size_t& ulen);
void fixup_after_fork (HANDLE);
void fixup_after_exec ();
- int __reg2 fstat (struct stat *buf);
- int __reg2 fstatvfs (struct statvfs *buf);
+ int fstat (struct stat *buf);
+ int fstatvfs (struct statvfs *buf);
select_record *select_read (select_stuff *);
select_record *select_write (select_stuff *);
select_record *select_except (select_stuff *);
@@ -1558,7 +1558,7 @@ class fhandler_dev_raw: public fhandler_base
int open (int flags, mode_t mode = 0);
- int __reg2 fstat (struct stat *buf);
+ int fstat (struct stat *buf);
int dup (fhandler_base *child, int);
int ioctl (unsigned int cmd, void *buf);
@@ -1620,8 +1620,8 @@ class fhandler_dev_floppy: public fhandler_dev_raw
int open (int flags, mode_t mode = 0);
int close ();
int dup (fhandler_base *child, int);
- void __reg3 raw_read (void *ptr, size_t& ulen);
- ssize_t __reg3 raw_write (const void *ptr, size_t ulen);
+ void raw_read (void *ptr, size_t& ulen);
+ ssize_t raw_write (const void *ptr, size_t ulen);
off_t lseek (off_t offset, int whence);
int ioctl (unsigned int cmd, void *buf);
@@ -1661,12 +1661,12 @@ class fhandler_dev_tape: public fhandler_dev_raw
int open (int flags, mode_t mode = 0);
virtual int close ();
- void __reg3 raw_read (void *ptr, size_t& ulen);
- ssize_t __reg3 raw_write (const void *ptr, size_t ulen);
+ void raw_read (void *ptr, size_t& ulen);
+ ssize_t raw_write (const void *ptr, size_t ulen);
virtual off_t lseek (off_t offset, int whence);
- virtual int __reg2 fstat (struct stat *buf);
+ virtual int fstat (struct stat *buf);
virtual int dup (fhandler_base *child, int);
virtual void fixup_after_fork (HANDLE parent);
@@ -1697,7 +1697,7 @@ class fhandler_disk_file: public fhandler_base
{
HANDLE prw_handle;
bool prw_handle_isasync;
- int __reg3 readdir_helper (DIR *, dirent *, DWORD, DWORD, PUNICODE_STRING fname);
+ int readdir_helper (DIR *, dirent *, DWORD, DWORD, PUNICODE_STRING fname);
int prw_open (bool, void *);
uint64_t fs_ioc_getflags ();
@@ -1713,19 +1713,19 @@ class fhandler_disk_file: public fhandler_base
int dup (fhandler_base *child, int);
void fixup_after_fork (HANDLE parent);
int mand_lock (int, struct flock *);
- int __reg2 fstat (struct stat *buf);
- int __reg1 fchmod (mode_t mode);
- int __reg2 fchown (uid_t uid, gid_t gid);
- int __reg3 facl (int, int, struct acl *);
- struct __acl_t * __reg2 acl_get (uint32_t);
- int __reg3 acl_set (struct __acl_t *, uint32_t);
- ssize_t __reg3 fgetxattr (const char *, void *, size_t);
- int __reg3 fsetxattr (const char *, const void *, size_t, int);
- int __reg3 fadvise (off_t, off_t, int);
- int __reg3 ftruncate (off_t, bool);
- int __reg2 link (const char *);
- int __reg2 utimens (const struct timespec *);
- int __reg2 fstatvfs (struct statvfs *buf);
+ int fstat (struct stat *buf);
+ int fchmod (mode_t mode);
+ int fchown (uid_t uid, gid_t gid);
+ int facl (int, int, struct acl *);
+ struct __acl_t *acl_get (uint32_t);
+ int acl_set (struct __acl_t *, uint32_t);
+ ssize_t fgetxattr (const char *, void *, size_t);
+ int fsetxattr (const char *, const void *, size_t, int);
+ int fadvise (off_t, off_t, int);
+ int ftruncate (off_t, bool);
+ int link (const char *);
+ int utimens (const struct timespec *);
+ int fstatvfs (struct statvfs *buf);
int ioctl (unsigned int cmd, void *buf);
HANDLE mmap (caddr_t *addr, size_t len, int prot, int flags, off_t off);
@@ -1735,15 +1735,15 @@ class fhandler_disk_file: public fhandler_base
off_t offset, SIZE_T size, void *address);
int mkdir (mode_t mode);
int rmdir ();
- DIR __reg2 *opendir (int fd);
- int __reg3 readdir (DIR *, dirent *);
+ DIR *opendir (int fd);
+ int readdir (DIR *, dirent *);
long telldir (DIR *);
void seekdir (DIR *, long);
void rewinddir (DIR *);
int closedir (DIR *);
- ssize_t __reg3 pread (void *, size_t, off_t, void *aio = NULL);
- ssize_t __reg3 pwrite (void *, size_t, off_t, void *aio = NULL);
+ ssize_t pread (void *, size_t, off_t, void *aio = NULL);
+ ssize_t pwrite (void *, size_t, off_t, void *aio = NULL);
fhandler_disk_file (void *) {}
dev_t get_dev () { return pc.fs_serial_number (); }
@@ -1773,11 +1773,11 @@ public:
fhandler_dev ();
int open (int flags, mode_t mode);
int close ();
- int __reg2 fstat (struct stat *buf);
- int __reg2 fstatvfs (struct statvfs *buf);
+ int fstat (struct stat *buf);
+ int fstatvfs (struct statvfs *buf);
int rmdir ();
- DIR __reg2 *opendir (int fd);
- int __reg3 readdir (DIR *, dirent *);
+ DIR *opendir (int fd);
+ int readdir (DIR *, dirent *);
void rewinddir (DIR *);
fhandler_dev (void *) {}
@@ -1805,12 +1805,12 @@ class fhandler_cygdrive: public fhandler_disk_file
public:
fhandler_cygdrive ();
int open (int flags, mode_t mode);
- DIR __reg2 *opendir (int fd);
- int __reg3 readdir (DIR *, dirent *);
+ DIR *opendir (int fd);
+ int readdir (DIR *, dirent *);
void rewinddir (DIR *);
int closedir (DIR *);
- int __reg2 fstat (struct stat *buf);
- int __reg2 fstatvfs (struct statvfs *buf);
+ int fstat (struct stat *buf);
+ int fstatvfs (struct statvfs *buf);
fhandler_cygdrive (void *) {}
dev_t get_dev () { return get_device (); }
@@ -1846,8 +1846,8 @@ class fhandler_serial: public fhandler_base
int open (int flags, mode_t mode);
int init (HANDLE h, DWORD a, mode_t flags);
- void __reg3 raw_read (void *ptr, size_t& ulen);
- ssize_t __reg3 raw_write (const void *ptr, size_t ulen);
+ void raw_read (void *ptr, size_t& ulen);
+ ssize_t raw_write (const void *ptr, size_t ulen);
int tcsendbreak (int);
int tcdrain ();
int tcflow (int);
@@ -2101,10 +2101,10 @@ class dev_console
int set_cl_x (cltype);
int set_cl_y (cltype);
bool fillin (HANDLE);
- bool __reg3 scroll_window (HANDLE, int, int, int, int);
- void __reg3 scroll_buffer (HANDLE, int, int, int, int, int, int);
- void __reg3 clear_screen (HANDLE, int, int, int, int);
- void __reg3 save_restore (HANDLE, char);
+ bool scroll_window (HANDLE, int, int, int, int);
+ void scroll_buffer (HANDLE, int, int, int, int, int, int);
+ void clear_screen (HANDLE, int, int, int, int);
+ void save_restore (HANDLE, char);
friend class fhandler_console;
};
@@ -2155,10 +2155,10 @@ private:
void scroll_buffer (int, int, int, int, int, int);
void scroll_buffer_screen (int, int, int, int, int, int);
- void __reg3 clear_screen (cltype, cltype, cltype, cltype);
- void __reg3 cursor_set (bool, int, int);
- void __reg3 cursor_get (int *, int *);
- void __reg3 cursor_rel (int, int);
+ void clear_screen (cltype, cltype, cltype, cltype);
+ void cursor_set (bool, int, int);
+ void cursor_get (int *, int *);
+ void cursor_rel (int, int);
inline void write_replacement_char ();
inline bool write_console (PWCHAR, DWORD, DWORD&);
const unsigned char *write_normal (unsigned const char*, unsigned const char *);
@@ -2201,7 +2201,7 @@ private:
void post_open_setup (int fd);
int dup (fhandler_base *, int);
- void __reg3 read (void *ptr, size_t& len);
+ void read (void *ptr, size_t& len);
ssize_t __stdcall write (const void *ptr, size_t len);
void doecho (const void *str, DWORD len);
int close ();
@@ -2387,7 +2387,7 @@ class fhandler_pty_slave: public fhandler_pty_common
int open (int flags, mode_t mode = 0);
bool open_setup (int flags);
ssize_t __stdcall write (const void *ptr, size_t len);
- void __reg3 read (void *ptr, size_t& len);
+ void read (void *ptr, size_t& len);
int init (HANDLE, DWORD, mode_t);
int tcsetattr (int a, const struct termios *t);
@@ -2405,10 +2405,10 @@ class fhandler_pty_slave: public fhandler_pty_common
select_record *select_except (select_stuff *);
bg_check_types bg_check (int sig, bool dontsignal = false);
virtual char const *ttyname () { return pc.dev.name (); }
- int __reg2 fstat (struct stat *buf);
- int __reg3 facl (int, int, struct acl *);
- int __reg1 fchmod (mode_t mode);
- int __reg2 fchown (uid_t uid, gid_t gid);
+ int fstat (struct stat *buf);
+ int facl (int, int, struct acl *);
+ int fchmod (mode_t mode);
+ int fchown (uid_t uid, gid_t gid);
fhandler_pty_slave (void *) {}
@@ -2502,7 +2502,7 @@ public:
int open (int flags, mode_t mode = 0);
bool open_setup (int flags);
ssize_t __stdcall write (const void *ptr, size_t len);
- void __reg3 read (void *ptr, size_t& len);
+ void read (void *ptr, size_t& len);
int close ();
void cleanup ();
@@ -2579,7 +2579,7 @@ class fhandler_dev_zero: public fhandler_base
public:
fhandler_dev_zero ();
ssize_t __stdcall write (const void *ptr, size_t len);
- void __reg3 read (void *ptr, size_t& len);
+ void read (void *ptr, size_t& len);
off_t lseek (off_t, int) { return 0; }
virtual HANDLE mmap (caddr_t *addr, size_t len, int prot,
@@ -2618,7 +2618,7 @@ class fhandler_dev_random: public fhandler_base
public:
ssize_t __stdcall write (const void *ptr, size_t len);
- void __reg3 read (void *ptr, size_t& len);
+ void read (void *ptr, size_t& len);
off_t lseek (off_t, int) { return 0; }
fhandler_dev_random () : fhandler_base () {}
@@ -2651,9 +2651,9 @@ class fhandler_dev_clipboard: public fhandler_base
public:
fhandler_dev_clipboard ();
int is_windows () { return 1; }
- int __reg2 fstat (struct stat *buf);
+ int fstat (struct stat *buf);
ssize_t __stdcall write (const void *ptr, size_t len);
- void __reg3 read (void *ptr, size_t& len);
+ void read (void *ptr, size_t& len);
off_t lseek (off_t offset, int whence);
int close ();
@@ -2689,7 +2689,7 @@ class fhandler_windows: public fhandler_base
HWND get_hwnd () { return hWnd_; }
int open (int flags, mode_t mode = 0);
ssize_t __stdcall write (const void *ptr, size_t len);
- void __reg3 read (void *ptr, size_t& len);
+ void read (void *ptr, size_t& len);
int ioctl (unsigned int cmd, void *);
off_t lseek (off_t, int) { return 0; }
int close () { return 0; }
@@ -2735,7 +2735,7 @@ class fhandler_dev_dsp: public fhandler_base
int open (int, mode_t mode = 0);
ssize_t __stdcall write (const void *, size_t);
- void __reg3 read (void *, size_t&);
+ void read (void *, size_t&);
int ioctl (unsigned int, void *);
int close ();
void fixup_after_fork (HANDLE);
@@ -2743,13 +2743,13 @@ class fhandler_dev_dsp: public fhandler_base
private:
ssize_t __stdcall _write (const void *, size_t);
- void __reg3 _read (void *, size_t&);
+ void _read (void *, size_t&);
int _ioctl (unsigned int, void *);
void _fixup_after_fork (HANDLE);
void _fixup_after_exec ();
- void __reg1 close_audio_in ();
- void __reg2 close_audio_out (bool = false);
+ void close_audio_in ();
+ void close_audio_out (bool = false);
bool use_archetype () const {return true;}
fhandler_dev_dsp (void *) {}
@@ -2784,21 +2784,21 @@ class fhandler_virtual : public fhandler_base
virtual ~fhandler_virtual();
virtual virtual_ftype_t exists();
- DIR __reg2 *opendir (int fd);
+ DIR *opendir (int fd);
long telldir (DIR *);
void seekdir (DIR *, long);
void rewinddir (DIR *);
int closedir (DIR *);
ssize_t __stdcall write (const void *ptr, size_t len);
- void __reg3 read (void *ptr, size_t& len);
+ void read (void *ptr, size_t& len);
off_t lseek (off_t, int);
int dup (fhandler_base *child, int);
int open (int flags, mode_t mode = 0);
int close ();
- int __reg2 fstatvfs (struct statvfs *buf);
- int __reg1 fchmod (mode_t mode);
- int __reg2 fchown (uid_t uid, gid_t gid);
- int __reg3 facl (int, int, struct acl *);
+ int fstatvfs (struct statvfs *buf);
+ int fchmod (mode_t mode);
+ int fchown (uid_t uid, gid_t gid);
+ int facl (int, int, struct acl *);
virtual bool fill_filebuf ();
char *get_filebuf () { return filebuf; }
void fixup_after_exec ();
@@ -2826,13 +2826,13 @@ class fhandler_proc: public fhandler_virtual
public:
fhandler_proc ();
virtual_ftype_t exists();
- DIR __reg2 *opendir (int fd);
+ DIR *opendir (int fd);
int closedir (DIR *);
- int __reg3 readdir (DIR *, dirent *);
+ int readdir (DIR *, dirent *);
static fh_devices get_proc_fhandler (const char *path);
int open (int flags, mode_t mode = 0);
- int __reg2 fstat (struct stat *buf);
+ int fstat (struct stat *buf);
bool fill_filebuf ();
fhandler_proc (void *) {}
@@ -2857,18 +2857,18 @@ class fhandler_procsys: public fhandler_virtual
{
public:
fhandler_procsys ();
- virtual_ftype_t __reg2 exists(struct stat *buf);
+ virtual_ftype_t exists(struct stat *buf);
virtual_ftype_t exists();
- DIR __reg2 *opendir (int fd);
- int __reg3 readdir (DIR *, dirent *);
+ DIR *opendir (int fd);
+ int readdir (DIR *, dirent *);
long telldir (DIR *);
void seekdir (DIR *, long);
int closedir (DIR *);
int open (int flags, mode_t mode = 0);
int close ();
- void __reg3 read (void *ptr, size_t& len);
+ void read (void *ptr, size_t& len);
ssize_t __stdcall write (const void *ptr, size_t len);
- int __reg2 fstat (struct stat *buf);
+ int fstat (struct stat *buf);
bool fill_filebuf ();
fhandler_procsys (void *) {}
@@ -2895,9 +2895,9 @@ class fhandler_procsysvipc: public fhandler_proc
public:
fhandler_procsysvipc ();
virtual_ftype_t exists();
- int __reg3 readdir (DIR *, dirent *);
+ int readdir (DIR *, dirent *);
int open (int flags, mode_t mode = 0);
- int __reg2 fstat (struct stat *buf);
+ int fstat (struct stat *buf);
bool fill_filebuf ();
fhandler_procsysvipc (void *) {}
@@ -2923,13 +2923,13 @@ class fhandler_netdrive: public fhandler_virtual
public:
fhandler_netdrive ();
virtual_ftype_t exists();
- int __reg3 readdir (DIR *, dirent *);
+ int readdir (DIR *, dirent *);
void seekdir (DIR *, long);
void rewinddir (DIR *);
int closedir (DIR *);
int open (int flags, mode_t mode = 0);
int close ();
- int __reg2 fstat (struct stat *buf);
+ int fstat (struct stat *buf);
fhandler_netdrive (void *) {}
@@ -2959,15 +2959,15 @@ class fhandler_registry: public fhandler_proc
fhandler_registry ();
void set_name (path_conv &pc);
virtual_ftype_t exists();
- DIR __reg2 *opendir (int fd);
- int __reg3 readdir (DIR *, dirent *);
+ DIR *opendir (int fd);
+ int readdir (DIR *, dirent *);
long telldir (DIR *);
void seekdir (DIR *, long);
void rewinddir (DIR *);
int closedir (DIR *);
int open (int flags, mode_t mode = 0);
- int __reg2 fstat (struct stat *buf);
+ int fstat (struct stat *buf);
bool fill_filebuf ();
int close ();
int dup (fhandler_base *child, int);
@@ -2999,11 +2999,11 @@ class fhandler_process: public fhandler_proc
public:
fhandler_process ();
virtual_ftype_t exists();
- DIR __reg2 *opendir (int fd);
+ DIR *opendir (int fd);
int closedir (DIR *);
- int __reg3 readdir (DIR *, dirent *);
+ int readdir (DIR *, dirent *);
int open (int flags, mode_t mode = 0);
- int __reg2 fstat (struct stat *buf);
+ int fstat (struct stat *buf);
bool fill_filebuf ();
fhandler_process (void *) {}
@@ -3033,8 +3033,8 @@ class fhandler_process_fd : public fhandler_process
fhandler_process_fd (void *) {}
virtual fhandler_base *fd_reopen (int, mode_t);
- int __reg2 fstat (struct stat *buf);
- virtual int __reg2 link (const char *);
+ int fstat (struct stat *buf);
+ virtual int link (const char *);
void copy_from (fhandler_base *x)
{
@@ -3059,9 +3059,9 @@ class fhandler_procnet: public fhandler_proc
fhandler_procnet ();
fhandler_procnet (void *) {}
virtual_ftype_t exists();
- int __reg3 readdir (DIR *, dirent *);
+ int readdir (DIR *, dirent *);
int open (int flags, mode_t mode = 0);
- int __reg2 fstat (struct stat *buf);
+ int fstat (struct stat *buf);
bool fill_filebuf ();
void copy_from (fhandler_base *x)
@@ -3086,7 +3086,7 @@ class fhandler_dev_fd: public fhandler_virtual
fhandler_dev_fd ();
virtual_ftype_t exists();
- int __reg2 fstat (struct stat *buf);
+ int fstat (struct stat *buf);
bool fill_filebuf ();
fhandler_dev_fd (void *) {}
@@ -3120,8 +3120,8 @@ class fhandler_signalfd : public fhandler_base
char *get_proc_fd_name (char *buf);
int signalfd (const sigset_t *mask, int flags);
- int __reg2 fstat (struct stat *buf);
- void __reg3 read (void *ptr, size_t& len);
+ int fstat (struct stat *buf);
+ void read (void *ptr, size_t& len);
ssize_t __stdcall write (const void *, size_t);
int poll ();
@@ -3165,8 +3165,8 @@ class fhandler_timerfd : public fhandler_base
struct itimerspec *ovalue);
int gettime (struct itimerspec *ovalue);
- int __reg2 fstat (struct stat *buf);
- void __reg3 read (void *ptr, size_t& len);
+ int fstat (struct stat *buf);
+ void read (void *ptr, size_t& len);
ssize_t __stdcall write (const void *, size_t);
int dup (fhandler_base *child, int);
int ioctl (unsigned int, void *);
@@ -3247,19 +3247,19 @@ public:
#define NO_IMPL { set_errno (EPERM); return -1; }
- ssize_t __reg3 fgetxattr (const char *, void *, size_t) NO_IMPL;
- int __reg3 fsetxattr (const char *, const void *, size_t, int) NO_IMPL;
- int __reg3 fadvise (off_t, off_t, int) NO_IMPL;
- int __reg3 ftruncate (off_t, bool) NO_IMPL;
- int __reg2 link (const char *) NO_IMPL;
+ ssize_t fgetxattr (const char *, void *, size_t) NO_IMPL;
+ int fsetxattr (const char *, const void *, size_t, int) NO_IMPL;
+ int fadvise (off_t, off_t, int) NO_IMPL;
+ int ftruncate (off_t, bool) NO_IMPL;
+ int link (const char *) NO_IMPL;
int mkdir (mode_t) NO_IMPL;
- ssize_t __reg3 pread (void *, size_t, off_t, void *aio = NULL) NO_IMPL;
- ssize_t __reg3 pwrite (void *, size_t, off_t, void *aio = NULL) NO_IMPL;
+ ssize_t pread (void *, size_t, off_t, void *aio = NULL) NO_IMPL;
+ ssize_t pwrite (void *, size_t, off_t, void *aio = NULL) NO_IMPL;
int lock (int, struct flock *) NO_IMPL;
int mand_lock (int, struct flock *) NO_IMPL;
- void __reg3 read (void *, size_t&);
+ void read (void *, size_t&);
off_t lseek (off_t, int);
- int __reg2 fstat (struct stat *);
+ int fstat (struct stat *);
int dup (fhandler_base *, int);
int fcntl (int cmd, intptr_t);
int ioctl (unsigned int, void *);
diff --git a/winsup/cygwin/fhandler_clipboard.cc b/winsup/cygwin/fhandler_clipboard.cc
index e2814d1..9515795 100644
--- a/winsup/cygwin/fhandler_clipboard.cc
+++ b/winsup/cygwin/fhandler_clipboard.cc
@@ -156,7 +156,7 @@ fhandler_dev_clipboard::write (const void *buf, size_t len)
return len;
}
-int __reg2
+int
fhandler_dev_clipboard::fstat (struct stat *buf)
{
buf->st_mode = S_IFCHR | STD_RBITS | STD_WBITS | S_IWGRP | S_IWOTH;
@@ -198,7 +198,7 @@ fhandler_dev_clipboard::fstat (struct stat *buf)
return 0;
}
-void __reg3
+void
fhandler_dev_clipboard::read (void *ptr, size_t& len)
{
HGLOBAL hglb;
diff --git a/winsup/cygwin/fhandler_console.cc b/winsup/cygwin/fhandler_console.cc
index 9336142..45b786d 100644
--- a/winsup/cygwin/fhandler_console.cc
+++ b/winsup/cygwin/fhandler_console.cc
@@ -833,7 +833,7 @@ fhandler_console::bg_check (int sig, bool dontsignal)
return fhandler_termios::bg_check (sig, dontsignal);
}
-void __reg3
+void
fhandler_console::read (void *pv, size_t& buflen)
{
termios_printf ("read(%p,%d)", pv, buflen);
@@ -1379,7 +1379,7 @@ dev_console::fillin (HANDLE h)
return ret;
}
-void __reg3
+void
dev_console::scroll_buffer (HANDLE h, int x1, int y1, int x2, int y2,
int xn, int yn)
{
@@ -1942,7 +1942,7 @@ dev_console::scroll_window (HANDLE h, int x1, int y1, int x2, int y2)
* Clear the screen context from x1/y1 to x2/y2 cell.
* Negative values represents current screen dimensions
*/
-void __reg3
+void
fhandler_console::clear_screen (cltype xc1, cltype yc1, cltype xc2, cltype yc2)
{
HANDLE h = get_output_handle ();
@@ -1970,7 +1970,7 @@ fhandler_console::clear_screen (cltype xc1, cltype yc1, cltype xc2, cltype yc2)
con.clear_screen (h, x1, y1, x2, y2);
}
-void __reg3
+void
dev_console::clear_screen (HANDLE h, int x1, int y1, int x2, int y2)
{
COORD tlc;
@@ -1995,7 +1995,7 @@ dev_console::clear_screen (HANDLE h, int x1, int y1, int x2, int y2)
release_attach_mutex ();
}
-void __reg3
+void
fhandler_console::cursor_set (bool rel_to_top, int x, int y)
{
COORD pos;
@@ -2030,7 +2030,7 @@ fhandler_console::cursor_set (bool rel_to_top, int x, int y)
release_attach_mutex ();
}
-void __reg3
+void
fhandler_console::cursor_rel (int x, int y)
{
con.fillin (get_output_handle ());
@@ -2039,7 +2039,7 @@ fhandler_console::cursor_rel (int x, int y)
cursor_set (false, x, y);
}
-void __reg3
+void
fhandler_console::cursor_get (int *x, int *y)
{
con.fillin (get_output_handle ());
diff --git a/winsup/cygwin/fhandler_cygdrive.cc b/winsup/cygwin/fhandler_cygdrive.cc
index 91331aa..1ac1d5d 100644
--- a/winsup/cygwin/fhandler_cygdrive.cc
+++ b/winsup/cygwin/fhandler_cygdrive.cc
@@ -52,7 +52,7 @@ fhandler_cygdrive::fstat (struct stat *buf)
return 0;
}
-int __reg2
+int
fhandler_cygdrive::fstatvfs (struct statvfs *sfs)
{
/* Virtual file system. Just return an empty buffer with a few values
diff --git a/winsup/cygwin/fhandler_dev.cc b/winsup/cygwin/fhandler_dev.cc
index 934cdf3..c6bda56 100644
--- a/winsup/cygwin/fhandler_dev.cc
+++ b/winsup/cygwin/fhandler_dev.cc
@@ -64,7 +64,7 @@ fhandler_dev::close ()
return fhandler_disk_file::close ();
}
-int __reg2
+int
fhandler_dev::fstat (struct stat *st)
{
/* If /dev really exists on disk, return correct disk information. */
@@ -78,7 +78,7 @@ fhandler_dev::fstat (struct stat *st)
return 0;
}
-int __reg2
+int
fhandler_dev::fstatvfs (struct statvfs *sfs)
{
int ret = -1, opened = 0;
diff --git a/winsup/cygwin/fhandler_dev_fd.cc b/winsup/cygwin/fhandler_dev_fd.cc
index 6462838..96ebd85 100644
--- a/winsup/cygwin/fhandler_dev_fd.cc
+++ b/winsup/cygwin/fhandler_dev_fd.cc
@@ -21,7 +21,7 @@ fhandler_dev_fd::exists ()
return virt_symlink;
}
-int __reg2
+int
fhandler_dev_fd::fstat (struct stat *buf)
{
const char *path = get_name ();
diff --git a/winsup/cygwin/fhandler_disk_file.cc b/winsup/cygwin/fhandler_disk_file.cc
index 38bdb36..f7728e3 100644
--- a/winsup/cygwin/fhandler_disk_file.cc
+++ b/winsup/cygwin/fhandler_disk_file.cc
@@ -204,7 +204,7 @@ path_conv::get_ino_by_handle (HANDLE hdl)
This returns the content of a struct fattr3 as defined in RFC 1813.
The content is the NFS equivalent of struct stat. so there's not much
to do here except for copying. */
-int __reg2
+int
fhandler_base::fstat_by_nfs_ea (struct stat *buf)
{
fattr3 *nfs_attr = pc.nfsattr ();
@@ -283,7 +283,7 @@ fhandler_base::fstat_by_nfs_ea (struct stat *buf)
return 0;
}
-int __reg2
+int
fhandler_base::fstat_by_handle (struct stat *buf)
{
HANDLE h = get_stat_handle ();
@@ -306,7 +306,7 @@ fhandler_base::fstat_by_handle (struct stat *buf)
return fstat_helper (buf);
}
-int __reg2
+int
fhandler_base::fstat_by_name (struct stat *buf)
{
NTSTATUS status;
@@ -350,7 +350,7 @@ fhandler_base::fstat_by_name (struct stat *buf)
return fstat_helper (buf);
}
-int __reg2
+int
fhandler_base::fstat_fs (struct stat *buf)
{
int res = -1;
@@ -394,7 +394,7 @@ fhandler_base::fstat_fs (struct stat *buf)
return res;
}
-int __reg2
+int
fhandler_base::fstat_helper (struct stat *buf)
{
IO_STATUS_BLOCK st;
@@ -589,13 +589,13 @@ fhandler_base::fstat_helper (struct stat *buf)
return 0;
}
-int __reg2
+int
fhandler_disk_file::fstat (struct stat *buf)
{
return fstat_fs (buf);
}
-int __reg2
+int
fhandler_disk_file::fstatvfs (struct statvfs *sfs)
{
int ret = -1, opened = 0;
@@ -635,7 +635,7 @@ out:
return ret;
}
-int __reg2
+int
fhandler_base::fstatvfs_by_handle (HANDLE fh, struct statvfs *sfs)
{
int ret = -1;
@@ -704,7 +704,7 @@ fhandler_base::fstatvfs_by_handle (HANDLE fh, struct statvfs *sfs)
return ret;
}
-int __reg1
+int
fhandler_disk_file::fchmod (mode_t mode)
{
int ret = -1;
@@ -849,7 +849,7 @@ out:
return ret;
}
-int __reg2
+int
fhandler_disk_file::fchown (uid_t uid, gid_t gid)
{
int oret = 0;
@@ -947,7 +947,7 @@ out:
return ret;
}
-int __reg3
+int
fhandler_disk_file::facl (int cmd, int nentries, aclent_t *aclbufp)
{
int res = -1;
@@ -1562,7 +1562,7 @@ fhandler_disk_file::prw_open (bool write, void *aio)
return 0;
}
-ssize_t __reg3
+ssize_t
fhandler_disk_file::pread (void *buf, size_t count, off_t offset, void *aio)
{
struct aiocb *aiocb = (struct aiocb *) aio;
@@ -1666,7 +1666,7 @@ out:
return res;
}
-ssize_t __reg3
+ssize_t
fhandler_disk_file::pwrite (void *buf, size_t count, off_t offset, void *aio)
{
struct aiocb *aiocb = (struct aiocb *) aio;
@@ -2025,7 +2025,7 @@ free_dir:
return res;
}
-ino_t __reg2
+ino_t
readdir_get_ino (const char *path, bool dot_dot)
{
char *fname;
diff --git a/winsup/cygwin/fhandler_dsp.cc b/winsup/cygwin/fhandler_dsp.cc
index e105514..4d4824b 100644
--- a/winsup/cygwin/fhandler_dsp.cc
+++ b/winsup/cygwin/fhandler_dsp.cc
@@ -1026,7 +1026,7 @@ fhandler_dev_dsp::write (const void *ptr, size_t len)
return base ()->_write (ptr, len);
}
-void __reg3
+void
fhandler_dev_dsp::read (void *ptr, size_t& len)
{
return base ()->_read (ptr, len);
@@ -1139,7 +1139,7 @@ fhandler_dev_dsp::_write (const void *ptr, size_t len)
return len - len_s + written;
}
-void __reg3
+void
fhandler_dev_dsp::_read (void *ptr, size_t& len)
{
debug_printf ("ptr=%p len=%ld", ptr, len);
@@ -1175,7 +1175,7 @@ fhandler_dev_dsp::_read (void *ptr, size_t& len)
audio_in_->read ((char *)ptr, (int&)len);
}
-void __reg1
+void
fhandler_dev_dsp::close_audio_in ()
{
if (audio_in_)
@@ -1186,7 +1186,7 @@ fhandler_dev_dsp::close_audio_in ()
}
}
-void __reg2
+void
fhandler_dev_dsp::close_audio_out (bool immediately)
{
if (audio_out_)
diff --git a/winsup/cygwin/fhandler_fifo.cc b/winsup/cygwin/fhandler_fifo.cc
index 34bd835..fa4ac78 100644
--- a/winsup/cygwin/fhandler_fifo.cc
+++ b/winsup/cygwin/fhandler_fifo.cc
@@ -1219,7 +1219,7 @@ nt_read (HANDLE h, HANDLE evt, PIO_STATUS_BLOCK pio, void *in_ptr, size_t& len)
return status;
}
-void __reg3
+void
fhandler_fifo::raw_read (void *in_ptr, size_t& len)
{
HANDLE evt;
@@ -1415,7 +1415,7 @@ out:
CloseHandle (evt);
}
-int __reg2
+int
fhandler_fifo::fstat (struct stat *buf)
{
if (reader || writer || duplexer)
@@ -1438,7 +1438,7 @@ fhandler_fifo::fstat (struct stat *buf)
return fhandler_base::fstat (buf);
}
-int __reg2
+int
fhandler_fifo::fstatvfs (struct statvfs *sfs)
{
if (get_flags () & O_PATH)
diff --git a/winsup/cygwin/fhandler_floppy.cc b/winsup/cygwin/fhandler_floppy.cc
index 2768a9c..e883ab6 100644
--- a/winsup/cygwin/fhandler_floppy.cc
+++ b/winsup/cygwin/fhandler_floppy.cc
@@ -392,7 +392,7 @@ fhandler_dev_floppy::get_current_position ()
return fpi.CurrentByteOffset.QuadPart;
}
-void __reg3
+void
fhandler_dev_floppy::raw_read (void *ptr, size_t& ulen)
{
DWORD bytes_read = 0;
@@ -524,7 +524,7 @@ err:
ulen = (size_t) -1;
}
-ssize_t __reg3
+ssize_t
fhandler_dev_floppy::raw_write (const void *ptr, size_t len)
{
DWORD bytes_written = 0;
diff --git a/winsup/cygwin/fhandler_mqueue.cc b/winsup/cygwin/fhandler_mqueue.cc
index d81880c..6b94bca 100644
--- a/winsup/cygwin/fhandler_mqueue.cc
+++ b/winsup/cygwin/fhandler_mqueue.cc
@@ -436,7 +436,7 @@ fhandler_mqueue::fill_filebuf ()
return true;
}
-void __reg3
+void
fhandler_mqueue::read (void *in_ptr, size_t& len)
{
if (len == 0)
@@ -479,7 +479,7 @@ fhandler_mqueue::lseek (off_t offset, int whence)
}
-int __reg2
+int
fhandler_mqueue::fstat (struct stat *buf)
{
int ret = fhandler_disk_file::fstat (buf);
diff --git a/winsup/cygwin/fhandler_netdrive.cc b/winsup/cygwin/fhandler_netdrive.cc
index 6365356..306d77d 100644
--- a/winsup/cygwin/fhandler_netdrive.cc
+++ b/winsup/cygwin/fhandler_netdrive.cc
@@ -212,7 +212,7 @@ fhandler_netdrive::fhandler_netdrive ():
{
}
-int __reg2
+int
fhandler_netdrive::fstat (struct stat *buf)
{
const char *path = get_name ();
diff --git a/winsup/cygwin/fhandler_pipe.cc b/winsup/cygwin/fhandler_pipe.cc
index 270ba34..720e4ef 100644
--- a/winsup/cygwin/fhandler_pipe.cc
+++ b/winsup/cygwin/fhandler_pipe.cc
@@ -275,7 +275,7 @@ fhandler_pipe::release_select_sem (const char *from)
ReleaseSemaphore (select_sem, n_release, NULL);
}
-void __reg3
+void
fhandler_pipe::raw_read (void *ptr, size_t& len)
{
size_t nbytes = 0;
@@ -395,7 +395,7 @@ fhandler_pipe::reader_closed ()
return n_reader == n_writer;
}
-ssize_t __reg3
+ssize_t
fhandler_pipe_fifo::raw_write (const void *ptr, size_t len)
{
size_t nbytes = 0;
@@ -1103,7 +1103,7 @@ fhandler_pipe::fcntl (int cmd, intptr_t arg)
return res;
}
-int __reg2
+int
fhandler_pipe::fstat (struct stat *buf)
{
int ret = fhandler_base::fstat (buf);
@@ -1117,7 +1117,7 @@ fhandler_pipe::fstat (struct stat *buf)
return ret;
}
-int __reg2
+int
fhandler_pipe::fstatvfs (struct statvfs *sfs)
{
set_errno (EBADF);
diff --git a/winsup/cygwin/fhandler_proc.cc b/winsup/cygwin/fhandler_proc.cc
index af55364..b79f319 100644
--- a/winsup/cygwin/fhandler_proc.cc
+++ b/winsup/cygwin/fhandler_proc.cc
@@ -191,7 +191,7 @@ fhandler_proc::fhandler_proc ():
{
}
-int __reg2
+int
fhandler_proc::fstat (struct stat *buf)
{
const char *path = get_name ();
diff --git a/winsup/cygwin/fhandler_process.cc b/winsup/cygwin/fhandler_process.cc
index 482dd17..c8ca6e2 100644
--- a/winsup/cygwin/fhandler_process.cc
+++ b/winsup/cygwin/fhandler_process.cc
@@ -130,7 +130,7 @@ fhandler_process::fhandler_process ():
{
}
-int __reg2
+int
fhandler_process::fstat (struct stat *buf)
{
const char *path = get_name ();
diff --git a/winsup/cygwin/fhandler_process_fd.cc b/winsup/cygwin/fhandler_process_fd.cc
index 71ba8b6..d814951 100644
--- a/winsup/cygwin/fhandler_process_fd.cc
+++ b/winsup/cygwin/fhandler_process_fd.cc
@@ -127,7 +127,7 @@ fhandler_process_fd::fd_reopen (int flags, mode_t mode)
return fh;
}
-int __reg2
+int
fhandler_process_fd::fstat (struct stat *statbuf)
{
if (!pc.follow_fd_symlink ())
diff --git a/winsup/cygwin/fhandler_procnet.cc b/winsup/cygwin/fhandler_procnet.cc
index 6df4622..937353b 100644
--- a/winsup/cygwin/fhandler_procnet.cc
+++ b/winsup/cygwin/fhandler_procnet.cc
@@ -69,7 +69,7 @@ fhandler_procnet::fhandler_procnet ():
{
}
-int __reg2
+int
fhandler_procnet::fstat (struct stat *buf)
{
fhandler_base::fstat (buf);
diff --git a/winsup/cygwin/fhandler_procsys.cc b/winsup/cygwin/fhandler_procsys.cc
index 02741d0..a5fd85f 100644
--- a/winsup/cygwin/fhandler_procsys.cc
+++ b/winsup/cygwin/fhandler_procsys.cc
@@ -251,7 +251,7 @@ unreadable:
return false;
}
-int __reg2
+int
fhandler_procsys::fstat (struct stat *buf)
{
const char *path = get_name ();
@@ -426,7 +426,7 @@ fhandler_procsys::closedir (DIR *dir)
return fhandler_virtual::closedir (dir);
}
-void __reg3
+void
fhandler_procsys::read (void *ptr, size_t& len)
{
fhandler_base::raw_read (ptr, len);
diff --git a/winsup/cygwin/fhandler_procsysvipc.cc b/winsup/cygwin/fhandler_procsysvipc.cc
index c2c7e0f..453d3b4 100644
--- a/winsup/cygwin/fhandler_procsysvipc.cc
+++ b/winsup/cygwin/fhandler_procsysvipc.cc
@@ -86,7 +86,7 @@ fhandler_procsysvipc::fhandler_procsysvipc ():
{
}
-int __reg2
+int
fhandler_procsysvipc::fstat (struct stat *buf)
{
fhandler_base::fstat (buf);
diff --git a/winsup/cygwin/fhandler_random.cc b/winsup/cygwin/fhandler_random.cc
index 1a3edd1..c0f37b5 100644
--- a/winsup/cygwin/fhandler_random.cc
+++ b/winsup/cygwin/fhandler_random.cc
@@ -86,7 +86,7 @@ fhandler_dev_random::pseudo_read (void *ptr, size_t len)
return len;
}
-void __reg3
+void
fhandler_dev_random::read (void *ptr, size_t& len)
{
if (!len)
diff --git a/winsup/cygwin/fhandler_raw.cc b/winsup/cygwin/fhandler_raw.cc
index 536d752..44cb10d 100644
--- a/winsup/cygwin/fhandler_raw.cc
+++ b/winsup/cygwin/fhandler_raw.cc
@@ -32,7 +32,7 @@ fhandler_dev_raw::~fhandler_dev_raw ()
delete [] devbufalloc;
}
-int __reg2
+int
fhandler_dev_raw::fstat (struct stat *buf)
{
debug_printf ("here");
diff --git a/winsup/cygwin/fhandler_registry.cc b/winsup/cygwin/fhandler_registry.cc
index b6c8aee..2830c70 100644
--- a/winsup/cygwin/fhandler_registry.cc
+++ b/winsup/cygwin/fhandler_registry.cc
@@ -459,7 +459,7 @@ fhandler_proc ()
prefix_len = sizeof ("registry") - 1;
}
-int __reg2
+int
fhandler_registry::fstat (struct stat *buf)
{
fhandler_base::fstat (buf);
diff --git a/winsup/cygwin/fhandler_serial.cc b/winsup/cygwin/fhandler_serial.cc
index e025730..174a57a 100644
--- a/winsup/cygwin/fhandler_serial.cc
+++ b/winsup/cygwin/fhandler_serial.cc
@@ -30,7 +30,7 @@ fhandler_serial::fhandler_serial ()
need_fork_fixup (true);
}
-void __reg3
+void
fhandler_serial::raw_read (void *ptr, size_t& ulen)
{
OVERLAPPED ov = { 0 };
@@ -173,7 +173,7 @@ out:
/* Cover function to WriteFile to provide Posix interface and semantics
(as much as possible). */
-ssize_t __reg3
+ssize_t
fhandler_serial::raw_write (const void *ptr, size_t len)
{
DWORD bytes_written;
diff --git a/winsup/cygwin/fhandler_signalfd.cc b/winsup/cygwin/fhandler_signalfd.cc
index 4d89a6c..9730551 100644
--- a/winsup/cygwin/fhandler_signalfd.cc
+++ b/winsup/cygwin/fhandler_signalfd.cc
@@ -54,7 +54,7 @@ fhandler_signalfd::signalfd (const sigset_t *mask, int flags)
return 0;
}
-int __reg2
+int
fhandler_signalfd::fstat (struct stat *buf)
{
int ret = fhandler_base::fstat (buf);
@@ -89,7 +89,7 @@ copy_siginfo_to_signalfd (struct signalfd_siginfo *sfd,
sfd->ssi_addr = (uint64_t) si->si_addr;
}
-void __reg3
+void
fhandler_signalfd::read (void *ptr, size_t& len)
{
const LARGE_INTEGER poll = { QuadPart : 0 };
diff --git a/winsup/cygwin/fhandler_socket.cc b/winsup/cygwin/fhandler_socket.cc
index f224126..57a75df 100644
--- a/winsup/cygwin/fhandler_socket.cc
+++ b/winsup/cygwin/fhandler_socket.cc
@@ -273,7 +273,7 @@ fhandler_socket::open (int flags, mode_t mode)
return 0;
}
-int __reg2
+int
fhandler_socket::fstat (struct stat *buf)
{
int res;
@@ -293,7 +293,7 @@ fhandler_socket::fstat (struct stat *buf)
return res;
}
-int __reg2
+int
fhandler_socket::fstatvfs (struct statvfs *sfs)
{
memset (sfs, 0, sizeof (*sfs));
diff --git a/winsup/cygwin/fhandler_socket_inet.cc b/winsup/cygwin/fhandler_socket_inet.cc
index f738ce4..6339052 100644
--- a/winsup/cygwin/fhandler_socket_inet.cc
+++ b/winsup/cygwin/fhandler_socket_inet.cc
@@ -1366,7 +1366,7 @@ fhandler_socket_wsock::recvmsg (struct msghdr *msg, int flags)
return ret;
}
-void __reg3
+void
fhandler_socket_wsock::read (void *in_ptr, size_t& len)
{
char *ptr = (char *) in_ptr;
diff --git a/winsup/cygwin/fhandler_socket_local.cc b/winsup/cygwin/fhandler_socket_local.cc
index c787073..249ad0e 100644
--- a/winsup/cygwin/fhandler_socket_local.cc
+++ b/winsup/cygwin/fhandler_socket_local.cc
@@ -670,7 +670,7 @@ fhandler_socket_local::fcntl (int cmd, intptr_t arg)
return fhandler_socket_wsock::fcntl (cmd, arg);
}
-int __reg2
+int
fhandler_socket_local::fstat (struct stat *buf)
{
if (!dev ().isfs ())
@@ -687,7 +687,7 @@ fhandler_socket_local::fstat (struct stat *buf)
return res;
}
-int __reg2
+int
fhandler_socket_local::fstatvfs (struct statvfs *sfs)
{
if (!dev ().isfs ())
diff --git a/winsup/cygwin/fhandler_socket_unix.cc b/winsup/cygwin/fhandler_socket_unix.cc
index 8abb581..10b1339 100644
--- a/winsup/cygwin/fhandler_socket_unix.cc
+++ b/winsup/cygwin/fhandler_socket_unix.cc
@@ -1891,7 +1891,7 @@ fhandler_socket_unix::recvfrom (void *ptr, size_t len, int flags,
return ret;
}
-void __reg3
+void
fhandler_socket_unix::read (void *ptr, size_t& len)
{
set_errno (EAFNOSUPPORT);
@@ -2311,7 +2311,7 @@ fhandler_socket_unix::fcntl (int cmd, intptr_t arg)
return ret;
}
-int __reg2
+int
fhandler_socket_unix::fstat (struct stat *buf)
{
if (!dev ().isfs ())
@@ -2328,7 +2328,7 @@ fhandler_socket_unix::fstat (struct stat *buf)
return ret;
}
-int __reg2
+int
fhandler_socket_unix::fstatvfs (struct statvfs *sfs)
{
if (!dev ().isfs ())
diff --git a/winsup/cygwin/fhandler_tape.cc b/winsup/cygwin/fhandler_tape.cc
index a7f64ea..0e235f1 100644
--- a/winsup/cygwin/fhandler_tape.cc
+++ b/winsup/cygwin/fhandler_tape.cc
@@ -1269,7 +1269,7 @@ fhandler_dev_tape::close ()
return ret ? -1 : cret;
}
-void __reg3
+void
fhandler_dev_tape::raw_read (void *ptr, size_t &ulen)
{
char *buf = (char *) ptr;
@@ -1371,7 +1371,7 @@ fhandler_dev_tape::raw_read (void *ptr, size_t &ulen)
unlock ();
}
-ssize_t __reg3
+ssize_t
fhandler_dev_tape::raw_write (const void *ptr, size_t len)
{
if (!_lock (true))
@@ -1453,7 +1453,7 @@ out:
#endif
}
-int __reg2
+int
fhandler_dev_tape::fstat (struct stat *buf)
{
int ret;
diff --git a/winsup/cygwin/fhandler_timerfd.cc b/winsup/cygwin/fhandler_timerfd.cc
index e7e2232..6bc4e0d 100644
--- a/winsup/cygwin/fhandler_timerfd.cc
+++ b/winsup/cygwin/fhandler_timerfd.cc
@@ -101,7 +101,7 @@ fhandler_timerfd::gettime (struct itimerspec *ovalue)
return ret;
}
-int __reg2
+int
fhandler_timerfd::fstat (struct stat *buf)
{
int ret = fhandler_base::fstat (buf);
@@ -114,7 +114,7 @@ fhandler_timerfd::fstat (struct stat *buf)
return ret;
}
-void __reg3
+void
fhandler_timerfd::read (void *ptr, size_t& len)
{
if (len < sizeof (LONG64))
diff --git a/winsup/cygwin/fhandler_tty.cc b/winsup/cygwin/fhandler_tty.cc
index b8427dc..e3f774a 100644
--- a/winsup/cygwin/fhandler_tty.cc
+++ b/winsup/cygwin/fhandler_tty.cc
@@ -1350,7 +1350,7 @@ fhandler_pty_common::to_be_read_from_nat_pipe (void)
return get_ttyp ()->nat_fg (get_ttyp ()->getpgid ());
}
-void __reg3
+void
fhandler_pty_slave::read (void *ptr, size_t& len)
{
ssize_t totalread = 0;
@@ -1777,7 +1777,7 @@ out:
return retval;
}
-int __reg2
+int
fhandler_pty_slave::fstat (struct stat *st)
{
fhandler_base::fstat (st);
@@ -1807,7 +1807,7 @@ fhandler_pty_slave::fstat (struct stat *st)
return 0;
}
-int __reg3
+int
fhandler_pty_slave::facl (int cmd, int nentries, aclent_t *aclbufp)
{
int res = -1;
@@ -1918,7 +1918,7 @@ fhandler_pty_slave::fch_close_handles ()
close_maybe (inuse);
}
-int __reg1
+int
fhandler_pty_slave::fchmod (mode_t mode)
{
int ret = -1;
@@ -1945,7 +1945,7 @@ errout:
return ret;
}
-int __reg2
+int
fhandler_pty_slave::fchown (uid_t uid, gid_t gid)
{
int ret = -1;
@@ -2327,7 +2327,7 @@ fhandler_pty_master::write (const void *ptr, size_t len)
return ret;
}
-void __reg3
+void
fhandler_pty_master::read (void *ptr, size_t& len)
{
bg_check_types bg = bg_check (SIGTTIN);
diff --git a/winsup/cygwin/fhandler_virtual.cc b/winsup/cygwin/fhandler_virtual.cc
index b9ee31f..bdd454d 100644
--- a/winsup/cygwin/fhandler_virtual.cc
+++ b/winsup/cygwin/fhandler_virtual.cc
@@ -177,7 +177,7 @@ fhandler_virtual::close ()
return 0;
}
-void __reg3
+void
fhandler_virtual::read (void *ptr, size_t& len)
{
if (len == 0)
@@ -262,7 +262,7 @@ fhandler_virtual::facl (int cmd, int nentries, aclent_t *aclbufp)
return res;
}
-int __reg2
+int
fhandler_virtual::fstatvfs (struct statvfs *sfs)
{
/* Virtual file system. Just return an empty buffer with a few values
diff --git a/winsup/cygwin/fhandler_windows.cc b/winsup/cygwin/fhandler_windows.cc
index 3a2119f..947cfd5 100644
--- a/winsup/cygwin/fhandler_windows.cc
+++ b/winsup/cygwin/fhandler_windows.cc
@@ -76,7 +76,7 @@ fhandler_windows::write (const void *buf, size_t)
return sizeof (MSG);
}
-void __reg3
+void
fhandler_windows::read (void *buf, size_t& len)
{
MSG *ptr = (MSG *) buf;
diff --git a/winsup/cygwin/fhandler_zero.cc b/winsup/cygwin/fhandler_zero.cc
index 1f75821..5637685 100644
--- a/winsup/cygwin/fhandler_zero.cc
+++ b/winsup/cygwin/fhandler_zero.cc
@@ -30,7 +30,7 @@ fhandler_dev_zero::write (const void *, size_t len)
return len;
}
-void __reg3
+void
fhandler_dev_zero::read (void *ptr, size_t& len)
{
memset (ptr, 0, len);
diff --git a/winsup/cygwin/heap.cc b/winsup/cygwin/heap.cc
index fa2c839..0fbda30 100644
--- a/winsup/cygwin/heap.cc
+++ b/winsup/cygwin/heap.cc
@@ -243,7 +243,7 @@ sbrk (ptrdiff_t n)
return cygheap->user_heap.sbrk (n);
}
-void __reg2 *
+void *
user_heap_info::sbrk (ptrdiff_t n)
{
/* FIXME: This function no longer handles "split heaps". */
diff --git a/winsup/cygwin/include/sys/strace.h b/winsup/cygwin/include/sys/strace.h
index 3334b04..7221b7f 100644
--- a/winsup/cygwin/include/sys/strace.h
+++ b/winsup/cygwin/include/sys/strace.h
@@ -37,17 +37,17 @@ class strace
void write (unsigned category, const char *buf, int count);
unsigned char _active;
public:
- void activate (bool) __attribute__ ((__regparm__ (2)));;
+ void activate (bool);
strace () {}
int microseconds ();
int version;
int lmicrosec;
bool execing;
- void dll_info () __attribute__ ((__regparm__ (1)));
- void prntf (unsigned, const char *func, const char *, ...) /*__attribute__ ((__regparm__(3)))*/;
- void vprntf (unsigned, const char *func, const char *, va_list ap) /*__attribute__ ((__regparm__(3)))*/;
- void wm (int message, int word, int lon) __attribute__ ((__regparm__(3)));
- void write_childpid (pid_t) __attribute__ ((__regparm__ (3)));
+ void dll_info ();
+ void prntf (unsigned, const char *func, const char *, ...);
+ void vprntf (unsigned, const char *func, const char *, va_list ap);
+ void wm (int message, int word, int lon);
+ void write_childpid (pid_t);
bool attached () const {return _active == 3;}
bool active () const {return _active & 1;}
unsigned char& active_val () {return _active;}
diff --git a/winsup/cygwin/miscfuncs.cc b/winsup/cygwin/miscfuncs.cc
index 739d9de..c3e63f4 100644
--- a/winsup/cygwin/miscfuncs.cc
+++ b/winsup/cygwin/miscfuncs.cc
@@ -34,7 +34,7 @@ get_obj_handle_count (HANDLE h)
return hdl_cnt;
}
-int __reg2
+int
check_invalid_virtual_addr (const void *s, unsigned sz)
{
MEMORY_BASIC_INFORMATION mbuf;
@@ -326,7 +326,7 @@ NT_readline::gets ()
}
/* Return an address from the import jmp table of main program. */
-void * __reg1
+void *
__import_address (void *imp)
{
__try
diff --git a/winsup/cygwin/miscfuncs.h b/winsup/cygwin/miscfuncs.h
index f571031..b0f8c24 100644
--- a/winsup/cygwin/miscfuncs.h
+++ b/winsup/cygwin/miscfuncs.h
@@ -44,10 +44,10 @@ is_alt_numpad_event (PINPUT_RECORD pirec)
&& pirec->Event.KeyEvent.wVirtualScanCode == 0x38;
}
-int __reg1 winprio_to_nice (DWORD);
-DWORD __reg1 nice_to_winprio (int &);
+int winprio_to_nice (DWORD);
+DWORD nice_to_winprio (int &);
-bool __reg3 create_pipe (PHANDLE, PHANDLE, LPSECURITY_ATTRIBUTES, DWORD);
+bool create_pipe (PHANDLE, PHANDLE, LPSECURITY_ATTRIBUTES, DWORD);
BOOL WINAPI CreatePipeOverlapped (PHANDLE read_handle, PHANDLE write_handle,
LPSECURITY_ATTRIBUTES sa);
@@ -78,11 +78,11 @@ public:
extern "C" void yield ();
#define import_address(x) __import_address ((void *)(x))
-void * __reg1 __import_address (void *);
+void * __import_address (void *);
#define caller_return_address() \
__caller_return_address (__builtin_return_address (0))
-void * __reg1 __caller_return_address (void *);
+void * __caller_return_address (void *);
void backslashify (const char *, char *, bool);
void slashify (const char *, char *, bool);
@@ -102,9 +102,9 @@ PWCHAR transform_chars_af_unix (PWCHAR, const char *, __socklen_t);
ULONG get_obj_handle_count (HANDLE h);
/* Memory checking */
-int __reg2 check_invalid_virtual_addr (const void *s, unsigned sz);
+int check_invalid_virtual_addr (const void *s, unsigned sz);
-ssize_t __reg3 check_iovec (const struct iovec *, int, bool);
+ssize_t check_iovec (const struct iovec *, int, bool);
#define check_iovec_for_read(a, b) check_iovec ((a), (b), false)
#define check_iovec_for_write(a, b) check_iovec ((a), (b), true)
diff --git a/winsup/cygwin/mount.h b/winsup/cygwin/mount.h
index 122a679..f54516c 100644
--- a/winsup/cygwin/mount.h
+++ b/winsup/cygwin/mount.h
@@ -124,7 +124,7 @@ class fs_info
const char *fsname () const { return fsn[0] ? fsn : "unknown"; }
- bool __reg3 update (PUNICODE_STRING, HANDLE);
+ bool update (PUNICODE_STRING, HANDLE);
bool inited () const { return !!status.flags; }
};
diff --git a/winsup/cygwin/ntea.cc b/winsup/cygwin/ntea.cc
index 8020dc9..5094cf3 100644
--- a/winsup/cygwin/ntea.cc
+++ b/winsup/cygwin/ntea.cc
@@ -38,7 +38,7 @@ details. */
#define NEXT_FEA(p) ((PFILE_FULL_EA_INFORMATION) (p->NextEntryOffset \
? (char *) p + p->NextEntryOffset : NULL))
-ssize_t __reg3
+ssize_t
read_ea (HANDLE hdl, path_conv &pc, const char *name, char *value, size_t size)
{
OBJECT_ATTRIBUTES attr;
@@ -229,7 +229,7 @@ read_ea (HANDLE hdl, path_conv &pc, const char *name, char *value, size_t size)
return ret;
}
-int __reg3
+int
write_ea (HANDLE hdl, path_conv &pc, const char *name, const char *value,
size_t size, int flags)
{
diff --git a/winsup/cygwin/path.cc b/winsup/cygwin/path.cc
index 5e6d0ea..98f7aa1 100644
--- a/winsup/cygwin/path.cc
+++ b/winsup/cygwin/path.cc
@@ -381,9 +381,9 @@ path_conv::add_ext_from_sym (symlink_info &sym)
}
}
-static void __reg2 mkrelpath (char *dst, bool caseinsensitive);
+static void mkrelpath (char *dst, bool caseinsensitive);
-static void __reg2
+static void
mkrelpath (char *path, bool caseinsensitive)
{
tmp_pathbuf tp;
@@ -1573,7 +1573,7 @@ normalize_win32_path (const char *src, char *dst, char *&tail)
/* nofinalslash: Remove trailing / and \ from SRC (except for the
first one). It is ok for src == dst. */
-void __reg2
+void
nofinalslash (const char *src, char *dst)
{
int len = strlen (src);
@@ -3656,7 +3656,7 @@ readlink (const char *__restrict path, char *__restrict buf, size_t buflen)
done during the opendir call and the hash or the filename within
the directory. FIXME: Not bullet-proof. */
/* Cygwin internal */
-ino_t __reg2
+ino_t
hash_path_name (ino_t hash, PUNICODE_STRING name)
{
if (name->Length == 0)
@@ -3670,7 +3670,7 @@ hash_path_name (ino_t hash, PUNICODE_STRING name)
return hash;
}
-ino_t __reg2
+ino_t
hash_path_name (ino_t hash, PCWSTR name)
{
UNICODE_STRING uname;
@@ -3678,7 +3678,7 @@ hash_path_name (ino_t hash, PCWSTR name)
return hash_path_name (hash, &uname);
}
-ino_t __reg2
+ino_t
hash_path_name (ino_t hash, const char *name)
{
UNICODE_STRING uname;
diff --git a/winsup/cygwin/path.h b/winsup/cygwin/path.h
index adb0ca1..74f831e 100644
--- a/winsup/cygwin/path.h
+++ b/winsup/cygwin/path.h
@@ -245,9 +245,9 @@ class path_conv
void set_symlink (DWORD n) {path_flags |= PATH_SYMLINK; symlink_length = n;}
void set_exec (int x = 1) {mount_flags |= x ? MOUNT_EXEC : MOUNT_NOTEXEC;}
- void __reg3 check (const UNICODE_STRING *upath, uint32_t opt = PC_SYM_FOLLOW,
+ void check (const UNICODE_STRING *upath, uint32_t opt = PC_SYM_FOLLOW,
const suffix_info *suffixes = NULL);
- void __reg3 check (const char *src, uint32_t opt = PC_SYM_FOLLOW,
+ void check (const char *src, uint32_t opt = PC_SYM_FOLLOW,
const suffix_info *suffixes = NULL);
path_conv (const device& in_dev)
@@ -411,7 +411,7 @@ class path_conv
ino_t get_ino_by_handle (HANDLE h);
inline const char *get_posix () const { return posix_path; }
- void __reg2 set_posix (const char *);
+ void set_posix (const char *);
DWORD get_symlink_length () { return symlink_length; };
};
@@ -431,7 +431,7 @@ enum fe_types
FE_CWD = 4, /* Search CWD for program */
FE_DLL = 8 /* Search for DLLs, not executables. */
};
-const char *__reg3 find_exec (const char *name, path_conv& buf,
+const char *find_exec (const char *name, path_conv& buf,
const char *search = "PATH",
unsigned opt = FE_NADA,
const char **known_suffix = NULL);
@@ -449,15 +449,15 @@ has_exec_chars (const char *buf, int len)
(buf[0] == 'M' && buf[1] == 'Z'));
}
-int __reg3 pathmatch (const char *path1, const char *path2, bool caseinsensitive);
-int __reg3 pathnmatch (const char *path1, const char *path2, int len, bool caseinsensitive);
-bool __reg2 has_dot_last_component (const char *dir, bool test_dot_dot);
+int pathmatch (const char *path1, const char *path2, bool caseinsensitive);
+int pathnmatch (const char *path1, const char *path2, int len, bool caseinsensitive);
+bool has_dot_last_component (const char *dir, bool test_dot_dot);
-int __reg3 path_prefix_p (const char *path1, const char *path2, int len1,
+int path_prefix_p (const char *path1, const char *path2, int len1,
bool caseinsensitive);
int normalize_win32_path (const char *, char *, char *&);
int normalize_posix_path (const char *, char *, char *&);
-PUNICODE_STRING __reg3 get_nt_native_path (const char *, UNICODE_STRING&, bool);
+PUNICODE_STRING get_nt_native_path (const char *, UNICODE_STRING&, bool);
-int __reg3 symlink_worker (const char *, path_conv &, bool);
+int symlink_worker (const char *, path_conv &, bool);
diff --git a/winsup/cygwin/pinfo.cc b/winsup/cygwin/pinfo.cc
index f501c47..a54dac8 100644
--- a/winsup/cygwin/pinfo.cc
+++ b/winsup/cygwin/pinfo.cc
@@ -581,7 +581,7 @@ _pinfo::set_ctty (fhandler_termios *fh, int flags)
/* Test to determine if a process really exists and is processing signals.
*/
-bool __reg1
+bool
_pinfo::exists ()
{
return process_state && !(process_state & (PID_EXITED | PID_REAPED));
diff --git a/winsup/cygwin/pinfo.h b/winsup/cygwin/pinfo.h
index 7e46cfb..86ba64b 100644
--- a/winsup/cygwin/pinfo.h
+++ b/winsup/cygwin/pinfo.h
@@ -119,8 +119,8 @@ public:
int siginfo (sigset_t &, sigset_t &, sigset_t &);
bool set_ctty (class fhandler_termios *, int);
bool alert_parent (char);
- int __reg2 kill (siginfo_t&);
- bool __reg1 exists ();
+ int kill (siginfo_t&);
+ bool exists ();
const char *_ctty (char *);
/* signals */
@@ -160,7 +160,7 @@ public:
bool waiter_ready;
class cygthread *wait_thread;
- void __reg3 init (pid_t, DWORD, HANDLE);
+ void init (pid_t, DWORD, HANDLE);
pinfo (_pinfo *x = NULL)
: pinfo_minimal (), destroy (false), winpid_hdl (NULL), procinfo (x),
waiter_ready (false), wait_thread (NULL) {}
@@ -171,19 +171,19 @@ public:
init (n, flag, NULL);
}
pinfo (HANDLE, pinfo_minimal&, pid_t);
- void __reg2 thisproc (HANDLE);
+ void thisproc (HANDLE);
void create_winpid_symlink ();
inline void _pinfo_release ();
void release ();
- bool __reg1 wait ();
+ bool wait ();
~pinfo ()
{
if (destroy && procinfo)
release ();
}
- void __reg2 exit (DWORD n) __attribute__ ((noreturn, ));
- void __reg1 maybe_set_exit_code_from_windows ();
- void __reg2 set_exit_code (DWORD n);
+ void exit (DWORD n) __attribute__ ((noreturn, ));
+ void maybe_set_exit_code_from_windows ();
+ void set_exit_code (DWORD n);
_pinfo *operator -> () const {return procinfo;}
int operator == (pinfo *x) const {return x->procinfo == procinfo;}
int operator == (pinfo &x) const {return x.procinfo == procinfo;}
diff --git a/winsup/cygwin/regparm.h b/winsup/cygwin/regparm.h
deleted file mode 100644
index cce1bab..0000000
--- a/winsup/cygwin/regparm.h
+++ /dev/null
@@ -1,19 +0,0 @@
-/* regparm.h: Define macros for regparm functions and methods.
-
-This file is part of Cygwin.
-
-This software is a copyrighted work licensed under the terms of the
-Cygwin license. Please consult the file "CYGWIN_LICENSE" for
-details. */
-
-#pragma once
-
-#if defined (__x86_64__) || defined (__CYGMAGIC__)
-# define __reg1
-# define __reg2
-# define __reg3
-#else
-# define __reg1 __stdcall __attribute__ ((regparm (1)))
-# define __reg2 __stdcall __attribute__ ((regparm (2)))
-# define __reg3 __stdcall __attribute__ ((regparm (3)))
-#endif
diff --git a/winsup/cygwin/sec_helper.cc b/winsup/cygwin/sec_helper.cc
index 86d2a7b..fad3b33 100644
--- a/winsup/cygwin/sec_helper.cc
+++ b/winsup/cygwin/sec_helper.cc
@@ -593,7 +593,7 @@ sec_acl (PACL acl, bool original, bool admins, PSID sid1, PSID sid2, DWORD acces
return true;
}
-PSECURITY_ATTRIBUTES __reg3
+PSECURITY_ATTRIBUTES
__sec_user (PVOID sa_buf, PSID sid1, PSID sid2, DWORD access2, BOOL inherit)
{
PSECURITY_ATTRIBUTES psa = (PSECURITY_ATTRIBUTES) sa_buf;
diff --git a/winsup/cygwin/sec_posixacl.cc b/winsup/cygwin/sec_posixacl.cc
index e745bdb..e7e5a9c 100644
--- a/winsup/cygwin/sec_posixacl.cc
+++ b/winsup/cygwin/sec_posixacl.cc
@@ -559,14 +559,14 @@ acl_to_text (acl_t acl, ssize_t *len_p)
return NULL;
}
-acl_t __reg2
+acl_t
fhandler_base::acl_get (acl_type_t type)
{
set_errno (ENOTSUP);
return NULL;
}
-acl_t __reg2
+acl_t
fhandler_disk_file::acl_get (acl_type_t type)
{
acl_t acl = NULL;
@@ -663,14 +663,14 @@ acl_get_file (const char *path_p, acl_type_t type)
return acl;
}
-int __reg3
+int
fhandler_base::acl_set (acl_t acl, acl_type_t type)
{
set_errno (ENOTSUP);
return -1;
}
-int __reg3
+int
fhandler_disk_file::acl_set (acl_t acl, acl_type_t type)
{
int ret = -1;
diff --git a/winsup/cygwin/security.h b/winsup/cygwin/security.h
index ff25480..c40adf1 100644
--- a/winsup/cygwin/security.h
+++ b/winsup/cygwin/security.h
@@ -411,23 +411,23 @@ legal_sid_type (SID_NAME_USE type)
class path_conv;
/* File manipulation */
-int __reg3 get_file_attribute (HANDLE, path_conv &, mode_t *,
+int get_file_attribute (HANDLE, path_conv &, mode_t *,
uid_t *, gid_t *);
-int __reg3 set_created_file_access (HANDLE, path_conv &, mode_t);
-int __reg2 get_object_sd (HANDLE, security_descriptor &);
-int __reg3 get_object_attribute (HANDLE, uid_t *, gid_t *, mode_t *);
-int __reg3 set_object_attribute (HANDLE, uid_t, gid_t, mode_t);
-int __reg3 create_object_sd_from_attribute (uid_t, gid_t, mode_t,
+int set_created_file_access (HANDLE, path_conv &, mode_t);
+int get_object_sd (HANDLE, security_descriptor &);
+int get_object_attribute (HANDLE, uid_t *, gid_t *, mode_t *);
+int set_object_attribute (HANDLE, uid_t, gid_t, mode_t);
+int create_object_sd_from_attribute (uid_t, gid_t, mode_t,
security_descriptor &);
-int __reg3 set_object_sd (HANDLE, security_descriptor &, bool);
+int set_object_sd (HANDLE, security_descriptor &, bool);
-int __reg3 get_reg_attribute (HKEY hkey, mode_t *, uid_t *, gid_t *);
-LONG __reg3 get_file_sd (HANDLE fh, path_conv &, security_descriptor &, bool);
-LONG __reg3 set_file_sd (HANDLE fh, path_conv &, security_descriptor &, bool);
-bool __reg3 add_access_allowed_ace (PACL, DWORD, PSID, size_t &, DWORD);
-bool __reg3 add_access_denied_ace (PACL, DWORD, PSID, size_t &, DWORD);
-int __reg3 check_file_access (path_conv &, int, bool);
-int __reg3 check_registry_access (HANDLE, int, bool);
+int get_reg_attribute (HKEY hkey, mode_t *, uid_t *, gid_t *);
+LONG get_file_sd (HANDLE fh, path_conv &, security_descriptor &, bool);
+LONG set_file_sd (HANDLE fh, path_conv &, security_descriptor &, bool);
+bool add_access_allowed_ace (PACL, DWORD, PSID, size_t &, DWORD);
+bool add_access_denied_ace (PACL, DWORD, PSID, size_t &, DWORD);
+int check_file_access (path_conv &, int, bool);
+int check_registry_access (HANDLE, int, bool);
void set_security_attribute (path_conv &pc, int attribute,
PSECURITY_ATTRIBUTES psa,
@@ -514,7 +514,7 @@ void set_cygwin_privileges (HANDLE token);
/* Various types of security attributes for use in Create* functions. */
extern SECURITY_ATTRIBUTES sec_none, sec_none_nih, sec_all, sec_all_nih;
-extern SECURITY_ATTRIBUTES *__reg3 __sec_user (PVOID, PSID, PSID,
+extern SECURITY_ATTRIBUTES *__sec_user (PVOID, PSID, PSID,
DWORD, BOOL);
extern PSECURITY_DESCRIPTOR _recycler_sd (void *buf, bool users, bool dir);
@@ -531,9 +531,9 @@ extern PSECURITY_DESCRIPTOR _everyone_sd (void *buf, ACCESS_MASK access);
extern bool sec_acl (PACL acl, bool original, bool admins, PSID sid1 = NO_SID,
PSID sid2 = NO_SID, DWORD access2 = 0);
-ssize_t __reg3 read_ea (HANDLE, path_conv &, const char *,
+ssize_t read_ea (HANDLE, path_conv &, const char *,
char *, size_t);
-int __reg3 write_ea (HANDLE, path_conv &, const char *, const char *,
+int write_ea (HANDLE, path_conv &, const char *, const char *,
size_t, int);
/* Note: sid1 is usually (read: currently always) the current user's
diff --git a/winsup/cygwin/signal.cc b/winsup/cygwin/signal.cc
index 0530355..7715291 100644
--- a/winsup/cygwin/signal.cc
+++ b/winsup/cygwin/signal.cc
@@ -27,7 +27,7 @@ details. */
#define _SA_NORESTART 0x8000
-static int __reg3 sigaction_worker (int, const struct sigaction *, struct sigaction *, bool);
+static int sigaction_worker (int, const struct sigaction *, struct sigaction *, bool);
#define sigtrapped(func) ((func) != SIG_IGN && (func) != SIG_DFL)
@@ -204,7 +204,7 @@ sigprocmask (int how, const sigset_t *set, sigset_t *oldset)
return res;
}
-int __reg3
+int
handle_sigprocmask (int how, const sigset_t *set, sigset_t *oldset, sigset_t& opmask)
{
/* check that how is in right range if set is not NULL */
@@ -248,7 +248,7 @@ handle_sigprocmask (int how, const sigset_t *set, sigset_t *oldset, sigset_t& op
return 0;
}
-int __reg2
+int
_pinfo::kill (siginfo_t& si)
{
int res;
@@ -415,7 +415,7 @@ abort (void)
do_exit (SIGABRT); /* signal handler didn't exit. Goodbye. */
}
-static int __reg3
+static int
sigaction_worker (int sig, const struct sigaction *newact,
struct sigaction *oldact, bool isinternal)
{
diff --git a/winsup/cygwin/sigproc.cc b/winsup/cygwin/sigproc.cc
index a70c3b6..0d9da23 100644
--- a/winsup/cygwin/sigproc.cc
+++ b/winsup/cygwin/sigproc.cc
@@ -101,7 +101,7 @@ Static HANDLE my_readsig;
HANDLE NO_COPY my_pendingsigs_evt;
/* Function declarations */
-static int __reg1 checkstate (waitq *);
+static int checkstate (waitq *);
static __inline__ bool get_proc_lock (DWORD, DWORD);
static int remove_proc (int);
static bool stopped_or_terminated (waitq *, _pinfo *);
@@ -120,7 +120,7 @@ public:
bool pending () {retry = true; return !!start.next;}
void clear (int sig) {sigs[sig].si.si_signo = 0;}
void clear (_cygtls *tls);
- friend void __reg1 sig_dispatch_pending (bool);
+ friend void sig_dispatch_pending (bool);
friend void WINAPI wait_sig (VOID *arg);
};
@@ -192,7 +192,7 @@ proc_can_be_signalled (_pinfo *p)
return false;
}
-bool __reg1
+bool
pid_exists (pid_t pid)
{
pinfo p (pid);
@@ -211,7 +211,7 @@ mychild (int pid)
/* Handle all subprocess requests
*/
-int __reg2
+int
proc_subproc (DWORD what, uintptr_t val)
{
int slot;
@@ -433,7 +433,7 @@ proc_terminate ()
}
/* Clear pending signal */
-void __reg1
+void
sig_clear (int sig)
{
sigq.clear (sig);
@@ -474,7 +474,7 @@ sigpending (sigset_t *mask)
}
/* Force the wait_sig thread to wake up and scan for pending signals */
-void __reg1
+void
sig_dispatch_pending (bool fast)
{
/* Non-atomically test for any signals pending and wake up wait_sig if any are
@@ -551,7 +551,7 @@ exit_thread (DWORD res)
ExitThread (res);
}
-sigset_t __reg3
+sigset_t
sig_send (_pinfo *p, int sig, _cygtls *tls)
{
siginfo_t si = {};
@@ -564,7 +564,7 @@ sig_send (_pinfo *p, int sig, _cygtls *tls)
If pinfo *p == NULL, send to the current process.
If sending to this process, wait for notification that a signal has
completed before returning. */
-sigset_t __reg3
+sigset_t
sig_send (_pinfo *p, siginfo_t& si, _cygtls *tls)
{
int rc = 1;
@@ -1155,7 +1155,7 @@ child_info_fork::abort (const char *fmt, ...)
/* Check the state of all of our children to see if any are stopped or
* terminated.
*/
-static int __reg1
+static int
checkstate (waitq *parent_w)
{
int potential_match = 0;
diff --git a/winsup/cygwin/sigproc.h b/winsup/cygwin/sigproc.h
index d037eae..f2d7e31 100644
--- a/winsup/cygwin/sigproc.h
+++ b/winsup/cygwin/sigproc.h
@@ -53,33 +53,33 @@ struct sigpacket
HANDLE thread_handle;
struct sigpacket *next;
};
- int __reg1 process ();
- int __reg3 setup_handler (void *, struct sigaction&, _cygtls *);
+ int process ();
+ int setup_handler (void *, struct sigaction&, _cygtls *);
};
-void __reg1 sig_dispatch_pending (bool fast = false);
-void __reg2 set_signal_mask (sigset_t&, sigset_t);
-int __reg3 handle_sigprocmask (int sig, const sigset_t *set,
+void sig_dispatch_pending (bool fast = false);
+void set_signal_mask (sigset_t&, sigset_t);
+int handle_sigprocmask (int sig, const sigset_t *set,
sigset_t *oldset, sigset_t& opmask);
-void __reg1 sig_clear (int);
-void __reg1 sig_set_pending (int);
+void sig_clear (int);
+void sig_set_pending (int);
int __stdcall handle_sigsuspend (sigset_t);
-int __reg2 proc_subproc (DWORD, uintptr_t);
+int proc_subproc (DWORD, uintptr_t);
class _pinfo;
void proc_terminate ();
void sigproc_init ();
-bool __reg1 pid_exists (pid_t);
-sigset_t __reg3 sig_send (_pinfo *, siginfo_t&, class _cygtls * = NULL);
-sigset_t __reg3 sig_send (_pinfo *, int, class _cygtls * = NULL);
+bool pid_exists (pid_t);
+sigset_t sig_send (_pinfo *, siginfo_t&, class _cygtls * = NULL);
+sigset_t sig_send (_pinfo *, int, class _cygtls * = NULL);
void signal_fixup_after_exec ();
void sigalloc ();
int kill_pgrp (pid_t, siginfo_t&);
-void __reg1 exit_thread (DWORD) __attribute__ ((noreturn));
-void __reg1 setup_signal_exit (int);
+void exit_thread (DWORD) __attribute__ ((noreturn));
+void setup_signal_exit (int);
int sigwait_common (const sigset_t *, siginfo_t *, PLARGE_INTEGER);
class no_thread_exit_protect
diff --git a/winsup/cygwin/spawn.cc b/winsup/cygwin/spawn.cc
index 905d949..8e70035 100644
--- a/winsup/cygwin/spawn.cc
+++ b/winsup/cygwin/spawn.cc
@@ -84,7 +84,7 @@ perhaps_suffix (const char *prog, path_conv& buf, int& err, unsigned opt)
If the file is not found and !FE_NNF then the POSIX version of name is
placed in buf and returned. Otherwise the contents of buf is undefined
and NULL is returned. */
-const char * __reg3
+const char *
find_exec (const char *name, path_conv& buf, const char *search,
unsigned opt, const char **known_suffix)
{
diff --git a/winsup/cygwin/sync.h b/winsup/cygwin/sync.h
index e11a229..d0b4878 100644
--- a/winsup/cygwin/sync.h
+++ b/winsup/cygwin/sync.h
@@ -24,17 +24,17 @@ public:
// class muto *next;
/* The real constructor. */
- muto __reg2 *init (const char *);
+ muto *init (const char *);
#if 0 /* FIXME: See comment in sync.cc */
~muto ()
#endif
- int __reg2 acquire (DWORD ms = INFINITE); /* Acquire the lock. */
- int __reg2 release (_cygtls * = &_my_tls); /* Release the lock. */
+ int acquire (DWORD ms = INFINITE); /* Acquire the lock. */
+ int release (_cygtls * = &_my_tls); /* Release the lock. */
- bool __reg1 acquired ();
+ bool acquired ();
void upforgrabs () {tls = this;} // just set to an invalid address
- void __reg1 grab ();
+ void grab ();
operator int () const {return !!name;}
};
diff --git a/winsup/cygwin/syscalls.cc b/winsup/cygwin/syscalls.cc
index b88edd9..7d53c2a 100644
--- a/winsup/cygwin/syscalls.cc
+++ b/winsup/cygwin/syscalls.cc
@@ -1998,7 +1998,7 @@ sync ()
}
/* Cygwin internal */
-int __reg2
+int
stat_worker (path_conv &pc, struct stat *buf)
{
int res = -1;
@@ -4961,7 +4961,7 @@ unlinkat (int dirfd, const char *pathname, int flags)
return -1;
}
-static int __reg3
+static int
pipe_worker (int filedes[2], unsigned int psize, int mode)
{
fhandler_pipe *fhs[2];
diff --git a/winsup/cygwin/tty.cc b/winsup/cygwin/tty.cc
index 60f4a60..2959fe2 100644
--- a/winsup/cygwin/tty.cc
+++ b/winsup/cygwin/tty.cc
@@ -82,7 +82,7 @@ tty::init_session ()
cygheap->fdtab.get_debugger_info ();
}
-int __reg2
+int
tty_list::attach (int n)
{
int res;
diff --git a/winsup/cygwin/tty.h b/winsup/cygwin/tty.h
index 3a87110..c4f2b5d 100644
--- a/winsup/cygwin/tty.h
+++ b/winsup/cygwin/tty.h
@@ -77,7 +77,7 @@ public:
void setsid (pid_t tsid) {sid = tsid;}
void kill_pgrp (int, pid_t target_pgid = 0);
int is_orphaned_process_group (int);
- const __reg1 char *ttyname () __attribute (());
+ const char *ttyname () __attribute (());
};
@@ -88,7 +88,7 @@ class fhandler_pty_master;
class tty: public tty_min
{
- HANDLE __reg3 get_event (const char *fmt, PSECURITY_ATTRIBUTES sa,
+ HANDLE get_event (const char *fmt, PSECURITY_ATTRIBUTES sa,
BOOL manual_reset = FALSE);
public:
pid_t master_pid; /* PID of tty master process */
@@ -191,7 +191,7 @@ public:
int connect (int);
void init ();
tty_min *get_cttyp ();
- int __reg2 attach (int n);
+ int attach (int n);
static void __stdcall init_session ();
friend class lock_ttys;
};
diff --git a/winsup/cygwin/window.cc b/winsup/cygwin/window.cc
index 007542b..0020538 100644
--- a/winsup/cygwin/window.cc
+++ b/winsup/cygwin/window.cc
@@ -21,7 +21,7 @@ wininfo NO_COPY winmsg;
muto NO_COPY wininfo::_lock;
-int __reg3
+int
wininfo::process (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
{
#ifndef NOSTRACE
@@ -52,7 +52,7 @@ process_window_events (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
}
/* Handle windows events. Inherits ownership of the wininfo lock */
-DWORD __reg1 WINAPI
+DWORD WINAPI
wininfo::winthread ()
{
MSG msg;
diff --git a/winsup/cygwin/winf.h b/winsup/cygwin/winf.h
index e3a65f8..651f78b 100644
--- a/winsup/cygwin/winf.h
+++ b/winsup/cygwin/winf.h
@@ -39,7 +39,7 @@ class av
cfree (argv);
}
}
- int unshift (const char *what) __reg2;
+ int unshift (const char *what);
operator char **() {return argv;}
void all_calloced () {calloced = argc;}
void replace0_maybe (const char *arg0)
@@ -58,7 +58,7 @@ class av
calloced = argc;
}
int setup (const char *, path_conv&, const char *, int, const char *const *,
- bool) __reg3;
+ bool);
};
class linebuf
@@ -69,11 +69,11 @@ class linebuf
public:
linebuf () : ix (0), buf (NULL), alloced (0) {}
~linebuf () {if (buf) free (buf);}
- void __reg3 add (const char *, int);
+ void add (const char *, int);
void add (const char *what) {add (what, strlen (what));}
void prepend (const char *, int);
- void __reg2 finish (bool);
- bool __reg3 fromargv(av&, const char *, bool);;
+ void finish (bool);
+ bool fromargv(av&, const char *, bool);;
operator size_t () const { return ix + 1; }
operator const char * () const { return buf; }
operator wchar_t * ()
diff --git a/winsup/cygwin/wininfo.h b/winsup/cygwin/wininfo.h
index 193eb6a..9dfba1a 100644
--- a/winsup/cygwin/wininfo.h
+++ b/winsup/cygwin/wininfo.h
@@ -13,10 +13,10 @@ class wininfo
static muto _lock;
public:
operator HWND ();
- int __reg3 process (HWND, UINT, WPARAM, LPARAM);
+ int process (HWND, UINT, WPARAM, LPARAM);
void lock ();
void release ();
- DWORD __reg1 WINAPI winthread ();
+ DWORD WINAPI winthread ();
};
extern wininfo winmsg;
diff --git a/winsup/cygwin/winsup.h b/winsup/cygwin/winsup.h
index 6d817f4..87aa5ef 100644
--- a/winsup/cygwin/winsup.h
+++ b/winsup/cygwin/winsup.h
@@ -79,7 +79,6 @@ uint32_t cygwin_inet_addr (const char *cp);
#ifdef __cplusplus
#include "wincap.h"
-#include "regparm.h"
extern const unsigned char case_folded_lower[];
#define cyg_tolower(c) ((char) case_folded_lower[(unsigned char)(c)])
@@ -162,7 +161,7 @@ extern "C" void _pei386_runtime_relocator (per_process *);
extern "C" int dll_noncygwin_dllcrt0 (HMODULE, per_process *);
#endif /* __i386__ */
-void __reg1 do_exit (int) __attribute__ ((noreturn));
+void do_exit (int) __attribute__ ((noreturn));
/* libstdc++ malloc operator wrapper support. */
extern struct per_process_cxx_malloc default_cygwin_cxx_malloc;
@@ -191,13 +190,13 @@ const char *find_first_notloaded_dll (class path_conv &);
void __stdcall set_std_handle (int);
int __stdcall stat_dev (DWORD, int, unsigned long, struct stat *);
-ino_t __reg2 hash_path_name (ino_t hash, PUNICODE_STRING name);
-ino_t __reg2 hash_path_name (ino_t hash, PCWSTR name);
-ino_t __reg2 hash_path_name (ino_t hash, const char *name);
-void __reg2 nofinalslash (const char *src, char *dst);
+ino_t hash_path_name (ino_t hash, PUNICODE_STRING name);
+ino_t hash_path_name (ino_t hash, PCWSTR name);
+ino_t hash_path_name (ino_t hash, const char *name);
+void nofinalslash (const char *src, char *dst);
-void __reg3 *hook_or_detect_cygwin (const char *, const void *, WORD&, HANDLE h = NULL);
-void __reg3 *hook_api (const char *mname, const char *name, const void *fn);
+void *hook_or_detect_cygwin (const char *, const void *, WORD&, HANDLE h = NULL);
+void *hook_api (const char *mname, const char *name, const void *fn);
/* Time related */
void __stdcall totimeval (struct timeval *, PLARGE_INTEGER, int, int);
@@ -225,9 +224,9 @@ bool child_copy (HANDLE, bool, bool, ...);
class path_conv;
-int __reg2 stat_worker (path_conv &pc, struct stat *buf);
+int stat_worker (path_conv &pc, struct stat *buf);
-ino_t __reg2 readdir_get_ino (const char *path, bool dot_dot);
+ino_t readdir_get_ino (const char *path, bool dot_dot);
/* mmap functions. */
enum mmap_region_status