Throughout, change __attribute__ ((regparm (N))) to just __regN. Throughout,

(mainly in fhandler*) start fixing gcc 4.7.2 mismatch between regparm
definitions and declarations.
* gendef: Define some functions to take @ declaration to accommodate _regN
defines which use __stdcall.
* gentls_offsets: Define __regN macros as empty.
* autoload.cc (wsock_init): Remove unneeded regparm attribute.
* winsup.h (__reg1): Define.
(__reg2): Define.
(__reg3): Define.
* advapi32.cc (DuplicateTokenEx): Coerce some initializers to avoid warnings
from gcc 4.7.2.
* exceptions.cc (status_info): Declare struct to use NTSTATUS.
(cygwin_exception::dump_exception): Coerce e->ExceptionCode to NTSTATUS.
* fhandler_clipboard.cc (cygnativeformat): Redefine as UINT to avoid gcc 4.7.2
warnings.
(fhandler_dev_clipboard::read): Ditto.
This commit is contained in:
Christopher Faylor
2013-01-21 04:34:52 +00:00
parent d89e61f354
commit 6e75c72b89
60 changed files with 510 additions and 511 deletions

View File

@@ -1,6 +1,7 @@
/* cygtls.h
Copyright 2003, 2004, 2005, 2008, 2009, 2010, 2011, 2012, 2013 Red Hat, Inc.
Copyright 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013
Red Hat, Inc.
This software is a copyrighted work licensed under the terms of the
Cygwin license. Please consult the file "CYGWIN_LICENSE" for
@@ -208,30 +209,28 @@ public:
static void call (DWORD (*) (void *, void *), void *);
void remove (DWORD);
void push (__stack_t addr) {*stackptr++ = (__stack_t) addr;}
__stack_t pop () __attribute__ ((regparm (1)));
__stack_t __reg1 pop ();
__stack_t retaddr () {return stackptr[-1];}
bool isinitialized () const
{
return initialized == CYGTLS_INITIALIZED;
}
bool interrupt_now (CONTEXT *, siginfo_t&, void *, struct sigaction&)
__attribute__((regparm(3)));
void __stdcall interrupt_setup (siginfo_t&, void *, struct sigaction&)
__attribute__((regparm(3)));
bool __reg3 interrupt_now (CONTEXT *, siginfo_t&, void *, struct sigaction&);
void __reg3 interrupt_setup (siginfo_t&, void *, struct sigaction&);
bool inside_kernel (CONTEXT *);
void copy_context (CONTEXT *) __attribute__ ((regparm(2)));
void signal_debugger (int) __attribute__ ((regparm(2)));
void __reg2 copy_context (CONTEXT *);
void __reg2 signal_debugger (int);
#ifdef CYGTLS_HANDLE
operator HANDLE () const {return tid ? tid->win32_obj_id : NULL;}
#endif
int call_signal_handler () __attribute__ ((regparm (1)));
void remove_wq (DWORD) __attribute__ ((regparm (1)));
void fixup_after_fork () __attribute__ ((regparm (1)));
void lock () __attribute__ ((regparm (1)));
void unlock () __attribute__ ((regparm (1)));
bool locked () __attribute__ ((regparm (1)));
int __reg1 call_signal_handler ();
void __reg1 remove_wq (DWORD);
void __reg1 fixup_after_fork ();
void __reg1 lock ();
void __reg1 unlock ();
bool __reg1 locked ();
HANDLE get_signal_arrived (bool wait_for_lock = true)
{
if (!signal_arrived)
@@ -257,7 +256,7 @@ public:
}
void reset_signal_arrived () { will_wait_for_signal = false; }
private:
void call2 (DWORD (*) (void *, void *), void *, void *) __attribute__ ((regparm (3)));
void __reg3 call2 (DWORD (*) (void *, void *), void *, void *);
/*gentls_offsets*/
};
#pragma pack(pop)