From fa25c8f3df6791727b9384c9b405c996ac68b8ab Mon Sep 17 00:00:00 2001 From: Nicholas Noll Date: Fri, 15 May 2020 18:11:58 -0700 Subject: feat: added buffered io to libn --- sys/libbio/test.c | 18 ------------------ 1 file changed, 18 deletions(-) (limited to 'sys/libbio/test.c') diff --git a/sys/libbio/test.c b/sys/libbio/test.c index da29c84..b7cbae1 100644 --- a/sys/libbio/test.c +++ b/sys/libbio/test.c @@ -3,7 +3,6 @@ #include #include -#include "kseq.h" // ----------------------------------------------------------------------- // Global data @@ -83,8 +82,6 @@ my_read(Stream *s, void *buf, int n) return io·read(s, 1, n, buf); } -KSEQ_INIT(Stream*, my_read) - // ----------------------------------------------------------------------- // Point of entry for testing @@ -198,23 +195,8 @@ test·fastq() clock_t t; - int n, slen; - kseq_t *kseq; - fd = io·open("/home/nolln/root/data/test/eg.fq", "r"); - t = clock(); - kseq = kseq_init(fd); - while (kseq_read(kseq) >= 0) { - ++n, slen += kseq->seq.l; - } - t = clock() - t; - printf("heng's fastq code took %f ms to execute\n", 1000.*t/CLOCKS_PER_SEC); - - kseq_destroy(kseq); - - io·seek(fd, 0, seek·set); - rdr = bio·openfastq((io·Reader){.read = &io·read}, fd, mem·sys, nil); t = clock(); -- cgit v1.2.1