Clean-up and use of aligned buffers in Test/
All of the new tests appear to pass.master
parent
07de6b80f8
commit
5eb73fa7d1
BIN
Examples/.swp
BIN
Examples/.swp
Binary file not shown.
|
@ -109,81 +109,80 @@ galois.h: ../galois.h
|
|||
galois.c: ../galois.c
|
||||
rm -f galois.c ; cp ../galois.c . ; chmod 0444 galois.c
|
||||
|
||||
galois.o ${LIBDIR}/gf_complete.a: galois.h
|
||||
jerasure.o: jerasure.h galois.h
|
||||
|
||||
jerasure_01.o: galois.h jerasure.h
|
||||
jerasure_01: jerasure_01.o galois.o ${LIBDIR}/gf_complete.a jerasure.o
|
||||
$(CC) $(CFLAGS) -o jerasure_01 jerasure_01.o jerasure.o galois.o ${LIBDIR}/gf_complete.a
|
||||
jerasure_01: jerasure_01.o galois.o jerasure.o
|
||||
$(CC) $(CFLAGS) -o jerasure_01 jerasure_01.o jerasure.o galois.o -lgf_complete
|
||||
|
||||
jerasure_02.o: galois.h jerasure.h
|
||||
jerasure_02: jerasure_02.o galois.o ${LIBDIR}/gf_complete.a jerasure.o
|
||||
$(CC) $(CFLAGS) -o jerasure_02 jerasure_02.o jerasure.o galois.o ${LIBDIR}/gf_complete.a
|
||||
jerasure_02: jerasure_02.o galois.o jerasure.o
|
||||
$(CC) $(CFLAGS) -o jerasure_02 jerasure_02.o jerasure.o galois.o -lgf_complete
|
||||
|
||||
jerasure_03.o: galois.h jerasure.h
|
||||
jerasure_03: jerasure_03.o galois.o ${LIBDIR}/gf_complete.a jerasure.o
|
||||
$(CC) $(CFLAGS) -o jerasure_03 jerasure_03.o jerasure.o galois.o ${LIBDIR}/gf_complete.a
|
||||
jerasure_03: jerasure_03.o galois.o jerasure.o
|
||||
$(CC) $(CFLAGS) -o jerasure_03 jerasure_03.o jerasure.o galois.o -lgf_complete
|
||||
|
||||
jerasure_04.o: galois.h jerasure.h
|
||||
jerasure_04: jerasure_04.o galois.o ${LIBDIR}/gf_complete.a jerasure.o
|
||||
$(CC) $(CFLAGS) -o jerasure_04 jerasure_04.o jerasure.o galois.o ${LIBDIR}/gf_complete.a
|
||||
jerasure_04: jerasure_04.o galois.o jerasure.o
|
||||
$(CC) $(CFLAGS) -o jerasure_04 jerasure_04.o jerasure.o galois.o -lgf_complete
|
||||
|
||||
jerasure_05.o: galois.h jerasure.h
|
||||
jerasure_05: jerasure_05.o galois.o ${LIBDIR}/gf_complete.a jerasure.o
|
||||
$(CC) $(CFLAGS) -o jerasure_05 jerasure_05.o jerasure.o galois.o ${LIBDIR}/gf_complete.a
|
||||
jerasure_05: jerasure_05.o galois.o jerasure.o
|
||||
$(CC) $(CFLAGS) -o jerasure_05 jerasure_05.o jerasure.o galois.o -lgf_complete
|
||||
|
||||
jerasure_06.o: galois.h jerasure.h
|
||||
jerasure_06: jerasure_06.o galois.o ${LIBDIR}/gf_complete.a jerasure.o
|
||||
$(CC) $(CFLAGS) -o jerasure_06 jerasure_06.o jerasure.o galois.o ${LIBDIR}/gf_complete.a
|
||||
jerasure_06: jerasure_06.o galois.o jerasure.o
|
||||
$(CC) $(CFLAGS) -o jerasure_06 jerasure_06.o jerasure.o galois.o -lgf_complete
|
||||
|
||||
jerasure_07.o: galois.h jerasure.h
|
||||
jerasure_07: jerasure_07.o galois.o ${LIBDIR}/gf_complete.a jerasure.o
|
||||
$(CC) $(CFLAGS) -o jerasure_07 jerasure_07.o jerasure.o galois.o ${LIBDIR}/gf_complete.a
|
||||
jerasure_07: jerasure_07.o galois.o jerasure.o
|
||||
$(CC) $(CFLAGS) -o jerasure_07 jerasure_07.o jerasure.o galois.o -lgf_complete
|
||||
|
||||
jerasure_08.o: galois.h jerasure.h
|
||||
jerasure_08: jerasure_08.o galois.o ${LIBDIR}/gf_complete.a jerasure.o
|
||||
$(CC) $(CFLAGS) -o jerasure_08 jerasure_08.o jerasure.o galois.o ${LIBDIR}/gf_complete.a
|
||||
jerasure_08: jerasure_08.o galois.o jerasure.o
|
||||
$(CC) $(CFLAGS) -o jerasure_08 jerasure_08.o jerasure.o galois.o -lgf_complete
|
||||
|
||||
reed_sol_01.o: galois.h reed_sol.h jerasure.h
|
||||
reed_sol_01: reed_sol_01.o galois.o ${LIBDIR}/gf_complete.a jerasure.o reed_sol.o
|
||||
$(CC) $(CFLAGS) -o reed_sol_01 reed_sol_01.o reed_sol.o jerasure.o galois.o ${LIBDIR}/gf_complete.a
|
||||
reed_sol_01: reed_sol_01.o galois.o jerasure.o reed_sol.o
|
||||
$(CC) $(CFLAGS) -o reed_sol_01 reed_sol_01.o reed_sol.o jerasure.o galois.o -lgf_complete
|
||||
|
||||
reed_sol_02.o: galois.h reed_sol.h jerasure.h
|
||||
reed_sol_02: reed_sol_02.o galois.o ${LIBDIR}/gf_complete.a jerasure.o reed_sol.o
|
||||
$(CC) $(CFLAGS) -o reed_sol_02 reed_sol_02.o reed_sol.o jerasure.o galois.o ${LIBDIR}/gf_complete.a
|
||||
reed_sol_02: reed_sol_02.o galois.o jerasure.o reed_sol.o
|
||||
$(CC) $(CFLAGS) -o reed_sol_02 reed_sol_02.o reed_sol.o jerasure.o galois.o -lgf_complete
|
||||
|
||||
reed_sol_03.o: galois.h reed_sol.h jerasure.h
|
||||
reed_sol_03: reed_sol_03.o galois.o ${LIBDIR}/gf_complete.a jerasure.o reed_sol.o
|
||||
$(CC) $(CFLAGS) -o reed_sol_03 reed_sol_03.o reed_sol.o jerasure.o galois.o ${LIBDIR}/gf_complete.a
|
||||
reed_sol_03: reed_sol_03.o galois.o jerasure.o reed_sol.o
|
||||
$(CC) $(CFLAGS) -o reed_sol_03 reed_sol_03.o reed_sol.o jerasure.o galois.o -lgf_complete
|
||||
|
||||
reed_sol_04.o: galois.h reed_sol.h jerasure.h
|
||||
reed_sol_04: reed_sol_04.o galois.o ${LIBDIR}/gf_complete.a jerasure.o reed_sol.o
|
||||
$(CC) $(CFLAGS) -o reed_sol_04 reed_sol_04.o reed_sol.o jerasure.o galois.o ${LIBDIR}/gf_complete.a
|
||||
reed_sol_04: reed_sol_04.o galois.o jerasure.o reed_sol.o
|
||||
$(CC) $(CFLAGS) -o reed_sol_04 reed_sol_04.o reed_sol.o jerasure.o galois.o -lgf_complete
|
||||
|
||||
cauchy_01.o: galois.h cauchy.h jerasure.h
|
||||
cauchy_01: cauchy_01.o galois.o ${LIBDIR}/gf_complete.a jerasure.o cauchy.o
|
||||
$(CC) $(CFLAGS) -o cauchy_01 cauchy_01.o cauchy.o jerasure.o galois.o ${LIBDIR}/gf_complete.a
|
||||
cauchy_01: cauchy_01.o galois.o jerasure.o cauchy.o
|
||||
$(CC) $(CFLAGS) -o cauchy_01 cauchy_01.o cauchy.o jerasure.o galois.o -lgf_complete
|
||||
|
||||
cauchy_02.o: galois.h cauchy.h jerasure.h
|
||||
cauchy_02: cauchy_02.o galois.o ${LIBDIR}/gf_complete.a jerasure.o cauchy.o
|
||||
$(CC) $(CFLAGS) -o cauchy_02 cauchy_02.o cauchy.o jerasure.o galois.o ${LIBDIR}/gf_complete.a
|
||||
cauchy_02: cauchy_02.o galois.o jerasure.o cauchy.o
|
||||
$(CC) $(CFLAGS) -o cauchy_02 cauchy_02.o cauchy.o jerasure.o galois.o -lgf_complete
|
||||
|
||||
cauchy_03.o: galois.h cauchy.h jerasure.h
|
||||
cauchy_03: cauchy_03.o galois.o ${LIBDIR}/gf_complete.a jerasure.o cauchy.o
|
||||
$(CC) $(CFLAGS) -o cauchy_03 cauchy_03.o cauchy.o jerasure.o galois.o ${LIBDIR}/gf_complete.a
|
||||
cauchy_03: cauchy_03.o galois.o jerasure.o cauchy.o
|
||||
$(CC) $(CFLAGS) -o cauchy_03 cauchy_03.o cauchy.o jerasure.o galois.o -lgf_complete
|
||||
|
||||
cauchy_04.o: galois.h cauchy.h jerasure.h
|
||||
cauchy_04: cauchy_04.o galois.o ${LIBDIR}/gf_complete.a jerasure.o cauchy.o
|
||||
$(CC) $(CFLAGS) -o cauchy_04 cauchy_04.o cauchy.o jerasure.o galois.o ${LIBDIR}/gf_complete.a
|
||||
cauchy_04: cauchy_04.o galois.o jerasure.o cauchy.o
|
||||
$(CC) $(CFLAGS) -o cauchy_04 cauchy_04.o cauchy.o jerasure.o galois.o -lgf_complete
|
||||
|
||||
liberation_01.o: galois.h liberation.h jerasure.h
|
||||
liberation_01: liberation_01.o galois.o ${LIBDIR}/gf_complete.a jerasure.o liberation.o
|
||||
$(CC) $(CFLAGS) -o liberation_01 liberation_01.o liberation.o jerasure.o galois.o ${LIBDIR}/gf_complete.a
|
||||
liberation_01: liberation_01.o galois.o jerasure.o liberation.o
|
||||
$(CC) $(CFLAGS) -o liberation_01 liberation_01.o liberation.o jerasure.o galois.o -lgf_complete
|
||||
|
||||
encoder.o: galois.h liberation.h jerasure.h reed_sol.h cauchy.h
|
||||
encoder: encoder.o galois.o ${LIBDIR}/gf_complete.a jerasure.o liberation.o reed_sol.o cauchy.o
|
||||
$(CC) $(CFLAGS) -o encoder encoder.o liberation.o jerasure.o galois.o ${LIBDIR}/gf_complete.a reed_sol.o cauchy.o
|
||||
encoder: encoder.o galois.o jerasure.o liberation.o reed_sol.o cauchy.o
|
||||
$(CC) $(CFLAGS) -o encoder encoder.o liberation.o jerasure.o galois.o reed_sol.o cauchy.o -lgf_complete
|
||||
|
||||
decoder.o: galois.h liberation.h jerasure.h reed_sol.h cauchy.h
|
||||
decoder: decoder.o galois.o ${LIBDIR}/gf_complete.a jerasure.o liberation.o reed_sol.o cauchy.o
|
||||
$(CC) $(CFLAGS) -o decoder decoder.o liberation.o jerasure.o galois.o ${LIBDIR}/gf_complete.a reed_sol.o cauchy.o
|
||||
decoder: decoder.o galois.o jerasure.o liberation.o reed_sol.o cauchy.o
|
||||
$(CC) $(CFLAGS) -o decoder decoder.o liberation.o jerasure.o galois.o reed_sol.o cauchy.o -lgf_complete
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
Copyright (c) 2011, James S. Plank
|
||||
All rights reserved.
|
||||
|
||||
Revision 2.0
|
||||
Nov, 18 2013 (Kevin Greenan and James S. Plank)
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions
|
||||
are met:
|
||||
|
|
|
@ -59,7 +59,18 @@ POSSIBILITY OF SUCH DAMAGE.
|
|||
|
||||
#define BUFSIZE 4096
|
||||
|
||||
#define talloc(type, num) (type *) valloc(sizeof(type)*(num))
|
||||
static void *malloc16(int size) {
|
||||
void *mem = malloc(size+16+sizeof(void*));
|
||||
void **ptr = (void**)((long)(mem+16+sizeof(void*)) & ~(15));
|
||||
ptr[-1] = mem;
|
||||
return ptr;
|
||||
}
|
||||
|
||||
static void free16(void *ptr) {
|
||||
free(((void**)ptr)[-1]);
|
||||
}
|
||||
|
||||
#define talloc(type, num) (type *) malloc16(sizeof(type)*(num))
|
||||
|
||||
usage(char *s)
|
||||
{
|
||||
|
|
|
@ -57,7 +57,18 @@ POSSIBILITY OF SUCH DAMAGE.
|
|||
#include "jerasure.h"
|
||||
#include "reed_sol.h"
|
||||
|
||||
#define talloc(type, num) (type *) valloc(sizeof(type)*(num))
|
||||
static void *malloc16(int size) {
|
||||
void *mem = malloc(size+16+sizeof(void*));
|
||||
void **ptr = (void**)((long)(mem+16+sizeof(void*)) & ~(15));
|
||||
ptr[-1] = mem;
|
||||
return ptr;
|
||||
}
|
||||
|
||||
static void free16(void *ptr) {
|
||||
free(((void**)ptr)[-1]);
|
||||
}
|
||||
|
||||
#define talloc(type, num) (type *) malloc16(sizeof(type)*(num))
|
||||
|
||||
void
|
||||
timer_start (double *t)
|
||||
|
|
|
@ -70,7 +70,7 @@ lib/libJerasure.so: lib/libJerasure.so.0
|
|||
|
||||
lib/libJerasure.so.0: lib $(OBJS)
|
||||
$(CC) $(LIBARGS) \
|
||||
-o lib/libJerasure.so.0 $(OBJS) ${LIBDIR}/gf_complete.a
|
||||
-o lib/libJerasure.so.0 $(OBJS) -lgf_complete
|
||||
|
||||
install: lib/libJerasure.so
|
||||
cp -P lib/libJerasure.so* ${LIBDIR}
|
||||
|
|
Loading…
Reference in New Issue