Commit 233f81ee authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent 4a20a573
...@@ -1428,12 +1428,24 @@ void test_file_access_mmapbase(void) ...@@ -1428,12 +1428,24 @@ void test_file_access_mmapbase(void)
CHECK_MRU (page3, page0, page2); CHECK_MRU (page3, page0, page2);
CHECK_DIRTY (page3, page0, page2); CHECK_DIRTY (page3, page0, page2);
// XXX unmap vma2 ? /* unmap vma2 */
diag("unmap vma2");
vma_unmap(vma2);
ok1(fh->mmaps.next == &vma->same_fileh);
ok1(vma->same_fileh.next == &fh->mmaps);
ok1( M(vma, 0)); CHECK_PAGE (page0, 100, PAGE_DIRTY, 1);
ok1(!M(vma, 1)); CHECK_NOPAGE( 101 );
ok1( M(vma, 2)); CHECK_PAGE (page2, 102, PAGE_DIRTY, 1);
ok1( M(vma, 3)); CHECK_PAGE (page3, 103, PAGE_DIRTY, 1);
CHECK_MRU (page3, page0, page2);
CHECK_DIRTY (page3, page0, page2);
/* discard - changes should go away */ /* discard - changes should go away */
diag("discard"); diag("discard");
fprintf(stderr, "\n\n\n\n");
fileh_dirty_discard(fh); fileh_dirty_discard(fh);
CHECK_NOPAGE( 100 ); CHECK_NOPAGE( 100 );
...@@ -1443,11 +1455,6 @@ void test_file_access_mmapbase(void) ...@@ -1443,11 +1455,6 @@ void test_file_access_mmapbase(void)
ok1(!M(vma, 2)); CHECK_NOPAGE( 102 ); ok1(!M(vma, 2)); CHECK_NOPAGE( 102 );
ok1(!M(vma, 3)); CHECK_NOPAGE( 103 ); ok1(!M(vma, 3)); CHECK_NOPAGE( 103 );
ok1(!M(vma2, 0));
ok1(!M(vma2, 1));
ok1(!M(vma2, 2));
ok1(!M(vma2, 3));
CHECK_MRU (/*empty*/); CHECK_MRU (/*empty*/);
CHECK_DIRTY (/*empty*/); CHECK_DIRTY (/*empty*/);
...@@ -1472,13 +1479,20 @@ void test_file_access_mmapbase(void) ...@@ -1472,13 +1479,20 @@ void test_file_access_mmapbase(void)
// XXX writeout STORE, MARK, STORE+MARK // XXX writeout STORE, MARK, STORE+MARK
diag("writeout");
// XXX ...
// XXX invalidation ?
// XXX fileh close
/* free resources */
ram_close(ram);
free(ram);
#undef CHECK_MRU #undef CHECK_MRU
#undef CHECK_PAGE #undef CHECK_PAGE
......
- doc: notes on how things are organized in wendelin.core 2 - doc: notes on how things are organized in wendelin.core 2
wcfs:
- SIGSEGV is used only to track writes
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment