Searched +hist:1 +hist:c88c851 (Results 1 - 2 of 2) sorted by relevance
/haiku/src/system/kernel/cache/ | ||
H A D | block_cache.cpp | diff 1cafaeca Fri Jun 18 15:17:11 MDT 2010 Ingo Weinhold <ingo_weinhold@gmx.de> * Introduced block_cache::unused_block_count, which counts the elements of block_cache::unused_blocks. * block_cache::Allocate(): No longer removes unused blocks when in a low resource state. That just removed too many blocks too quickly, when the cache was actively used for writing, seriously affecting performance. * block_cache::_LowMemoryHandler(): Compute the number of unused blocks to remove depending on the total unused block number. This way we cull huge block caches with lots of old blocks much quicker. Treats part of #5816. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37170 a95241bf-73f2-0310-859d-f6bbb57e9c96 diff ff59ce68 Wed Feb 24 07:43:20 MST 2010 Axel Dörfler <axeld@pinc-software.de> * The low resource handler now empties the cache depot's magazines; before, they were never freed unless the cache was destroyed (I just wondered why my system would bury >1G in the magazines). * Made the magazine capacity variable per cache, ie. for larger objects, it's not a good idea to have 64*CPU buffers lying around in the worst case. * Furthermore, the create_object_cache_etc()/object_depot_init() now have arguments for the magazine capacity as well as the maximum number of full unused magazines. * By default, you might want to initialize both to zero, as then some hopefully usable defaults are computed. Otherwise (the only current example is the vm_page_mapping cache) you can just put in the values you'd want there. The page mapping cache uses larger values, as its objects are usually allocated and deleted in larger chunks. * Beware, though, I couldn't test these changes yet as Qemu didn't like to run today. I'll test these changes on another machine now. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35601 a95241bf-73f2-0310-859d-f6bbb57e9c96 diff 1db31d4d Fri Nov 27 06:04:30 MST 2009 Axel Dörfler <axeld@pinc-software.de> * The slab and the block cache now both also react on address space shortages. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34310 a95241bf-73f2-0310-859d-f6bbb57e9c96 diff 1d136d5a Tue Aug 19 02:40:55 MDT 2008 Axel Dörfler <axeld@pinc-software.de> * Fixed bug #2631 based on a patch by Salvatore: the block cache was put into a global list before it was fully initialized. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27058 a95241bf-73f2-0310-859d-f6bbb57e9c96 diff 76824051 Tue Apr 29 08:57:56 MDT 2008 Axel Dörfler <axeld@pinc-software.de> * Only enable block/transaction tracing when the macro is 1. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25247 a95241bf-73f2-0310-859d-f6bbb57e9c96 diff fae99f15 Fri Mar 14 16:03:26 MDT 2008 Ingo Weinhold <ingo_weinhold@gmx.de> cached_block::Compare() was ignoring the upper 32 bit of the block number. Was a problem only for partitions > 2^32 * block size (4TB for 1KB blocks). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24393 a95241bf-73f2-0310-859d-f6bbb57e9c96 diff 1bb74eb1 Thu Jan 26 14:02:53 MST 2006 Axel Dörfler <axeld@pinc-software.de> This fixes the work-around made in r16105, and some more: * cached_block::parent_data can be NULL in a sub transaction in case the block wasn't part of the parent transaction (but not in low memory situations). cache_abort_sub_transaction() and cache_detach_sub_transaction() didn't account for this, though, ie. the block data could end up corrupted. * Renamed cached_block::original in original_data. * Renamed cached_block::data in current_data. * Added some comments. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16108 a95241bf-73f2-0310-859d-f6bbb57e9c96 diff 1c88c851 Wed Oct 19 17:01:57 MDT 2005 Axel Dörfler <axeld@pinc-software.de> Turned off debug output again - also temporarily removed the file cache warning about our block_io module not honouring the total length in read_pages(). Removed drops into the debugger when there is a block without an "original" data buffer - that's completely normal and happens when someone asks for a cleared block that is not yet in the cache. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14437 a95241bf-73f2-0310-859d-f6bbb57e9c96 diff 1c88c851 Wed Oct 19 17:01:57 MDT 2005 Axel Dörfler <axeld@pinc-software.de> Turned off debug output again - also temporarily removed the file cache warning about our block_io module not honouring the total length in read_pages(). Removed drops into the debugger when there is a block without an "original" data buffer - that's completely normal and happens when someone asks for a cleared block that is not yet in the cache. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14437 a95241bf-73f2-0310-859d-f6bbb57e9c96 diff 1cafaecaf595342ef972c727904eaeb1454bd511 Fri Jun 18 15:17:11 MDT 2010 Ingo Weinhold <ingo_weinhold@gmx.de> * Introduced block_cache::unused_block_count, which counts the elements of block_cache::unused_blocks. * block_cache::Allocate(): No longer removes unused blocks when in a low resource state. That just removed too many blocks too quickly, when the cache was actively used for writing, seriously affecting performance. * block_cache::_LowMemoryHandler(): Compute the number of unused blocks to remove depending on the total unused block number. This way we cull huge block caches with lots of old blocks much quicker. Treats part of #5816. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37170 a95241bf-73f2-0310-859d-f6bbb57e9c96 |
H A D | file_cache.cpp | diff 1d578e15 Wed Jun 02 14:46:49 MDT 2010 Ingo Weinhold <ingo_weinhold@gmx.de> Fixed more address types related issues. Mostly printf() or comparison warnings, but also some oversights from earlier changes. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37000 a95241bf-73f2-0310-859d-f6bbb57e9c96 diff 1f611c01 Tue Feb 16 10:22:56 MST 2010 Ingo Weinhold <ingo_weinhold@gmx.de> The file cache code was completely ignoring the vm_page::modified flag. In particular it wouldn't set the flag when writing something to a page, but only move it to the modified queue. Since mapping the page would move it to another queue, the information that the page was modified would be lost and it would never be written to disk. Was well reproducible with a Haiku image build and limited amount of memory. Fixes the hopefully last remaining cause for #5374. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35500 a95241bf-73f2-0310-859d-f6bbb57e9c96 diff 1af7d115 Sat Oct 10 16:37:26 MDT 2009 Michael Lotz <mmlr@mlotz.ch> * Rework page writing to combine page writes where possible. For now the pages are required to be physically contiguos, which should be reworked to put them into seperate iovecs. Still this manages to combine a great deal of page writes into larger bursts already. Reduces the amount of IO requests being scheduled (and greatly benefits media where page wise writes are slow when they are accessed through a non-IOScheduler path, i.e. USB mass storage until that is properly implemented). * Abstracted per page page writing tasks into a PageWriteWrapper class. * Abstracted per transfer page writing tasks into PageWriteTransfer class which formerly was the PageWriterCallback. * Use both classes from the PageWriterRun and from vm_page_write_modified_page_range to remove code duplication. * Adjusted synchronous VMAnonymousCache::Write() to cope correctly with larger iovecs and more than one iovec. It assumed that there was exactly one page per vector previously. * Introduced MaxPagesPerWrite() and MaxPagesPerAsyncWrite() to VMCache to allow a cache to specify restricitions. VMAnonymousCache does restrict the max pages to 1 for WriteAsync right now as I didn't feel like reworking that one to cope with non single page writes just yet. * Pulled out PageWriteTransfer methods for better readability. * Some typo fixes. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33507 a95241bf-73f2-0310-859d-f6bbb57e9c96 diff 1af7d115 Sat Oct 10 16:37:26 MDT 2009 Michael Lotz <mmlr@mlotz.ch> * Rework page writing to combine page writes where possible. For now the pages are required to be physically contiguos, which should be reworked to put them into seperate iovecs. Still this manages to combine a great deal of page writes into larger bursts already. Reduces the amount of IO requests being scheduled (and greatly benefits media where page wise writes are slow when they are accessed through a non-IOScheduler path, i.e. USB mass storage until that is properly implemented). * Abstracted per page page writing tasks into a PageWriteWrapper class. * Abstracted per transfer page writing tasks into PageWriteTransfer class which formerly was the PageWriterCallback. * Use both classes from the PageWriterRun and from vm_page_write_modified_page_range to remove code duplication. * Adjusted synchronous VMAnonymousCache::Write() to cope correctly with larger iovecs and more than one iovec. It assumed that there was exactly one page per vector previously. * Introduced MaxPagesPerWrite() and MaxPagesPerAsyncWrite() to VMCache to allow a cache to specify restricitions. VMAnonymousCache does restrict the max pages to 1 for WriteAsync right now as I didn't feel like reworking that one to cope with non single page writes just yet. * Pulled out PageWriteTransfer methods for better readability. * Some typo fixes. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33507 a95241bf-73f2-0310-859d-f6bbb57e9c96 diff 1b6eff28 Sat Oct 11 14:55:32 MDT 2008 Ingo Weinhold <ingo_weinhold@gmx.de> * Replaced the vm_get_physical_page() "flags" PHYSICAL_PAGE_{NO,CAN}_WAIT into an actual flag PHYSICAL_PAGE_DONT_WAIT. * Pass the flags through to the chunk mapper callback. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27979 a95241bf-73f2-0310-859d-f6bbb57e9c96 diff ea2cd27e Wed Dec 21 10:00:03 MST 2005 Axel Dörfler <axeld@pinc-software.de> * Fixed the strange vm_cache_ref reference count mechanism: now, a fresh vm_cache_ref starts with a reference count of 1. When acquiring a vm_cache, you no longer need to worry if that should go through the vm_store, or not; as it now always does. * map_backing_store() no longer needs to play with the vm_cache_ref references. * that simplified some code. * vfs_get_vnode_cache() now grabs a reference to the cache, if successful. * better balanced vnode ownership on vnode_store creation (vnode_store released the vnode before if its creation failed). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15641 a95241bf-73f2-0310-859d-f6bbb57e9c96 diff 1c88c851 Wed Oct 19 17:01:57 MDT 2005 Axel Dörfler <axeld@pinc-software.de> Turned off debug output again - also temporarily removed the file cache warning about our block_io module not honouring the total length in read_pages(). Removed drops into the debugger when there is a block without an "original" data buffer - that's completely normal and happens when someone asks for a cleared block that is not yet in the cache. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14437 a95241bf-73f2-0310-859d-f6bbb57e9c96 diff 1c88c851 Wed Oct 19 17:01:57 MDT 2005 Axel Dörfler <axeld@pinc-software.de> Turned off debug output again - also temporarily removed the file cache warning about our block_io module not honouring the total length in read_pages(). Removed drops into the debugger when there is a block without an "original" data buffer - that's completely normal and happens when someone asks for a cleared block that is not yet in the cache. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14437 a95241bf-73f2-0310-859d-f6bbb57e9c96 diff 1d578e15fe5b5c3ff62866ae81aef529d00d7762 Wed Jun 02 14:46:49 MDT 2010 Ingo Weinhold <ingo_weinhold@gmx.de> Fixed more address types related issues. Mostly printf() or comparison warnings, but also some oversights from earlier changes. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37000 a95241bf-73f2-0310-859d-f6bbb57e9c96 diff 1f611c018b474c78f84ea905e574c24586ae85b1 Tue Feb 16 10:22:56 MST 2010 Ingo Weinhold <ingo_weinhold@gmx.de> The file cache code was completely ignoring the vm_page::modified flag. In particular it wouldn't set the flag when writing something to a page, but only move it to the modified queue. Since mapping the page would move it to another queue, the information that the page was modified would be lost and it would never be written to disk. Was well reproducible with a Haiku image build and limited amount of memory. Fixes the hopefully last remaining cause for #5374. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35500 a95241bf-73f2-0310-859d-f6bbb57e9c96 |
Completed in 145 milliseconds