Skip to content

Commit

Permalink
address review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
mreineck committed Nov 5, 2024
1 parent 3be6f0a commit cd3ca5a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
7 changes: 5 additions & 2 deletions makefile
Original file line number Diff line number Diff line change
Expand Up @@ -175,10 +175,10 @@ usage:
@echo "Also see docs/install.rst and docs/README"

# collect headers for implicit depends (we don't separate public from private)
HEADERS = $(wildcard include/*.h include/finufft/*.h) $(DUCC_HEADERS)
HEADERS = $(wildcard include/*.h include/finufft/*.h)

# implicit rules for objects (note -o ensures writes to correct dir)
%.o: %.cpp $(HEADERS) $(XSIMD_DIR)/include/xsimd/xsimd.hpp
%.o: %.cpp $(HEADERS)
$(CXX) -c $(CXXFLAGS) $< -o $@
%.o: %.c $(HEADERS)
$(CC) -c $(CFLAGS) $< -o $@
Expand All @@ -194,6 +194,9 @@ include/finufft/fft.h: $(DUCC_SETUP)
SHEAD = $(wildcard src/*.h) $(XSIMD_DIR)/include/xsimd/xsimd.hpp
src/spreadinterp.o: $(SHEAD)

# we need xsimd functionality in finufft_core.h, which is included by many other
# files, so make sure we install xsimd before we prcess any of those files.
include/finufft/finufft_core.h: $(XSIMD_DIR)/include/xsimd/xsimd.hpp

# lib -----------------------------------------------------------------------
# build library with double/single prec both bundled in...
Expand Down
6 changes: 3 additions & 3 deletions src/finufft_core.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -548,7 +548,7 @@ FINUFFT_PLAN_T<TF>::FINUFFT_PLAN_T(int type_, int dim_, const BIGINT *n_modes, i
if (!opts_) // use default opts
finufft_default_opts_t(&opts);
else // or read from what's passed in
opts = *opts_; // keep a deep copy; changing *opts now has no effect
opts = *opts_; // keep a deep copy; changing *opts_ now has no effect

if (opts.debug) // do a hello world
printf("[%s] new plan: FINUFFT version " FINUFFT_VER " .................\n",
Expand Down Expand Up @@ -907,9 +907,9 @@ int FINUFFT_PLAN_T<TF>::setpts(BIGINT nj, TF *xj, TF *yj, TF *zj, BIGINT nk, TF
}
} else
for (BIGINT j = 0; j < nj; ++j)
prephase[j] = {1, 0}; // *** or keep flag so no mult in exec??
prephase[j] = {1.0, 0.0}; // *** or keep flag so no mult in exec??

// rescale the target s_k etc to s'_k etc...
// rescale the target s_k etc to s'_k etc...
#pragma omp parallel for num_threads(opts.nthreads) schedule(static)
for (BIGINT k = 0; k < nk; ++k) {
Sp[k] = t3P.h1 * t3P.gam1 * (s[k] - t3P.D1); // so |s'_k| < pi/R
Expand Down

0 comments on commit cd3ca5a

Please sign in to comment.