#
bf77c152 |
|
02-Dec-2017 |
Augustin Cavalier <waddlesplash@gmail.com> |
kernel/vm: Correct virtual function declarations. The base VMCache class changed to the generic_ types with their introduction in in *2011* (435c43f5912b109e7d5cf682865d2061e62fad8c), but these classes were never properly adapted. These functions should not be called here (they panic() -- but the base class only returns B_ERROR, so that is a difference at least.) Found by Clang's -Woverloaded-virtual.
|
#
f8154d17 |
|
02-Nov-2011 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
mmlr (distracted) + bonefish: * Turn VMCache::consumers C list into a DoublyLinkedList. * Use object caches for the different VMCache types and the VMCacheRefs. The purpose is to reduce slab area fragmentation. * Requires the introduction of a pure virtual VMCache::DeleteObject() method, implemented in the derived classes. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@43133 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
ab3d6a3e |
|
02-Nov-2011 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Style cleanup. No functional change. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@43122 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
6e83a6fa |
|
20-Apr-2010 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* VMCache::Resize(): Corrected TODO comment. * Changed the semantics of VMCache::HasPage(). It was interpreted inconsistently by the derived classes. Now it returns whether the backing store can provide the page (via Read()). The default implementation returns false. VNodeCache::HasPage() only returns true, if the given offset is within the cache (i.e. file) bounds. This prevents vm_soft_fault() from adding clean pages to vnode caches on faults beyond the file bounds. Probably fixes #5473 -- at least mmap_resize_test behaves correctly, now. * Removed redundant HasPage() and Fault() overrides in VMCache derived classes. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36374 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
7263efe5 |
|
03-Mar-2010 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Override Fault() method for VM{Device,Null}Cache to prevent vm_soft_fault() from inserting a clean page, if a fault happens. VMNullCaches are used by the slab's memory manager -- all page faults in slab areas are serious bugs and we want to panic() immediately. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35748 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
deee8524 |
|
26-Jan-2010 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* Introduced {malloc,memalign,free}_etc() which take an additional "flags" argument. They replace the previous special-purpose allocation functions (malloc_nogrow(), vip_io_request_malloc()). * Moved the I/O VIP heap to heap.cpp accordingly. * Added quite a bit of passing around of allocation flags in the VM, particularly in the VM*AddressSpace classes. * Fixed IOBuffer::GetNextVirtualVec(): It was ignoring the VIP flag and always allocated on the normal heap. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35316 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
4eaa43ac |
|
11-Oct-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* Added "flags" parameter to VMCache::Read(). * Use the new VMCache::Read() flags parameter to directly read into the physical page in the page fault handler instead of mapping it first. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27966 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
2a79a768 |
|
18-Aug-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* VMCache::Write(): Added "uint32 flags" argument which is supposed to be passed on to the IORequest. Most relevantly physical pages can now be written directly by passing B_PHYSICAL_IO_REQUEST. * Added VMCache::WriteAsync() which is supposed to write pages asynchronously. The base class version version falls back to the synchronous Write(). Only VMVnodeCache implements WriteAsync() ATM, VMAnonymousCache (swap support) still has to be adjusted accordingly. * write_page() doesn't need to map the page anymore as it can write the physical page directly. * Modified the page writer to write pages asynchronously. This shouldn't have any noticeable effect yet. It will though as soon as the I/O scheduler reorders I/O operations. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27056 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
e6bd90c5 |
|
23-Jul-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* bfs_fsync() was the only place which could cause the fs_vnode_ops::write_pages() to be called with fsReenter = true. Since this is no longer the case, the argument has become superfluous. For read_pages() it always was. Removed the argument from the functions and all functions that propagated it. * Some whitespace at the end of lines was removed. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26579 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
5c99d639 |
|
22-Jul-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Merged branch haiku/branches/developer/bonefish/vm into trunk. This introduces the following relevant changes: * VMCache: - Renamed vm_cache to VMCache, merged it with vm_store and made it a C++ class with virtual methods (replacing the store operations). Turned the different store implementations into subclasses. - Introduced MergeStore() callback, changed semantics of Commit(). - Changed locking and referencing semantics. A reference can only be acquired/released with the cache locked. An unreferenced cache is deleted and a mergeable cache merged when it is unlocked. This removes the "busy" state of a cache and simplifies the page fault code. * Added VMAnonymousCache, which will implement swap support (work by Zhao Shuai). It is not integrated and used yet, though. * Enabled the mutex/recursive lock holder asserts. * Fixed DoublyLinkedList::Swap(). * Generalized the low memory handler to a low resource handler. And made semaphores and reserved memory handled resources. Made vm_try_resource_memory() optionally wait (with timeout), and used that feature to reserve memory for areas. ... git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26572 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
f8154d172da77bd77316f14c76d428bae7376323 |
|
02-Nov-2011 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
mmlr (distracted) + bonefish: * Turn VMCache::consumers C list into a DoublyLinkedList. * Use object caches for the different VMCache types and the VMCacheRefs. The purpose is to reduce slab area fragmentation. * Requires the introduction of a pure virtual VMCache::DeleteObject() method, implemented in the derived classes. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@43133 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
ab3d6a3eafbd2e5fe3d66315550ec2231914c585 |
|
02-Nov-2011 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Style cleanup. No functional change. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@43122 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
6e83a6fac971dc2021617ade48a932900c54801a |
|
20-Apr-2010 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* VMCache::Resize(): Corrected TODO comment. * Changed the semantics of VMCache::HasPage(). It was interpreted inconsistently by the derived classes. Now it returns whether the backing store can provide the page (via Read()). The default implementation returns false. VNodeCache::HasPage() only returns true, if the given offset is within the cache (i.e. file) bounds. This prevents vm_soft_fault() from adding clean pages to vnode caches on faults beyond the file bounds. Probably fixes #5473 -- at least mmap_resize_test behaves correctly, now. * Removed redundant HasPage() and Fault() overrides in VMCache derived classes. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36374 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
7263efe581f47822ee1cbfecaef14d31f176d6ef |
|
03-Mar-2010 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Override Fault() method for VM{Device,Null}Cache to prevent vm_soft_fault() from inserting a clean page, if a fault happens. VMNullCaches are used by the slab's memory manager -- all page faults in slab areas are serious bugs and we want to panic() immediately. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35748 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
deee8524b7534d9b586cbcbf366d0660c9769a8e |
|
26-Jan-2010 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* Introduced {malloc,memalign,free}_etc() which take an additional "flags" argument. They replace the previous special-purpose allocation functions (malloc_nogrow(), vip_io_request_malloc()). * Moved the I/O VIP heap to heap.cpp accordingly. * Added quite a bit of passing around of allocation flags in the VM, particularly in the VM*AddressSpace classes. * Fixed IOBuffer::GetNextVirtualVec(): It was ignoring the VIP flag and always allocated on the normal heap. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35316 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
4eaa43ac48bb4936de09b85827893c9beb90b51c |
|
11-Oct-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* Added "flags" parameter to VMCache::Read(). * Use the new VMCache::Read() flags parameter to directly read into the physical page in the page fault handler instead of mapping it first. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27966 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
2a79a7686f90e5720024387dd90f8e058d13b044 |
|
18-Aug-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* VMCache::Write(): Added "uint32 flags" argument which is supposed to be passed on to the IORequest. Most relevantly physical pages can now be written directly by passing B_PHYSICAL_IO_REQUEST. * Added VMCache::WriteAsync() which is supposed to write pages asynchronously. The base class version version falls back to the synchronous Write(). Only VMVnodeCache implements WriteAsync() ATM, VMAnonymousCache (swap support) still has to be adjusted accordingly. * write_page() doesn't need to map the page anymore as it can write the physical page directly. * Modified the page writer to write pages asynchronously. This shouldn't have any noticeable effect yet. It will though as soon as the I/O scheduler reorders I/O operations. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27056 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
e6bd90c58dbae64f3b464edcff90dcb06e63a716 |
|
23-Jul-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* bfs_fsync() was the only place which could cause the fs_vnode_ops::write_pages() to be called with fsReenter = true. Since this is no longer the case, the argument has become superfluous. For read_pages() it always was. Removed the argument from the functions and all functions that propagated it. * Some whitespace at the end of lines was removed. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26579 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
5c99d639708df9b4e2cc847b38d510149d19ec78 |
|
22-Jul-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Merged branch haiku/branches/developer/bonefish/vm into trunk. This introduces the following relevant changes: * VMCache: - Renamed vm_cache to VMCache, merged it with vm_store and made it a C++ class with virtual methods (replacing the store operations). Turned the different store implementations into subclasses. - Introduced MergeStore() callback, changed semantics of Commit(). - Changed locking and referencing semantics. A reference can only be acquired/released with the cache locked. An unreferenced cache is deleted and a mergeable cache merged when it is unlocked. This removes the "busy" state of a cache and simplifies the page fault code. * Added VMAnonymousCache, which will implement swap support (work by Zhao Shuai). It is not integrated and used yet, though. * Enabled the mutex/recursive lock holder asserts. * Fixed DoublyLinkedList::Swap(). * Generalized the low memory handler to a low resource handler. And made semaphores and reserved memory handled resources. Made vm_try_resource_memory() optionally wait (with timeout), and used that feature to reserve memory for areas. ... git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26572 a95241bf-73f2-0310-859d-f6bbb57e9c96
|