1
0
Fork 0
mirror of https://github.com/tobast/libunwind-eh_elf.git synced 2024-11-25 16:47:38 +01:00

Apply `define_lock()'

We have a nice macro for defining pthread mutexes, use it.
This commit is contained in:
Tommi Rantala 2012-09-21 07:43:41 +03:00
parent 22aff2cc1f
commit aebba1f8a7
9 changed files with 9 additions and 9 deletions

View file

@ -25,7 +25,7 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
#include "unwind_i.h" #include "unwind_i.h"
#include "dwarf_i.h" #include "dwarf_i.h"
HIDDEN pthread_mutex_t arm_lock = PTHREAD_MUTEX_INITIALIZER; HIDDEN define_lock (arm_lock);
HIDDEN int tdep_init_done; HIDDEN int tdep_init_done;
/* Unwinding methods to use. See UNW_METHOD_ enums */ /* Unwinding methods to use. See UNW_METHOD_ enums */

View file

@ -25,7 +25,7 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
#include "unwind_i.h" #include "unwind_i.h"
HIDDEN pthread_mutex_t hppa_lock = PTHREAD_MUTEX_INITIALIZER; HIDDEN define_lock (hppa_lock);
HIDDEN int tdep_init_done; HIDDEN int tdep_init_done;
HIDDEN void HIDDEN void

View file

@ -25,7 +25,7 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
#include "libunwind_i.h" #include "libunwind_i.h"
HIDDEN pthread_mutex_t _U_dyn_info_list_lock = PTHREAD_MUTEX_INITIALIZER; HIDDEN define_lock (_U_dyn_info_list_lock);
void void
_U_dyn_register (unw_dyn_info_t *di) _U_dyn_register (unw_dyn_info_t *di)

View file

@ -25,7 +25,7 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
#include "unwind_i.h" #include "unwind_i.h"
#include "dwarf_i.h" #include "dwarf_i.h"
HIDDEN pthread_mutex_t mips_lock = PTHREAD_MUTEX_INITIALIZER; HIDDEN define_lock (mips_lock);
HIDDEN int tdep_init_done; HIDDEN int tdep_init_done;
HIDDEN void HIDDEN void

View file

@ -28,7 +28,7 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
#include "unwind_i.h" #include "unwind_i.h"
#include "dwarf_i.h" #include "dwarf_i.h"
HIDDEN pthread_mutex_t ppc32_lock = PTHREAD_MUTEX_INITIALIZER; HIDDEN define_lock (ppc32_lock);
HIDDEN int tdep_init_done; HIDDEN int tdep_init_done;
/* The API register numbers are exactly the same as the .eh_frame /* The API register numbers are exactly the same as the .eh_frame

View file

@ -28,7 +28,7 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
#include "unwind_i.h" #include "unwind_i.h"
#include "dwarf_i.h" #include "dwarf_i.h"
HIDDEN pthread_mutex_t ppc64_lock = PTHREAD_MUTEX_INITIALIZER; HIDDEN define_lock (ppc64_lock);
HIDDEN int tdep_init_done; HIDDEN int tdep_init_done;
/* The API register numbers are exactly the same as the .eh_frame /* The API register numbers are exactly the same as the .eh_frame

View file

@ -26,7 +26,7 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
#include "unwind_i.h" #include "unwind_i.h"
#include "dwarf_i.h" #include "dwarf_i.h"
HIDDEN pthread_mutex_t x86_lock = PTHREAD_MUTEX_INITIALIZER; HIDDEN define_lock (x86_lock);
HIDDEN int tdep_init_done; HIDDEN int tdep_init_done;
/* See comments for svr4_dbx_register_map[] in gcc/config/i386/i386.c. */ /* See comments for svr4_dbx_register_map[] in gcc/config/i386/i386.c. */

View file

@ -29,7 +29,7 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
#include "unwind_i.h" #include "unwind_i.h"
#include "dwarf_i.h" #include "dwarf_i.h"
HIDDEN pthread_mutex_t x86_64_lock = PTHREAD_MUTEX_INITIALIZER; HIDDEN define_lock (x86_64_lock);
HIDDEN int tdep_init_done; HIDDEN int tdep_init_done;
/* See comments for svr4_dbx_register_map[] in gcc/config/i386/i386.c. */ /* See comments for svr4_dbx_register_map[] in gcc/config/i386/i386.c. */

View file

@ -45,7 +45,7 @@ typedef struct
} unw_trace_cache_t; } unw_trace_cache_t;
static const unw_tdep_frame_t empty_frame = { 0, UNW_X86_64_FRAME_OTHER, -1, -1, 0, -1, -1 }; static const unw_tdep_frame_t empty_frame = { 0, UNW_X86_64_FRAME_OTHER, -1, -1, 0, -1, -1 };
static pthread_mutex_t trace_init_lock = PTHREAD_MUTEX_INITIALIZER; static define_lock (trace_init_lock);
static pthread_once_t trace_cache_once = PTHREAD_ONCE_INIT; static pthread_once_t trace_cache_once = PTHREAD_ONCE_INIT;
static sig_atomic_t trace_cache_once_happen; static sig_atomic_t trace_cache_once_happen;
static pthread_key_t trace_cache_key; static pthread_key_t trace_cache_key;