Commit Graph

315 Commits

Author SHA1 Message Date
Joe Taylor
b01fb32aea Some variables now need to be saved explicitly to maintain value
betweek subsoutine calls.


git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4939 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-02-06 15:18:38 +00:00
Bill Somerville
1271243952 Thread safe lib/timer.f90
Accounts for each traced call per thread and accumulates by rolling up
calls with an identical call chain before printing the statistics. The
print now accounts for function calls  in their call chain so the same
function will be reported more than  once if it is called in different
places.

git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4937 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-02-05 22:07:19 +00:00
Joe Taylor
6582f5410c Increase JT65 decoding depth at QSO frequency.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4936 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-02-05 17:43:43 +00:00
Joe Taylor
5de52a2516 Better to set nflatten=0 here, for command-line speed tests.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4935 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-02-04 21:42:49 +00:00
Joe Taylor
06c83c580d Make array sizes in downsam9 consistent with the new big FFT length.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4934 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-02-04 21:26:58 +00:00
Bill Somerville
01626eeaa3 Only use >1 thread for the biggest FFTs
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4933 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-02-04 20:52:42 +00:00
Joe Taylor
73a69499e4 Make the symspec() call in jt9.for consistent with that from mainwindow.cpp.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4932 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-02-04 19:52:37 +00:00
Bill Somerville
36ad50735b Fix typo that disabled JT65 decoding in dual mode.
Disable timer.out generation in OpenMP builds as it is broken.

git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4931 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-02-04 16:33:45 +00:00
Bill Somerville
a7c4d1001f Adjust the jt9 decoder to do the right decodes in parallel
Also limit the required threads for parallel decoding to 2.

git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4930 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-02-04 15:34:46 +00:00
Joe Taylor
c7faf40d34 Need space for more calls to timer().
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4929 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-02-04 15:05:39 +00:00
Bill Somerville
91b909b581 Thread safety enhancements to jt9
Serialize thread unsafe FFTW3 calls

Serialize FFTW3 plan initializations in four2a

Serialize decoder results output to file/console

git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4928 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-02-04 01:41:26 +00:00
Joe Taylor
16452ae32f Add rfilt and df to the "save" list in filbig.f90.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4927 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-02-04 00:37:33 +00:00
Joe Taylor
010f85ec70 Further algorithmic tweaks in the JT9 decoder.
More detailed message to come, with comparative timing statistics.


git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4926 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-02-02 18:29:00 +00:00
Bill Somerville
e791efb5b8 First attempt at a thread safe lib/timer.f90
This  tries  to  account  for  function  calls  in  different  threads
separately by decorating  the function name with the  thread number it
is  running in.  This may  not be  the best  strategy for  performance
timing but it is  the easiest way of making it thread  safe that I can
see.

git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4924 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-02-02 14:08:17 +00:00
Bill Somerville
ffdeafe3bb Build an OpenMP version of jt9 where possible
This change  introduces the program jt9_omp  which is a testbed  for a
multi-threaded version of the jt9 decoder program. The program jt9_omp
should be  a directly substitutable for  jt9 except that JT65  and JT9
decodes are computed in parallel.

Also enable  the OpenMP directives in  decoder.f90 - note this  is not
yet a working multi-threaded decoder and the existing jt9 is still the
correct decoder to be used in WSJT-X.

Increased the available  stack size for jt9_omp.exe as this  is a hard
limit on  Windows and  the default  is not big  enough for  the OpenMP
version of jt9.

Also  Fortran  array  bounds  checking is  now  disabled  for  Release
configuration builds so as to improve performance a little.

git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4922 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-02-02 11:24:20 +00:00
Joe Taylor
3d112ab26c Change some calls to timer().
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4921 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-02-01 20:11:10 +00:00
Joe Taylor
630ec94aaa Forgot to commit decjt9.f90.
Also note: something's wrong when trying to decode a file read 
by the GUI from disk.  Will fix it soon...



