Blame lib/bitsetv.h

Packit d6cc65
/* Bitset vectors.
Packit d6cc65
Packit d6cc65
   Copyright (C) 2002, 2004, 2009-2015 Free Software Foundation, Inc.
Packit d6cc65
Packit d6cc65
   Contributed by Michael Hayes (m.hayes@elec.canterbury.ac.nz).
Packit d6cc65
Packit d6cc65
   This program is free software: you can redistribute it and/or modify
Packit d6cc65
   it under the terms of the GNU General Public License as published by
Packit d6cc65
   the Free Software Foundation, either version 3 of the License, or
Packit d6cc65
   (at your option) any later version.
Packit d6cc65
Packit d6cc65
   This program is distributed in the hope that it will be useful,
Packit d6cc65
   but WITHOUT ANY WARRANTY; without even the implied warranty of
Packit d6cc65
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
Packit d6cc65
   GNU General Public License for more details.
Packit d6cc65
Packit d6cc65
   You should have received a copy of the GNU General Public License
Packit d6cc65
   along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
Packit d6cc65
Packit d6cc65
#ifndef _BITSETV_H
Packit d6cc65
#define _BITSETV_H
Packit d6cc65
Packit d6cc65
#include "bitset.h"
Packit d6cc65
Packit d6cc65
typedef bitset * bitsetv;
Packit d6cc65
Packit d6cc65
/* Create a vector of N_VECS bitsets, each of N_BITS, and of
Packit d6cc65
   type TYPE.  */
Packit d6cc65
extern bitsetv bitsetv_alloc (bitset_bindex, bitset_bindex, enum bitset_type);
Packit d6cc65
Packit d6cc65
/* Create a vector of N_VECS bitsets, each of N_BITS, and with
Packit d6cc65
   attribute hints specified by ATTR.  */
Packit d6cc65
extern bitsetv bitsetv_create (bitset_bindex, bitset_bindex, unsigned int);
Packit d6cc65
Packit d6cc65
/* Free vector of bitsets.  */
Packit d6cc65
extern void bitsetv_free (bitsetv);
Packit d6cc65
Packit d6cc65
/* Zero vector of bitsets.  */
Packit d6cc65
extern void bitsetv_zero (bitsetv);
Packit d6cc65
Packit d6cc65
/* Set vector of bitsets.  */
Packit d6cc65
extern void bitsetv_ones (bitsetv);
Packit d6cc65
Packit d6cc65
/* Given a vector BSETV of N bitsets of size N, modify its contents to
Packit d6cc65
   be the transitive closure of what was given.  */
Packit d6cc65
extern void bitsetv_transitive_closure (bitsetv);
Packit d6cc65
Packit d6cc65
/* Given a vector BSETV of N bitsets of size N, modify its contents to
Packit d6cc65
   be the reflexive transitive closure of what was given.  This is
Packit d6cc65
   the same as transitive closure but with all bits on the diagonal
Packit d6cc65
   of the bit matrix set.  */
Packit d6cc65
extern void bitsetv_reflexive_transitive_closure (bitsetv);
Packit d6cc65
Packit d6cc65
/* Dump vector of bitsets.  */
Packit d6cc65
extern void bitsetv_dump (FILE *, const char *, const char *, bitsetv);
Packit d6cc65
Packit d6cc65
/* Function to debug vector of bitsets from debugger.  */
Packit d6cc65
extern void debug_bitsetv (bitsetv);
Packit d6cc65
Packit d6cc65
#endif  /* _BITSETV_H  */