change log for rtems (2011-03-09)
rtems-vc at rtems.org
rtems-vc at rtems.org
Wed Mar 9 16:11:35 UTC 2011
*sh*:
2011-03-09 Sebastian Huber <sebastian.huber at embedded-brains.de>
* malloctest/init.c: Improve coverage.
* malloctest/malloctest.scn: Update.
M 1.260 testsuites/libtests/ChangeLog
M 1.45 testsuites/libtests/malloctest/init.c
M 1.6 testsuites/libtests/malloctest/malloctest.scn
diff -u rtems/testsuites/libtests/ChangeLog:1.259 rtems/testsuites/libtests/ChangeLog:1.260
--- rtems/testsuites/libtests/ChangeLog:1.259 Tue Feb 22 08:46:46 2011
+++ rtems/testsuites/libtests/ChangeLog Wed Mar 9 09:39:58 2011
@@ -1,3 +1,8 @@
+2011-03-09 Sebastian Huber <sebastian.huber at embedded-brains.de>
+
+ * malloctest/init.c: Improve coverage.
+ * malloctest/malloctest.scn: Update.
+
2011-02-22 Ralf Corsépius <ralf.corsepius at rtems.org>
* configure.ac: Add AC_CONFIG_HEADER(config.h).
diff -u rtems/testsuites/libtests/malloctest/init.c:1.44 rtems/testsuites/libtests/malloctest/init.c:1.45
--- rtems/testsuites/libtests/malloctest/init.c:1.44 Tue Feb 22 01:34:07 2011
+++ rtems/testsuites/libtests/malloctest/init.c Wed Mar 9 09:39:58 2011
@@ -940,32 +940,42 @@
static void test_heap_extend(void)
{
bool ret = false;
+ Heap_Control *heap = &TestHeap;
+ uint8_t *area_begin = TestHeapMemory;
- _Heap_Initialize( &TestHeap, TestHeapMemory + 768, 256, 0 );
+ _Heap_Initialize( heap, area_begin + 768, 256, 0 );
puts( "heap extend - link below" );
- ret = _Protected_heap_Extend( &TestHeap, TestHeapMemory + 0, 256 );
+ ret = _Protected_heap_Extend( heap, area_begin + 0, 256 );
test_heap_assert( ret, true );
puts( "heap extend - merge below" );
- ret = _Protected_heap_Extend( &TestHeap, TestHeapMemory + 512, 256 );
+ ret = _Protected_heap_Extend( heap, area_begin + 512, 256 );
test_heap_assert( ret, true );
puts( "heap extend - merge above" );
- ret = _Protected_heap_Extend( &TestHeap, TestHeapMemory + 1024, 256 );
+ ret = _Protected_heap_Extend( heap, area_begin + 1024, 256 );
test_heap_assert( ret, true );
puts( "heap extend - link above" );
- ret = _Protected_heap_Extend( &TestHeap, TestHeapMemory + 1536, 256 );
+ ret = _Protected_heap_Extend( heap, area_begin + 1536, 256 );
test_heap_assert( ret, true );
puts( "heap extend - area too small" );
- ret = _Protected_heap_Extend( &TestHeap, TestHeapMemory + 2048, 0 );
+ ret = _Protected_heap_Extend( heap, area_begin + 2048, 0 );
test_heap_assert( ret, false );
puts( "heap extend - invalid area" );
- ret = _Protected_heap_Extend( &TestHeap, (void *) -1, 2 );
+ ret = _Protected_heap_Extend( heap, (void *) -1, 2 );
test_heap_assert( ret, false );
+
+ area_begin = (uint8_t *) (((uintptr_t) area_begin) | 1);
+
+ _Heap_Initialize( heap, area_begin + 768, 256, 0 );
+
+ puts( "heap extend - merge below with align up" );
+ ret = _Protected_heap_Extend( heap, area_begin + 512, 256 );
+ test_heap_assert( ret, true );
}
static void test_heap_info(void)
diff -u rtems/testsuites/libtests/malloctest/malloctest.scn:1.5 rtems/testsuites/libtests/malloctest/malloctest.scn:1.6
--- rtems/testsuites/libtests/malloctest/malloctest.scn:1.5 Wed Sep 9 09:59:09 2009
+++ rtems/testsuites/libtests/malloctest/malloctest.scn Wed Mar 9 09:39:58 2011
@@ -44,8 +44,13 @@
malloc_walk - normal path
malloc_walk - in critical section path
Heap Initialized
-heap extend - bad address
-heap extend - OK
+heap extend - link below
+heap extend - merge below
+heap extend - merge above
+heap extend - link above
+heap extend - area too small
+heap extend - invalid area
+heap extend - merge below with align up
malloc_free_space - check malloc space drops after malloc
malloc_free_space - verify free space returns to previous value
malloc_info - called with NULL
--
Generated by Deluxe Loginfo [http://www.codewiz.org/projects/index.html#loginfo] 2.122 by Bernardo Innocenti <bernie at develer.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/vc/attachments/20110309/9ba71fcb/attachment.html>
More information about the vc
mailing list