90 Commits

Author SHA1 Message Date
Arvid Norberg
c047f66454 improved disk buffer logging and added extra asserts when logging disk buffer stats 2009-05-19 07:00:05 +00:00
Arvid Norberg
062e1796c0 fixed crash when shutting down while checking a torrent 2009-05-13 17:17:33 +00:00
Arvid Norberg
85bf463e11 added session setting to control disk buffer pool allocation sizes 2009-05-12 18:52:05 +00:00
Arvid Norberg
039ee486af use alloca for iovec arrays 2009-05-12 17:56:12 +00:00
Arvid Norberg
89e4c41ea2 fixed indentation 2009-05-11 21:19:03 +00:00
Arvid Norberg
1eb2799a03 added more allocation logging for statistics builds. Identified and fixed some memory waste 2009-05-07 20:30:20 +00:00
Arvid Norberg
838df44184 documented file_rename_failed_alert and file_renamed_alert. they were previously not documented. Fixed bug where the storage would be left in an error state (and eventually pause the torrent) when a rename_file() failed. The error is now only reported back through the alert 2009-05-07 06:41:41 +00:00
Arvid Norberg
ff3db926fb allocates 10 disk buffers at a time instead of 32. Fixed bug where connection candidates would be too high 2009-05-06 07:06:26 +00:00
Arvid Norberg
cf6dc377c9 define fixes for disk stats build configurations 2009-05-04 06:42:24 +00:00
Arvid Norberg
641abc6c4a slight memory optimization and some header cleanup 2009-05-03 20:21:24 +00:00
Arvid Norberg
807c1fc397 added validation check to disk_buffer_pool (and disk_io_thread in 0.14). This should catch any reference to the disk_io_thread after it has been destructed 2009-05-03 03:16:15 +00:00
Arvid Norberg
e4ddb13b6f made the cache_size setting include send and receive buffers 2009-05-02 06:52:57 +00:00
Arvid Norberg
033fd5bd22 count send and receive buffers against the cache size limit 2009-05-01 08:00:58 +00:00
Arvid Norberg
509c8ed402 timed_wait does not seem to work as expected, revert to regular wait() 2009-04-15 16:32:05 +00:00
Arvid Norberg
91ba36a396 added compile time option for mlock support 2009-03-31 08:15:21 +00:00
Arvid Norberg
c6017f9366 reverted bug introduced a few check-ins ago. Fixed case when recursive_copy fails (don't remove the original files). Cleaned up callback dispatching in disk_io_thread in trunk. Improved unit tests for move_storage 2009-03-31 08:05:46 +00:00
Arvid Norberg
36eb9c4f51 move storage fix 2009-03-30 04:55:23 +00:00
Arvid Norberg
af10b55254 wakes up the disk io thread once a second to flush caches 2009-03-14 09:24:58 +00:00
Arvid Norberg
7ddffbac64 fixed windows build 2009-02-06 17:59:49 +00:00
Arvid Norberg
5c12db28d2 added option to lock disk cache in physical memory 2009-02-06 09:46:13 +00:00
Arvid Norberg
1ac8f806fa added seed mode support (lazy hash checking) 2009-02-03 07:46:24 +00:00
Arvid Norberg
26910eff1d update_settings fixes for disk_io_thread 2009-01-28 07:09:10 +00:00
Arvid Norberg
b3a17b1787 added disk buffer instrumentation and log parser 2009-01-23 09:13:31 +00:00
Arvid Norberg
00808473e7 factor out disk_buffer_pool from disk_io_thread. refactored the file open modes to be platform independent. gave the disk_io_thread its own copy of session_settings that it shares with storage. added an unaligned_read implementation to storage. Added options to session_settings on when to open files in unbuffered mode. Added unit tests for unaligned reads 2009-01-21 07:31:49 +00:00
Arvid Norberg
113d1f3557 moved page_aligned_allocator to its own file and uses it in set_piece_hashes to not pass in unaligned buffers to storage read 2009-01-15 17:09:36 +00:00
Arvid Norberg
630601aedf use & instead of % 2009-01-15 04:25:07 +00:00
Arvid Norberg
b9d7538ba8 fixed storage to generate a proper error when the read operation 2009-01-14 03:05:35 +00:00
Arvid Norberg
3f0fa60164 fixed typo preventing pool-allocators=off build 2009-01-13 06:49:40 +00:00
Arvid Norberg
7592ad4aee updated disk IO to support unbuffered files 2009-01-11 02:02:34 +00:00
Arvid Norberg
cfd116ffad made disk_io_settings be synchronized through the job queue 2009-01-10 05:46:02 +00:00
Arvid Norberg
f1d229aae6 first pass of replacing coalesce writes and reads by writev and readv (no windows support yet) 2009-01-03 08:11:31 +00:00
Arvid Norberg
3bf9fa239d fixed incorrect failure test in storage. Affected reading when not coalescing reads 2009-01-02 10:31:26 +00:00
Arvid Norberg
06da1f8e8a added some session logging. added more disk-io-thread stats logging and parse script 2008-12-30 08:20:25 +00:00
Arvid Norberg
28cb451eac expire read cache as well (same time out as write cache) 2008-12-27 02:38:14 +00:00
Arvid Norberg
2d4bdbca7d fixed disk_io_thread over-allocation 2008-12-03 06:42:53 +00:00
Arvid Norberg
1022ba45fc fixed bug in disk IO thread which would make it sometimes0 exit the thread if an error occurred 2008-11-29 21:38:34 +00:00
Arvid Norberg
09b3a865ef fixed compiler flags in pkg-config file and made header files not depend on the NDEBUG define 2008-11-29 21:33:21 +00:00
Arvid Norberg
f503bbfe86 fix for when aborting torrents that are being checked. Fix in client_test when removing torrents that are checking. 2008-11-17 01:19:46 +00:00
Arvid Norberg
49a3ac9710 disk_io_thread shutdown fix 2008-11-11 09:32:51 +00:00
Arvid Norberg
4e9124019b added accessor to query for the max number of connections 2008-11-08 07:40:55 +00:00
Arvid Norberg
5f6351146a removed assert that could cause dead-lock in debug mode 2008-10-05 19:47:55 +00:00
Arvid Norberg
0f6ec06e12 fixed race condition in invariant check in disk io thread (only affected debug builds) 2008-09-30 01:16:19 +00:00
Arvid Norberg
26dea3c222 fixed stats miscount when deleting files 2008-09-17 02:29:05 +00:00
Arvid Norberg
658eef82a5 get rid of msvc warning 2008-09-15 13:58:38 +00:00
Arvid Norberg
8488d5eb59 fixed bug in disk_io_thread read cache management 2008-08-07 12:30:36 +00:00
Arvid Norberg
58978048e8 fixed assert in disk_io_thread 2008-07-30 08:05:04 +00:00
Arvid Norberg
21dff61cb5 clears read cache when paused. Saves memory 2008-07-18 15:31:22 +00:00
Arvid Norberg
3cb1369385 improved error reporting of file errors (uses boost.system's error_code). Now permission errors are properly reported when checking files 2008-07-17 23:41:46 +00:00
Arvid Norberg
9c9c13c7bb exposed read cache info as well as write cache 2008-07-11 10:29:26 +00:00
Arvid Norberg
9c84908bb9 switched resume data parsing over to use lazy_bdecode. Improves memory allocation performance, especially noticable when heap allocations are expensive. Makes it more practical to run with malloc debug. Changed resume data interface to take a vector as opposed to a parsed structure 2008-06-30 23:14:31 +00:00