git/parallel-checkout.c

#define USE_THE_REPOSITORY_VARIABLE

#include "git-compat-util.h"
#include "config.h"
#include "entry.h"
#include "gettext.h"
#include "hash.h"
#include "hex.h"
#include "parallel-checkout.h"
#include "pkt-line.h"
#include "progress.h"
#include "read-cache-ll.h"
#include "run-command.h"
#include "sigchain.h"
#include "streaming.h"
#include "symlinks.h"
#include "thread-utils.h"
#include "trace2.h"

struct pc_worker {};

struct parallel_checkout {};

static struct parallel_checkout parallel_checkout;

enum pc_status parallel_checkout_status(void)
{}

static const int DEFAULT_THRESHOLD_FOR_PARALLELISM =;
static const int DEFAULT_NUM_WORKERS =;

void get_parallel_checkout_configs(int *num_workers, int *threshold)
{}

void init_parallel_checkout(void)
{}

static void finish_parallel_checkout(void)
{}

static int is_eligible_for_parallel_checkout(const struct cache_entry *ce,
					     const struct conv_attrs *ca)
{}

int enqueue_checkout(struct cache_entry *ce, struct conv_attrs *ca,
		     int *checkout_counter)
{}

size_t pc_queue_size(void)
{}

static void advance_progress_meter(void)
{}

static int handle_results(struct checkout *state)
{}

static int reset_fd(int fd, const char *path)
{}

static int write_pc_item_to_fd(struct parallel_checkout_item *pc_item, int fd,
			       const char *path)
{}

static int close_and_clear(int *fd)
{}

void write_pc_item(struct parallel_checkout_item *pc_item,
		   struct checkout *state)
{}

static void send_one_item(int fd, struct parallel_checkout_item *pc_item)
{}

static void send_batch(int fd, size_t start, size_t nr)
{}

static struct pc_worker *setup_workers(struct checkout *state, int num_workers)
{}

static void finish_workers(struct pc_worker *workers, int num_workers)
{}

static inline void assert_pc_item_result_size(int got, int exp)
{}

static void parse_and_save_result(const char *buffer, int len,
				  struct pc_worker *worker)
{}

static void gather_results_from_workers(struct pc_worker *workers,
					int num_workers)
{}

static void write_items_sequentially(struct checkout *state)
{}

int run_parallel_checkout(struct checkout *state, int num_workers, int threshold,
			  struct progress *progress, unsigned int *progress_cnt)
{}