git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4920 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-02-01 17:40:14 +00:00
Joe Taylor
94472ac31c Many changes in program jt9[.exe] aimed at speeding up the decoders.
The long FFTs can now use the multi-threaded FFTW routines.
Subroutine decode9.f90 was renamed jt9fano.f90.
The JT9 decoder's top-level functions were removed from decoder.f90
and put into a separate subroutine decjt90.f90.
Subroutine decoder.f90 is now configured for possible use of OpenMP 
SECTIONS, with the JT9 and JT65 decoders running concurrently on
a multi-core machine.  Note, however, that this concurrent processing 
is not yet fully implemented.  Probably calls to timer need to be removed; 
some variables used in calls to jt65a and decjt9 may need to be 
declared PRIVATE in decoder; some sections probably need to be declared 
CRITICAL; probably some SAVE statements in downstream routines have
made them not thread-safe; etc., etc.  

I'm a neophyte at using OpenMP.  Comments, suggestions, and/or tests by
others will be welcome!



git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4919 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-02-01 16:23:36 +00:00
Joe Taylor
3a8232b113 Made a start at implementing an option to use multi-threaded FFTs.
New command-line option for jt9: [-m nthreads].  Default is nthreads=1.
Also refactored a loop in filbig.f90 that was taking far too much
time.


git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4916 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-01-30 21:28:10 +00:00
Joe Taylor
72305cf10f Allow use on nonthreading model by setting nthreads=0.
Require at least 10 iterations.


git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4915 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-01-30 01:45:37 +00:00
Joe Taylor
d8f8c0c809 More minor cleanup.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4914 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-01-29 20:50:05 +00:00
Joe Taylor
647ae961fa Set compiler flags.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4913 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-01-29 19:17:56 +00:00
Joe Taylor
00e8a7a0c8 Clean up compiler warnings.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4912 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-01-29 19:16:37 +00:00
Joe Taylor
776c78544d Another tweak.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4911 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-01-29 18:49:40 +00:00
Joe Taylor
d10194bb54 Remove diagnostic print.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4910 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-01-29 18:46:46 +00:00
Joe Taylor
9a9c814e13 Minor tweaks.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4909 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-01-29 18:38:51 +00:00
Joe Taylor
104f001590 More testing of FFTW performance...
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4908 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-01-29 18:29:41 +00:00
Joe Taylor
cbeed6b053 Testing some newer FFTW features.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4907 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2015-01-28 12:52:24 +00:00
Joe Taylor
a4897b696b Add nfft.out (output from chkfft, on a Dell laptop).
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4848 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-12-22 14:06:40 +00:00
Joe Taylor
d338885098 Some final(?) tweaks and additions to the chkfft mini-package.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4838 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-12-18 21:06:21 +00:00
Joe Taylor
c628013582 A few more tweaks, and add the file nfft.dat of efficient FFT lengths.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4837 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-12-18 20:53:16 +00:00
Joe Taylor
1889b24c78 Several tweaks to chkfft.f90. Add descriptive file chkfft.txt.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4836 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-12-18 20:34:06 +00:00
Joe Taylor
22e15084e1 Add chkfft.f90; more thorough comments in four2a.f90.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4835 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-12-18 16:41:18 +00:00
Bill Somerville
f37ed4cd78 Take advantage of the new KVASD v1.12
Pass the  temporary directory to  jt9 and use  it to give  the correct
paths  to  temporary files.  Also  jt9  passes  the absolute  path  to
kvasd.dat in the temporary directory to kvasd.

Clear out all the annoying cruft that has accumulated due to having to
run with $CWD as the temporary directory.

Use QStandardPaths  to find the  writable data directory  where needed
rather than passing it around  between objects. This now works because
the $CWD hasn't been changed.

Do away with the CMake option WSJT_STANDARD_FILE_LOCATIONS as it is no
longer needed.

Fix astro status file azel.dat formatting.

git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4732 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-12-03 00:06:54 +00:00
Joe Taylor
e8c59114db Update the linux Makefile for qmake/make builds.
Minor correction for wsjtx man page.


git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4635 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-11-24 14:54:47 +00:00
Joe Taylor
021f677687 Add wisdom for the FFTs done by symspec_(), wsjtx[.exe].
Also complete the wrapper code in wisdom.c.
TBD: should be possible to use fftw3f.f03 instead of the ad hoc wisdom.c.


