Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/C/Postgres/src/include/port/   (Postgres Database Version 18.4©)  Datei vom 11.4.2026 mit Größe 1 kB image not shown  

Quelle  pg_pthread.h

  Sprache: C
 

/*-------------------------------------------------------------------------
 *
 * Declarations for missing POSIX thread components.
 *
 *   Currently this supplies an implementation of pthread_barrier_t for the
 *   benefit of macOS, which lacks it.  These declarations are not in port.h,
 *   because that'd require <pthread.h> to be included by every translation
 *   unit.
 *
 *-------------------------------------------------------------------------
 */


#ifndef PG_PTHREAD_H
#define PG_PTHREAD_H

#include <pthread.h>   /* IWYU pragma: export */

#ifndef HAVE_PTHREAD_BARRIER_WAIT

#ifndef PTHREAD_BARRIER_SERIAL_THREAD
#define PTHREAD_BARRIER_SERIAL_THREAD (-1)
#endif

typedef struct pg_pthread_barrier
{
 bool  sense;   /* we only need a one bit phase */
 int   count;   /* number of threads expected */
 int   arrived;  /* number of threads that have arrived */
 pthread_mutex_t mutex;
 pthread_cond_t cond;
} pthread_barrier_t;

extern int pthread_barrier_init(pthread_barrier_t *barrier,
         const void *attr,
         int count);
extern int pthread_barrier_wait(pthread_barrier_t *barrier);
extern int pthread_barrier_destroy(pthread_barrier_t *barrier);

#endif

#endif

Messung V0.5 in Prozent
C=82 H=95 G=88

¤ Dauer der Verarbeitung: 0.14 Sekunden  (vorverarbeitet am  2026-08-08) ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

PVS Prover

Isabelle Prover

NIST Cobol Testsuite

Cephes Mathematical Library

Vienna Development Method

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.