Nugget
Loading...
Searching...
No Matches
Functions | Variables
qsort.c File Reference
#include "common/syscalls/syscalls.h"
Include dependency graph for qsort.c:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

 CESTER_BODY (static int icmp(const void *a, const void *b) { return *(const int *) a - *(const int *) b;})
 
 syscall_qsort (input, size, sizeof(input[0]), icmp)
 
 for (int i=0;i< size;i++)
 
 CESTER_BODY (static int scmp(const void *a, const void *b) { return syscall_strcmp(*(const char **) a, *(const char **) b);})
 
 syscall_qsort (input, size, sizeof(input[0]), scmp)
 

Variables

int input []
 

Function Documentation

◆ CESTER_BODY() [1/2]

CESTER_BODY ( static int icmp(const void *a, const void *b) { return *(const int *) a - *(const int *) b;}  )

◆ CESTER_BODY() [2/2]

CESTER_BODY ( static int scmp(const void *a, const void *b) { return syscall_strcmp(*(const char **) a, *(const char **) b);}  )

◆ for()

for ( )

◆ syscall_qsort() [1/2]

syscall_qsort ( input  ,
size  ,
sizeof(input[0])  ,
icmp   
)

◆ syscall_qsort() [2/2]

syscall_qsort ( input  ,
size  ,
sizeof(input[0])  ,
scmp   
)

Variable Documentation

◆ input

const char * input
Initial value:
= {
2097143,
8191,
509,
1021,
257,
65537,
4099,
1048573,
524287,
127,
131071,
4194301,
16381,
32771,
2053,
262147,
}