Mercurial > hg > GearsTemplate
view src/verifier/verify_put_cs.c @ 590:9146d6017f18 default tip
hg mv parallel_execution/* ..
author | anatofuz <anatofuz@cr.ie.u-ryukyu.ac.jp> |
---|---|
date | Thu, 16 Jan 2020 15:12:06 +0900 |
parents | src/parallel_execution/verifier/verify_put_cs.c@e6bc0a4c2c36 |
children |
line wrap: on
line source
/* Verification of LLRB-Tree height in put operations. * LLRB-Tree allows (max-height) <= 2*(min-height). */ #include <stdlib.h> #include <stdio.h> #include <time.h> #include "llrbContextWithVerifier.h" __code meta(struct Context* context, enum Code next) { if (next == Put) { verify_tree_height(context->data[Tree]->tree.root); } goto (context->code[next])(context); } __code start_code(struct Context* context, enum Code next) { unsigned int seed = (unsigned int)time(NULL); printf("--- srand(%u)\n", seed); goto meta(context, next); } __code exit_code(struct Context* context) { free(context->code); free(context->data); free(context->heapStart); goto exit(0); }