Initial commit

Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
This commit is contained in:
Robert Baldyga
2019-03-29 08:39:34 +01:00
commit 94e8ca09e0
140 changed files with 37144 additions and 0 deletions

22
casadm/psort.h Normal file
View File

@@ -0,0 +1,22 @@
/*
* Copyright(c) 2012-2019 Intel Corporation
* SPDX-License-Identifier: BSD-3-Clause-Clear
*/
#ifndef PSORT_H
#define PSORT_H
typedef int (*compar_t)(const void *, const void *);
/**
* function does exactly the same thing as qsort, except, that it sorts
* using many CPU cores, not just one.
*
* number of CPU cores is configured as half of the number of online
* CPUs in the system.
*/
void psort(void *base, size_t nmemb, size_t size,
compar_t compar);
#endif