aboutsummaryrefslogtreecommitdiffstats
path: root/checklink/Bitstring_utils.ml
diff options
context:
space:
mode:
authorBernhard Schommer <bernhardschommer@gmail.com>2015-10-20 14:45:56 +0200
committerBernhard Schommer <bernhardschommer@gmail.com>2015-10-20 14:45:56 +0200
commited6043fe910f7a320f7af6d3f9d35f39f5cf7ee1 (patch)
tree3fab134f5444f0472a1ff8c06e5b7686a40648dc /checklink/Bitstring_utils.ml
parent4d542bc7eafadb16b845cf05d1eb4988eb55ed0f (diff)
parent8a95c3e07fd02eaa87f8cca447bc7d7c2642eb22 (diff)
downloadcompcert-ed6043fe910f7a320f7af6d3f9d35f39f5cf7ee1.tar.gz
compcert-ed6043fe910f7a320f7af6d3f9d35f39f5cf7ee1.zip
Merge remote-tracking branch 'origin/master' into named-externals
Conflicts: arm/TargetPrinter.ml backend/CMparser.mly backend/SelectLongproof.v backend/Selectionproof.v cfrontend/C2C.ml checklink/Asm_printers.ml checklink/Check.ml checklink/Fuzz.ml common/AST.v debug/DebugInformation.ml debug/DebugInit.ml debug/DwarfPrinter.ml debug/DwarfTypes.mli debug/Dwarfgen.ml exportclight/ExportClight.ml ia32/TargetPrinter.ml powerpc/Asm.v powerpc/SelectOpproof.v powerpc/TargetPrinter.ml
Diffstat (limited to 'checklink/Bitstring_utils.ml')
-rw-r--r--checklink/Bitstring_utils.ml33
1 files changed, 0 insertions, 33 deletions
diff --git a/checklink/Bitstring_utils.ml b/checklink/Bitstring_utils.ml
deleted file mode 100644
index 3218f898..00000000
--- a/checklink/Bitstring_utils.ml
+++ /dev/null
@@ -1,33 +0,0 @@
-(** Note that a bitstring is a triple (string * int * int), where the string
- contains the contents (the last char is filled up with zeros if necessary),
- the firts int gives the first bit to consider, and the second int gives the
- bit length of the considered bitstring.
-*)
-type bitstring = Bitstring.bitstring
-
-(** Checks whether a given number of bits of a bitstring are zeroed. The
- bitstring may be longer.
- @param size number of bits to check
-*)
-
-let is_zeros (bs: bitstring) (size: int): bool =
- Bitstring.bitstring_length bs >= size
- && Bitstring.is_zeroes_bitstring (Bitstring.subbitstring bs 0 size)
-
-(*
-
-let rec is_zeros (bs: bitstring) (size: int): bool =
- size = 0 ||
- if size >= 64
- then (
- bitmatch bs with
- | { 0L : 64 : int ; rest : -1 : bitstring } ->
- is_zeros rest (size - 64)
- | { _ } -> false
- )
- else (
- bitmatch bs with
- | { 0L : size : int } -> true
- | { _ } -> false
- )
-*)