Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions cc.R
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,9 @@ cc = function(test=TRUE, clean=FALSE, debug=FALSE, omp=!debug, cc_dir=Sys.getenv
if (clean) system("rm *.o *.so")
OMP = if (omp) "" else "no-"
if (debug) {
ret = system(sprintf("MAKEFLAGS='-j CC=%s PKG_CFLAGS=-f%sopenmp CFLAGS=-std=c99\\ -O0\\ -ggdb\\ -pedantic' R CMD SHLIB -d -o data.table.so *.c", CC, OMP))
ret = system(sprintf("MAKEFLAGS='-j CC=%s PKG_CFLAGS=-f%sopenmp CFLAGS=-std=c99\\ -O0\\ -ggdb\\ -pedantic\\ -flto' R CMD SHLIB -d -o data.table.so *.c", CC, OMP))
} else {
ret = system(sprintf("MAKEFLAGS='-j CC=%s CFLAGS=-f%sopenmp\\ -std=c99\\ -O3\\ -pipe\\ -Wall\\ -pedantic' R CMD SHLIB -o data.table.so *.c", CC, OMP))
ret = system(sprintf("MAKEFLAGS='-j CC=%s CFLAGS=-f%sopenmp\\ -std=c99\\ -O3\\ -pipe\\ -Wall\\ -pedantic\\ -flto' R CMD SHLIB -o data.table.so *.c", CC, OMP))
# TODO add -Wextra too?
}
if (ret) return()
Expand Down
6 changes: 3 additions & 3 deletions src/fwrite.c
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,12 @@ static int8_t doQuote=INT8_MIN; // whether to surround fields with double
static bool qmethodEscape=false; // when quoting fields, how to escape double quotes in the field contents (default false means to add another double quote)
static bool squashDateTime=false; // 0=ISO(yyyy-mm-dd) 1=squash(yyyymmdd)

extern const char *getString(void *, int);
extern const int getStringLen(void *, int);
extern const char *getString(void *, int64_t);
extern const int getStringLen(void *, int64_t);
extern const int getMaxStringLen(void *, int64_t);
extern const int getMaxCategLen(void *);
extern const int getMaxListItemLen(void *, int64_t);
extern const char *getCategString(void *, int);
extern const char *getCategString(void *, int64_t);
extern double wallclock(void);

inline void write_chars(const char *x, char **pch)
Expand Down