55 |
#define max(a, b) ((a) > (b) ? (a) : (b)) |
#define max(a, b) ((a) > (b) ? (a) : (b)) |
56 |
|
|
57 |
static bitset_bindex |
static bitset_bindex |
58 |
vbitset_resize (src, n_bits) |
vbitset_resize (bitset src, bitset_bindex n_bits) |
|
bitset src; |
|
|
bitset_bindex n_bits; |
|
59 |
{ |
{ |
60 |
bitset_windex oldsize; |
bitset_windex oldsize; |
61 |
bitset_windex newsize; |
bitset_windex newsize; |
341 |
|
|
342 |
|
|
343 |
static void |
static void |
344 |
vbitset_ones (dst) |
vbitset_ones (bitset dst) |
|
bitset dst; |
|
345 |
{ |
{ |
346 |
bitset_word *dstp = VBITSET_WORDS (dst); |
bitset_word *dstp = VBITSET_WORDS (dst); |
347 |
unsigned int bytes; |
unsigned int bytes; |
354 |
|
|
355 |
|
|
356 |
static void |
static void |
357 |
vbitset_zero (dst) |
vbitset_zero (bitset dst) |
|
bitset dst; |
|
358 |
{ |
{ |
359 |
bitset_word *dstp = VBITSET_WORDS (dst); |
bitset_word *dstp = VBITSET_WORDS (dst); |
360 |
unsigned int bytes; |
unsigned int bytes; |
366 |
|
|
367 |
|
|
368 |
static bool |
static bool |
369 |
vbitset_empty_p (dst) |
vbitset_empty_p (bitset dst) |
|
bitset dst; |
|
370 |
{ |
{ |
371 |
unsigned int i; |
unsigned int i; |
372 |
bitset_word *dstp = VBITSET_WORDS (dst); |
bitset_word *dstp = VBITSET_WORDS (dst); |
380 |
|
|
381 |
|
|
382 |
static void |
static void |
383 |
vbitset_copy1 (dst, src) |
vbitset_copy1 (bitset dst, bitset src) |
|
bitset dst; |
|
|
bitset src; |
|
384 |
{ |
{ |
385 |
bitset_word *srcp; |
bitset_word *srcp; |
386 |
bitset_word *dstp; |
bitset_word *dstp; |
405 |
|
|
406 |
|
|
407 |
static void |
static void |
408 |
vbitset_not (dst, src) |
vbitset_not (bitset dst, bitset src) |
|
bitset dst; |
|
|
bitset src; |
|
409 |
{ |
{ |
410 |
unsigned int i; |
unsigned int i; |
411 |
bitset_word *srcp; |
bitset_word *srcp; |
430 |
|
|
431 |
|
|
432 |
static bool |
static bool |
433 |
vbitset_equal_p (dst, src) |
vbitset_equal_p (bitset dst, bitset src) |
|
bitset dst; |
|
|
bitset src; |
|
434 |
{ |
{ |
435 |
unsigned int i; |
unsigned int i; |
436 |
bitset_word *srcp = VBITSET_WORDS (src); |
bitset_word *srcp = VBITSET_WORDS (src); |
460 |
|
|
461 |
|
|
462 |
static bool |
static bool |
463 |
vbitset_subset_p (dst, src) |
vbitset_subset_p (bitset dst, bitset src) |
|
bitset dst; |
|
|
bitset src; |
|
464 |
{ |
{ |
465 |
unsigned int i; |
unsigned int i; |
466 |
bitset_word *srcp = VBITSET_WORDS (src); |
bitset_word *srcp = VBITSET_WORDS (src); |
484 |
|
|
485 |
|
|
486 |
static bool |
static bool |
487 |
vbitset_disjoint_p (dst, src) |
vbitset_disjoint_p (bitset dst, bitset src) |
|
bitset dst; |
|
|
bitset src; |
|
488 |
{ |
{ |
489 |
unsigned int i; |
unsigned int i; |
490 |
bitset_word *srcp = VBITSET_WORDS (src); |
bitset_word *srcp = VBITSET_WORDS (src); |
501 |
|
|
502 |
|
|
503 |
static void |
static void |
504 |
vbitset_and (dst, src1, src2) |
vbitset_and (bitset dst, bitset src1, bitset src2) |
|
bitset dst; |
|
|
bitset src1; |
|
|
bitset src2; |
|
505 |
{ |
{ |
506 |
unsigned int i; |
unsigned int i; |
507 |
bitset_word *src1p; |
bitset_word *src1p; |
528 |
|
|
529 |
|
|
530 |
static bool |
static bool |
531 |
vbitset_and_cmp (dst, src1, src2) |
vbitset_and_cmp (bitset dst, bitset src1, bitset src2) |
|
bitset dst; |
|
|
bitset src1; |
|
|
bitset src2; |
|
532 |
{ |
{ |
533 |
unsigned int i; |
unsigned int i; |
534 |
int changed = 0; |
int changed = 0; |
581 |
|
|
582 |
|
|
583 |
static void |
static void |
584 |
vbitset_andn (dst, src1, src2) |
vbitset_andn (bitset dst, bitset src1, bitset src2) |
|
bitset dst; |
|
|
bitset src1; |
|
|
bitset src2; |
|
585 |
{ |
{ |
586 |
unsigned int i; |
unsigned int i; |
587 |
bitset_word *src1p; |
bitset_word *src1p; |
621 |
|
|
622 |
|
|
623 |
static bool |
static bool |
624 |
vbitset_andn_cmp (dst, src1, src2) |
vbitset_andn_cmp (bitset dst, bitset src1, bitset src2) |
|
bitset dst; |
|
|
bitset src1; |
|
|
bitset src2; |
|
625 |
{ |
{ |
626 |
unsigned int i; |
unsigned int i; |
627 |
int changed = 0; |
int changed = 0; |
686 |
|
|
687 |
|
|
688 |
static void |
static void |
689 |
vbitset_or (dst, src1, src2) |
vbitset_or (bitset dst, bitset src1, bitset src2) |
|
bitset dst; |
|
|
bitset src1; |
|
|
bitset src2; |
|
690 |
{ |
{ |
691 |
unsigned int i; |
unsigned int i; |
692 |
bitset_word *src1p; |
bitset_word *src1p; |
722 |
|
|
723 |
|
|
724 |
static bool |
static bool |
725 |
vbitset_or_cmp (dst, src1, src2) |
vbitset_or_cmp (bitset dst, bitset src1, bitset src2) |
|
bitset dst; |
|
|
bitset src1; |
|
|
bitset src2; |
|
726 |
{ |
{ |
727 |
unsigned int i; |
unsigned int i; |
728 |
int changed = 0; |
int changed = 0; |
777 |
|
|
778 |
|
|
779 |
static void |
static void |
780 |
vbitset_xor (dst, src1, src2) |
vbitset_xor (bitset dst, bitset src1, bitset src2) |
|
bitset dst; |
|
|
bitset src1; |
|
|
bitset src2; |
|
781 |
{ |
{ |
782 |
unsigned int i; |
unsigned int i; |
783 |
bitset_word *src1p; |
bitset_word *src1p; |
813 |
|
|
814 |
|
|
815 |
static bool |
static bool |
816 |
vbitset_xor_cmp (dst, src1, src2) |
vbitset_xor_cmp (bitset dst, bitset src1, bitset src2) |
|
bitset dst; |
|
|
bitset src1; |
|
|
bitset src2; |
|
817 |
{ |
{ |
818 |
unsigned int i; |
unsigned int i; |
819 |
int changed = 0; |
int changed = 0; |
871 |
bitsets. */ |
bitsets. */ |
872 |
|
|
873 |
static void |
static void |
874 |
vbitset_and_or (dst, src1, src2, src3) |
vbitset_and_or (bitset dst, bitset src1, bitset src2, bitset src3) |
|
bitset dst; |
|
|
bitset src1; |
|
|
bitset src2; |
|
|
bitset src3; |
|
875 |
{ |
{ |
876 |
unsigned int i; |
unsigned int i; |
877 |
bitset_word *src1p; |
bitset_word *src1p; |
901 |
|
|
902 |
|
|
903 |
static bool |
static bool |
904 |
vbitset_and_or_cmp (dst, src1, src2, src3) |
vbitset_and_or_cmp (bitset dst, bitset src1, bitset src2, bitset src3) |
|
bitset dst; |
|
|
bitset src1; |
|
|
bitset src2; |
|
|
bitset src3; |
|
905 |
{ |
{ |
906 |
unsigned int i; |
unsigned int i; |
907 |
int changed = 0; |
int changed = 0; |
938 |
|
|
939 |
|
|
940 |
static void |
static void |
941 |
vbitset_andn_or (dst, src1, src2, src3) |
vbitset_andn_or (bitset dst, bitset src1, bitset src2, bitset src3) |
|
bitset dst; |
|
|
bitset src1; |
|
|
bitset src2; |
|
|
bitset src3; |
|
942 |
{ |
{ |
943 |
unsigned int i; |
unsigned int i; |
944 |
bitset_word *src1p; |
bitset_word *src1p; |
968 |
|
|
969 |
|
|
970 |
static bool |
static bool |
971 |
vbitset_andn_or_cmp (dst, src1, src2, src3) |
vbitset_andn_or_cmp (bitset dst, bitset src1, bitset src2, bitset src3) |
|
bitset dst; |
|
|
bitset src1; |
|
|
bitset src2; |
|
|
bitset src3; |
|
972 |
{ |
{ |
973 |
unsigned int i; |
unsigned int i; |
974 |
int changed = 0; |
int changed = 0; |
1005 |
|
|
1006 |
|
|
1007 |
static void |
static void |
1008 |
vbitset_or_and (dst, src1, src2, src3) |
vbitset_or_and (bitset dst, bitset src1, bitset src2, bitset src3) |
|
bitset dst; |
|
|
bitset src1; |
|
|
bitset src2; |
|
|
bitset src3; |
|
1009 |
{ |
{ |
1010 |
unsigned int i; |
unsigned int i; |
1011 |
bitset_word *src1p; |
bitset_word *src1p; |
1035 |
|
|
1036 |
|
|
1037 |
static bool |
static bool |
1038 |
vbitset_or_and_cmp (dst, src1, src2, src3) |
vbitset_or_and_cmp (bitset dst, bitset src1, bitset src2, bitset src3) |
|
bitset dst; |
|
|
bitset src1; |
|
|
bitset src2; |
|
|
bitset src3; |
|
1039 |
{ |
{ |
1040 |
unsigned int i; |
unsigned int i; |
1041 |
int changed = 0; |
int changed = 0; |
1072 |
|
|
1073 |
|
|
1074 |
void |
void |
1075 |
vbitset_copy (dst, src) |
vbitset_copy (bitset dst, bitset src) |
|
bitset dst; |
|
|
bitset src; |
|
1076 |
{ |
{ |
1077 |
if (BITSET_COMPATIBLE_ (dst, src)) |
if (BITSET_COMPATIBLE_ (dst, src)) |
1078 |
vbitset_copy1 (dst, src); |
vbitset_copy1 (dst, src); |