git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4617 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-11-21 15:17:22 +00:00
Joe Taylor
20ded259d8 Decode from disk sets npatience = 2.
This means that the first decode from a saved data file will be slow,
but the saved wisdom for the decoded mode(s) will be better than
for the default npatience = 1.  All subsequent decodes in the same 
mode(s) will take advantage of the newly saved wisdom.



git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4616 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-11-21 01:40:24 +00:00
Joe Taylor
2bc824b4a5 Try a home-made wrapper for fftwf_export_wisdom_to_filename().
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4614 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-11-21 00:44:50 +00:00
Joe Taylor
3a5edb5af5 FFTW wisdom is now built into jt9[.exe].
New optional argument to jt9: -w patience
Default is patience = 1

Example timing measurements for 130610_2343.wav:

patience  plan   execute
          (s)      (s)
-----------------------------------------------
   0      0.01     1.25  FFTW_ESTIMATE
   1      0.69     1.25  FFTW_ESTIMATE_PATIENT
   2     16.97     1.15  FFTW_MEASURE
   3    390.88     1.15  FFTW_PATIENT

Conclusions, consistent with expectation based on past experience
with similar FFTs:
  - First decode (in each mode) with patience = 2 is slow.
  - Speed advantage of patience = 2 is small but measurable.
  - No measurable advantage in using patience > 2.

Present mainwindow.cpp has "-w 1" hard-wired.


git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4610 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-11-20 18:48:53 +00:00
Joe Taylor
b3f4432f67 Correct the logic for negative-frequency index into new ca array.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4609 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-11-19 20:17:15 +00:00
Joe Taylor
f07a960e2d Several decoder optimizations, including implementation of FFTW wisdom.
Notes:
1. Equivalents of wisdom1.bat will be needed for *nix and OS X.  (The
   version now added to the source .../lib directory is an example only.)
2. Installers should offer to run the wisdom1[.bat] script at installation
   time.
3. wisdom1[.bat] and fftwf-wisdom[.exe] must be installed in .../bin directory 



git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4607 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-11-19 17:23:57 +00:00
Joe Taylor
4fea8ebd0c Optimizations of JT9 and JT65 decoders; change clock in timer routine.
Both decoders now have slightly better performance and faster
execution.  The rare "duplicate decodes" in JT9 were eliminated.
On Windows, at least, calls to f90 routine system_clock() do not
provide correct wall time increments.  Changed to using secnds()
instead.


git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4571 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-10-30 19:29:16 +00:00
Joe Taylor
3dec8d4d97 Adding programmer comments to decoding routines.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4558 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-10-24 21:43:43 +00:00
Bill Somerville
0ee86f63b5 Added new library source
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4553 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-10-21 14:21:24 +00:00
Bill Somerville
1ff68d5098 Make/qmake tweaks
The lib/Makefile.MinGW makefile  has been enhanced to link  to the DLL
version of fftw3  which is the normal version of  the library that you
get with the Windows installer.

The library is  located by passing the FFTW3_DIR variable  on the make
command line. For example on my system:

	$ # In a MinGW console
	$ cd ~/src/wsjtx/lib
	$ make QT_DIR=/c/Tools/Qt/5.2.1/mingw48_32 \
	>  FFTW3_DIR=/c/Tools/fftw-3.3.3-dll32-2

Similarly with the qmake project:

	$ # In a Qt MinGW 32-bit console
	$ cd ~/src/wsjtx
	$ qmake \
	>  HAMLIB_DIR=c:/test-install/hamlib/mingw48_32 \
	>  FFTW3_DIR=c:/Tools/fftw-3.3.3-dll32-2
	$ mingw32-make



git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4551 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-10-21 13:47:19 +00:00
Bill Somerville
5a56cbdedb Tidy up unused files and move platform specific files
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4549 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-10-20 18:01:21 +00:00
Joe Taylor
a47f3cb9fe Remove two unused routines. Remove declaration of unused variable.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4544 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-10-20 13:04:29 +00:00
Joe Taylor
8a6694f9b4 Remove a bad test message from jt9code.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4540 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-10-19 12:29:45 +00:00
Joe Taylor
d110a5fbcf Update the "Usage" messages for jt65code and jt9code.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4537 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-10-19 01:31:17 +00:00
Joe Taylor
c6fea4af05 Build a list of test messages into jt9code and jt65code.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4536 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2014-10-19 01:29:30 +00:00