[#5828] libstdc++-4.3 21_strings/basic_string/capacity/char/18654.cc test on fdpic would fail

Document created by Aaronwu Employee on Oct 17, 2013
Version 1Show Document
  • View in full screen mode

[#5828] libstdc++-4.3 21_strings/basic_string/capacity/char/18654.cc test on fdpic would fail

Submitted By: Mingquan Pan

Open Date

2010-01-14 04:42:04     Close Date

2012-05-15 03:03:15

Priority:

Medium High     Assignee:

Vivi Li

Mingquan Pan

Stuart Henderson

Board:

N/A     Silicon Revision:

Resolution:

Fixed     Fixed In Release:

2012R1

Processor:

BF537     

Host Operating System:

toolchain rev.:

4.1 trunk head     kernel rev.:

State:

Closed     Found In Release:

N/A

Is this bug repeatable?:

N/A     

Summary: libstdc++-4.3 21_strings/basic_string/capacity/char/18654.cc test on fdpic would fail

Details:

 

libstdc++-4.3 21_strings/basic_string/capacity/char/18654.cc test on fdpic would fail frequentlynow. It looks has something related to the hush return code issue, need verification.

 

Tests that now fail, but worked before:

 

bfin-linux-uclibc: 21_strings/basic_string/capacity/char/18654.cc execution test

 

failed log:

Executing on host: bfin-linux-uclibc-g++ -g -O2 -D_GLIBCXX_ASSERT -fmessage-length=0  -DLOCALEDIR="." -I/home/test/work/cruise/checkouts/toolchain/gcc-4.3/libstdc++-v3/testsuite/util /home/test/work/cruise/checkouts/toolchain/gcc-4.3/libstdc++-v3/testsuite/21_strings/basic_string/capacity/char/18654.cc     ./libtestc++.a   -lm  -mcpu=bf537-0.2 -o ./18654.exe    (timeout = 600)

spawn bfin-linux-uclibc-g++ -g -O2 -D_GLIBCXX_ASSERT -fmessage-length=0 -DLOCALEDIR="." -I/home/test/work/cruise/checkouts/toolchain/gcc-4.3/libstdc++-v3/testsuite/util /home/test/work/cruise/checkouts/toolchain/gcc-4.3/libstdc++-v3/testsuite/21_strings/basic_string/capacity/char/18654.cc ./libtestc++.a -lm -mcpu=bf537-0.2 -o ./18654.exe^M

PASS: 21_strings/basic_string/capacity/char/18654.cc (test for excess errors)

Executing on bfin-linux-uclibc: /tmp/18654.exe.16193    (timeout = 300)

Executing on bfin-linux-uclibc: rm -f  /tmp/18654.exe.16193    (timeout = 300)

Executed ./18654.exe, status 1

terminate called after throwing an instance of 'std::bad_alloc'

  what():  std::bad_alloc

ABRT

FAIL: 21_strings/basic_string/capacity/char/18654.cc execution test

extra_tool_flags are:

 

 

While in the log og Jan 4 ,it can pass:

 

Executing on host: bfin-linux-uclibc-g++ -g -O2 -D_GLIBCXX_ASSERT -fmessage-length=0  -DLOCALEDIR="." -I/home/test/work/cruise/checkouts/toolchain/gcc-4.3/libstdc++-v3/testsuite/util /home/test/work/cruise/checkouts/toolchain/gcc-4.3/libstdc++-v3/testsuite/21_strings/basic_string/capacity/char/18654.cc     ./libtestc++.a   -lm  -mcpu=bf537-0.2 -o ./18654.exe    (timeout = 600)

spawn bfin-linux-uclibc-g++ -g -O2 -D_GLIBCXX_ASSERT -fmessage-length=0 -DLOCALEDIR="." -I/home/test/work/cruise/checkouts/toolchain/gcc-4.3/libstdc++-v3/testsuite/util /home/test/work/cruise/checkouts/toolchain/gcc-4.3/libstdc++-v3/testsuite/21_strings/basic_string/capacity/char/18654.cc ./libtestc++.a -lm -mcpu=bf537-0.2 -o ./18654.exe^M

PASS: 21_strings/basic_string/capacity/char/18654.cc (test for excess errors)

Executing on bfin-linux-uclibc: /tmp/18654.exe.23678    (timeout = 300)

Executing on bfin-linux-uclibc: rm -f  /tmp/18654.exe.23678    (timeout = 300)

Executed ./18654.exe, status 0

PASS: 21_strings/basic_string/capacity/char/18654.cc execution test

extra_tool_flags are:

 

 

Which makes it strange is that there is log in middle of the above two logs shown:

 

Executing on host: bfin-linux-uclibc-g++ -g -O2 -D_GLIBCXX_ASSERT -fmessage-length=0  -DLOCALEDIR="." -I/home/test/work/cruise/checkouts/toolchain/gcc-4.3/libstdc++-v3/testsuite/util /home/test/work/cruise/checkouts/toolchain/gcc-4.3/libstdc++-v3/testsuite/21_strings/basic_string/capacity/char/18654.cc     ./libtestc++.a   -lm  -mcpu=bf537-0.2 -o ./18654.exe    (timeout = 600)

spawn bfin-linux-uclibc-g++ -g -O2 -D_GLIBCXX_ASSERT -fmessage-length=0 -DLOCALEDIR="." -I/home/test/work/cruise/checkouts/toolchain/gcc-4.3/libstdc++-v3/testsuite/util /home/test/work/cruise/checkouts/toolchain/gcc-4.3/libstdc++-v3/testsuite/21_strings/basic_string/capacity/char/18654.cc ./libtestc++.a -lm -mcpu=bf537-0.2 -o ./18654.exe^M

PASS: 21_strings/basic_string/capacity/char/18654.cc (test for excess errors)

Executing on bfin-linux-uclibc: /tmp/18654.exe.19655    (timeout = 300)

Executing on bfin-linux-uclibc: rm -f  /tmp/18654.exe.19655    (timeout = 300)

Executed ./18654.exe, status 0

terminate called after throwing an instance of 'std::bad_alloc'

  what():  std::bad_alloc

ABRT

PASS: 21_strings/basic_string/capacity/char/18654.cc execution test

extra_tool_flags are:

 

 

The passed version is:

************** Tested toolchain svn info ***************

At revision 3792.

Path: .

URL: svn://10.99.29.20/toolchain/trunk

Repository Root: svn://10.99.29.20/toolchain

Repository UUID: 2adf4935-75e9-4407-93b2-34b21a1880a4

Revision: 3792

Node Kind: directory

Schedule: normal

Last Changed Author: vapier

Last Changed Rev: 3792

Last Changed Date: 2010-01-02 12:36:46 +0800 (Sat, 02 Jan 2010)

************** Tested U-Boot svn info ******************

At revision 2199.

Path: .

URL: svn://10.99.29.20/u-boot/trunk

Repository Root: svn://10.99.29.20/u-boot

Repository UUID: e8ad1c53-384c-47db-b5ce-66ae1f620dea

Revision: 2199

Node Kind: directory

Schedule: normal

Last Changed Author: vivili

Last Changed Rev: 2199

Last Changed Date: 2009-12-29 14:30:33 +0800 (Tue, 29 Dec 2009)

************* Tested uclinux-dist svn info *************

U    testsuites/kernel_test

U    testsuites/ltp/config/passwd

U    testsuites/kgdb/kgdb_test.exp

Updated to revision 9336.

Path: .

URL: svn://10.99.29.20/uclinux-dist/trunk

Repository Root: svn://10.99.29.20/uclinux-dist

Repository UUID: 3e2a5524-39e8-4cb9-84a9-c49da69cba3a

Revision: 9336

Node Kind: directory

Schedule: normal

Last Changed Author: vivili

Last Changed Rev: 9336

Last Changed Date: 2010-01-04 12:59:39 +0800 (Mon, 04 Jan 2010)

************* Tested linux svn info ********************

At revision 8107.

Path: .

URL: svn://10.99.29.20/linux-kernel/trunk

Repository Root: svn://10.99.29.20/linux-kernel

Repository UUID: 526b6c2d-f592-4532-a319-5dd88ccb003d

Revision: 8107

Node Kind: directory

Schedule: normal

Last Changed Author: cliff

Last Changed Rev: 8107

Last Changed Date: 2009-12-31 17:44:01 +0800 (Thu, 31 Dec 2009)

 

Testing is running on target with following versions:

kernel:    Linux release 2.6.32.2-ADI-2010R1-pre-svn8107, build #46 Mon Jan 4 21:30:32 CST 2010

toolchain: bfin-uclinux-gcc release gcc version 4.3.4 (ADI-trunk/svn-3771)

user-dist: release svn-9336, build #16 Mon Jan 4 21:27:30 CST 2010

 

 

failed version:

 

************** Tested toolchain svn info ***************

At revision 3792.

Path: .

URL: svn://10.99.29.20/toolchain/trunk

Repository Root: svn://10.99.29.20/toolchain

Repository UUID: 2adf4935-75e9-4407-93b2-34b21a1880a4

Revision: 3792

Node Kind: directory

Schedule: normal

Last Changed Author: vapier

Last Changed Rev: 3792

Last Changed Date: 2010-01-02 12:36:46 +0800 (Sat, 02 Jan 2010)

************** Tested U-Boot svn info ******************

At revision 2199.

Path: .

URL: svn://10.99.29.20/u-boot/trunk

Repository Root: svn://10.99.29.20/u-boot

Repository UUID: e8ad1c53-384c-47db-b5ce-66ae1f620dea

Revision: 2199

Node Kind: directory

Schedule: normal

Last Changed Author: vivili

Last Changed Rev: 2199

Last Changed Date: 2009-12-29 14:30:33 +0800 (Tue, 29 Dec 2009)

************* Tested uclinux-dist svn info *************

A    lib/readline/readline-6.1

A    lib/readline/readline-6.1/ansi_stdlib.h

A    lib/readline/readline-6.1/Makefile.in

A    lib/readline/readline-6.1/history.c

A    lib/readline/readline-6.1/display.c

A    lib/readline/readline-6.1/posixdir.h

...U    drivers/usb/musb/musb_core.c

U    drivers/usb/musb/musb_core.h

Updated to revision 8124.

Path: .

URL: svn://10.99.29.20/linux-kernel/trunk

Repository Root: svn://10.99.29.20/linux-kernel

Repository UUID: 526b6c2d-f592-4532-a319-5dd88ccb003d

Revision: 8124

Node Kind: directory

Schedule: normal

Last Changed Author: sonicz

Last Changed Rev: 8124

Last Changed Date: 2010-01-06 11:20:36 +0800 (Wed

 

Testing is running on target with following versions:

kernel:    Linux release 2.6.32.2-ADI-2010R1-pre-svn8124, build #52 Thu Jan 7 01:29:44 CST 2010

toolchain: bfin-uclinux-gcc release gcc version 4.3.4 (ADI-trunk/svn-3771)

user-dist: release svn-9347, build #18 Thu Jan 7 01:26:33 CST 2010

 

, 06 Jan 2010)

 

 

 

 

Follow-ups

 

--- Jie Zhang                                                2010-01-26 09:05:22

I cannot reproduce it.

 

--- Vivi Li                                                  2010-07-01 03:17:54

I also see this bug happening on some regression machine for bfin-linux-uclibc.

 

--- Vivi Li                                                  2010-07-08 03:35:21

From the log on target board, I can see when this execution test fail, there is

a page allocation failure on target board.

 

--

18654.exe.2295: page allocation failure. order:11, mode:0xd0^M

Mem-Info:^M

DMA per-cpu:^M

CPU    0: hi:    0, btch:   1 usd:   0^M

active_anon:0 inactive_anon:0 isolated_anon:0^M

active_file:0 inactive_file:78 isolated_file:0^M

unevictable:3911 dirty:0 writeback:0 unstable:0^M

free:6214 slab_reclaimable:244 slab_unreclaimable:175^M

mapped:0 shmem:0 pagetables:0 bounce:0^M

DMA free:24856kB min:4096kB low:5120kB high:6144kB active_anon:0kB

inactive_anon:0kB active_file:0kB inactive_file:312kB unevictable:15644kB

isolated(anon):0kB isolated(file):0kB present:56896kB mlocked:0kB dirty:0kB

writeback:0kB mapped:0kB shmem:0kB slab_reclaimable:976kB

slab_unreclaimable:700kB kernel_stack:160kB pagetables:0kB unstable:0kB

bounce:0kB writeback_tmp:0kB pages_scanned:0 all_unreclaimable? no^M

lowmem_reserve[]: 0 0 0^M

DMA: 8*4kB 1*8kB 1*16kB 1*32kB 1*64kB 25*128kB 12*256kB 2*512kB 3*1024kB

1*2048kB 3*4096kB 0*8192kB 0*16384kB 0*32768kB = 24856kB^M

3956 total pagecache pages^M

14336 pages RAM^M

544 pages reserved^M

1602 pages shared^M

5956 pages non-shared^M

--

 

--- Robin Getz                                               2010-08-02 08:05:05

The test in this case:

 

  const size_type maxsize = 2 << 20;  /* 1Meg */

  for (size_type i = minsize; i <= maxsize; i *= 2)

    {

      string str(i, 'x');

      str.reserve(3 * i);

 

      str.reserve(2 * i);

      VERIFY( str.capacity() == 2 * i );

 

      str.reserve();

      VERIFY( str.capacity() == i );

    }

 

Which will try to malloc 4Meg - so that explains the order 11 allocation (8Meg

page)

 

Most likely works with:

 

-  const size_type maxsize = 2 << 20;

+  const size_type maxsize = 2 << 16;

 

--- Stuart Henderson                                         2010-08-04 11:27:16

The test will often pass as there is enough memory, however, during testing the

memory is becoming quite badly fragmented and we end up with no areas large

enough.  There's nothing we can realistically do about this other than Robin's

suggested change, so I'm going to recommend we just go with that.

 

Unless anyone objects, i'll update the test.

 

--- Stuart Henderson                                         2010-08-09 05:24:54

Fixed the test.  It's still possible the test could fail, but it's significantly

less likely.

 

--- Vivi Li                                                  2010-08-24 05:57:45

Yes, it's better now.

Close it.

 

--- Mingquan Pan                                             2011-11-04 05:58:30

I reopen this for I have seen the 18654 case has made kernel panic sometimes

when testing on linux-uclibc,and the board reset introduces more failure in

libstdc++ testing.

 

FAIL: 21_strings/basic_string/capacity/wchar_t/18654.cc execution test

It could be this case make this bug.

 

Console output:

testing linux-uclibc libstdc++^M

18654.exe.5033: page allocation failure: order:11, mode:0xd0^M

03000004  00a1d640  04000021  00000000 ^M

Mem-Info:^M

DMA per-cpu:^M

CPU    0: hi:    0, btch:   1 usd:   0^M

active_anon:0 inactive_anon:0 isolated_anon:0^M

active_file:1 inactive_file:9 isolated_file:0^M

unevictable:3375 dirty:0 writeback:0 unstable:0^M

free:8342 slab_reclaimable:230 slab_unreclaimable:206^M

mapped:0 shmem:0 pagetables:0 bounce:0^M

DMA free:33368kB min:4096kB low:5120kB high:6144kB active_anon:0kB

inactive_anon:0kB active_file:4kB inactive_file:36kB unevictable:13500kB

isolated(anon):0kB isolated(file):0kB present:64008kB mlocked:0kB dirty:0kB

writeback:0kB mapped:0kB shmem:0kB slab_reclaimable:920kB

slab_unreclaimable:824kB kernel_stack:208kB pagetables:0kB unstable:0kB

bounce:0kB writeback_tmp:0kB pages_scanned:1500 all_unreclaimable? yes^M

lowmem_reserve[]: 0 0 0^M

DMA: 0*4kB 1*8kB 1*16kB 0*32kB 1*64kB 0*128kB 6*256kB 6*512kB 2*1024kB 1*2048kB

4*4096kB 1*8192kB 0*16384kB 0*32768kB = 33368kB^M

3385 total pagecache pages^M

16128 pages RAM^M

616 pages reserved^M

0 pages shared^M

7144 pages non-shared^M

Allocation of length 4198400 from process 18187 (18654.exe.5033) failed^M

DMA per-cpu:^M

CPU    0: hi:    0, btch:   1 usd:   0^M

active_anon:0 inactive_anon:0 isolated_anon:0^M

active_file:1 inactive_file:9 isolated_file:0^M

unevictable:3375 dirty:0 writeback:0 unstable:0^M

free:8342 slab_reclaimable:230 slab_unreclaimable:206^M

mapped:0 shmem:0 pagetables:0 bounce:0^M

...

 

                       ******* libstdc++-4.3.sum ***********

=== libstdc++ Summary ===               === libstdc++ Summary ===        ()

# of expected passes            4894            # of expected passes          

4811     (-83)

# of unexpected failures        9               # of unexpected failures      

92       (83)

# of unexpected successes       2               # of unexpected successes     

4        (2)

# of expected failures          70              # of expected failures        

68       (-2)

# of unsupported tests          337             # of unsupported tests        

337      (0)

 

 

--- Mingquan Pan                                             2011-12-08 03:53:26

21_strings/basic_string/capacity/wchar_t/18654.cc

this case still influence existing test frequently on bf537 and bf533 stamp

board.

 

on bf537 stamp board console:

 

testing uclinux libstdc++^M

18654.exe.28925: page allocation failure: order:12, mode:0xd0^M

Mem-Info:^M

DMA per-cpu:^M

CPU    0: hi:    0, btch:   1 usd:   0^M

active_anon:0 inactive_anon:0 isolated_anon:0^M

active_file:0 inactive_file:0 isolated_file:0^M

unevictable:3243 dirty:0 writeback:0 unstable:0^M

free:7170 slab_reclaimable:248 slab_unreclaimable:174^M

mapped:0 shmem:0 pagetables:0 bounce:0^M

DMA free:28680kB min:4096kB low:5120kB high:6144kB active_anon:0kB

inactive_anon:0kB active_file:0kB inactive_file:0kB unevictable:12972kB

isolated(anon):0kB isolated(file):0kB present:56896kB mlocked:0kB dirty:0kB

writeback:0kB mapped:0kB shmem:0kB slab_reclaimable:992kB

slab_unreclaimable:696kB kernel_stack:184kB pagetables:0kB unstable:0kB

bounce:0kB writeback_tmp:0kB pages_scanned:870 all_unreclaimable? yes^M

lowmem_reserve[]: 0 0 0^M

DMA: 18*4kB 4*8kB 0*16kB 1*32kB 0*64kB 1*128kB 1*256kB 3*512kB 0*1024kB

3*2048kB 1*4096kB 2*8192kB 0*16384kB 0*32768kB = 28680kB^M

3243 total pagecache pages^M

14336 pages RAM^M

574 pages reserved^M

0 pages shared^M

6569 pages non-shared^M

Allocation of length 12587008 from process 6341 (18654.exe.28925) failed^M

DMA per-cpu:^M

CPU    0: hi:    0, btch:   1 usd:   0^M

active_anon:0 inactive_anon:0 isolated_anon:0^M

active_file:0 inactive_file:0 isolated_file:0^M

unevictable:3243 dirty:0 writeback:0 unstable:0^M

free:7170 slab_reclaimable:248 slab_unreclaimable:174^M

mapped:0 shmem:0 pagetables:0 bounce:0^M

DMA free:28680kB min:4096kB low:5120kB high:6144kB active_anon:0kB

inactive_anon:0kB active_file:0kB inactive_file:0kB unevictable:12972kB

isolated(anon):0kB isolated(file):0kB present:56896kB mlocked:0kB dirty:0kB

writeback:0kB mapped:0kB shmem:0kB slab_reclaimable:992kB

slab_unreclaimable:696kB kernel_stack:184kB pagetables:0kB unstable:0kB

bounce:0kB writeback_tmp:0kB pages_scanned:870 all_unreclaimable? yes^M

lowmem_reserve[]: 0 0 0^M

DMA: 18*4kB 4*8kB 0*16kB 1*32kB 0*64kB 1*128kB 1*256kB 3*512kB 0*1024kB

3*2048kB 1*4096kB 2*8192kB 0*16384kB 0*32768kB = 28680kB^M

3243 total pagecache pages^M

Allocation of length 1073745920 from process 6422 (1.exe.28925) failed^M

DMA per-cpu:^M

CPU    0: hi:    0, btch:   1 usd:   0^M

active_anon:0 inactive_anon:0 isolated_anon:0^M

active_file:85 inactive_file:0 isolated_file:0^M

unevictable:3214 dirty:0 writeback:0 unstable:0^M

free:9117 slab_reclaimable:244 slab_unreclaimable:176^M

mapped:0 shmem:0 pagetables:0 bounce:0^M

DMA free:36468kB min:4096kB low:5120kB high:6144kB active_anon:0kB

inactive_anon:0kB active_file:340kB inactive_file:0kB unevictable:12856kB

isolated(anon):0kB isolated(file):0kB present:56896kB mlocked:0kB dirty:0kB

writeback:0kB mapped:0kB shmem:0kB slab_reclaimable:976kB

slab_unreclaimable:704kB kernel_stack:184kB pagetables:0kB unstable:0kB

bounce:0kB writeback_tmp:0kB pages_scanned:0 all_unreclaimable? no^M

lowmem_reserve[]: 0 0 0^M

DMA: 1*4kB 0*8kB 1*16kB 1*32kB 1*64kB 0*128kB 2*256kB 2*512kB 0*1024kB 3*2048kB

1*4096kB 1*8192kB 1*16384kB 0*32768kB = 36468kB^M

3303 total pagecache pages^M

Allocation of length 1073745920 from process 6422 (1.exe.28925) failed^M

..

16728.exe.28925 invoked oom-killer: gfp_mask=0xd0, order=0, oom_adj=0,

oom_score_adj=0

Mem-Info:

DMA per-cpu:

CPU    0: hi:    0, btch:   1 usd:   0

active_anon:0 inactive_anon:0 isolated_anon:0

active_file:0 inactive_file:0 isolated_file:0

unevictable:3721 dirty:0 writeback:0 unstable:0

free:1026 slab_reclaimable:235 slab_unreclaimable:433

mapped:0 shmem:0 pagetables:0 bounce:0

DMA free:4104kB min:4096kB low:5120kB high:6144kB active_anon:0kB

inactive_anon:0kB active_file:0kB inactive_file:0kB unevictable:14884kB

isolated(anon):0kB isolated(file):0kB present:56896kB mlocked:0kB dirty:0kB

writeback:0kB mapped:0kB shmem:0kB slab_reclaimable:940kB

slab_unreclaimable:1732kB kernel_stack:184kB pagetables:0kB unstable:0kB

bounce:0kB writeback_tmp:0kB pages_scanned:139 all_unreclaimable? yes

lowmem_reserve[]: 0 0 0

DMA: 0*4kB 1*8kB 0*16kB 0*32kB 0*64kB 0*128kB 0*256kB 0*512kB 0*1024kB 0*2048kB

1*4096kB 0*8192kB 0*16384kB 0*32768kB = 4104kB

3721 total pagecache pages

14336 pages RAM

574 pages reserved

0 pages shared

12713 pages non-shared

Out of memory: Kill process 162 (sh) score 1 or sacrifice child

Killed process 162 (sh) total-vm:480kB, anon-rss:0kB, file-rss:0kB

sh: page allocation failure: order:7, mode:0xd0

Mem-Info:

DMA per-cpu:

CPU    0: hi:    0, btch:   1 usd:   0

active_anon:0 inactive_anon:0 isolated_anon:0

active_file:0 inactive_file:0 isolated_file:0

unevictable:3721 dirty:0 writeback:0 unstable:0

free:1137 slab_reclaimable:234 slab_unreclaimable:433

mapped:0 shmem:0 pagetables:0 bounce:0

DMA free:4548kB min:4096kB low:5120kB high:6144kB active_anon:0kB

inactive_anon:0kB active_file:0kB inactive_file:0kB unevictable:14884kB

isolated(anon):0kB isolated(file):0kB present:56896kB mlocked:0kB dirty:0kB

writeback:0kB mapped:0kB shmem:0kB slab_reclaimable:936kB

slab_unreclaimable:1732kB kernel_stack:184kB pagetables:0kB unstable:0kB

bounce:0kB writeback_tmp:0kB pages_scanned:0 all_unreclaimable? yes

lowmem_reserve[]: 0 0 0

DMA: 1*4kB 0*8kB 0*16kB 0*32kB 1*64kB 1*128kB 1*256kB 0*512kB 0*1024kB 0*2048kB

1*4096kB 0*8192kB 0*16384kB 0*32768kB = 4548kB

3721 total pagecache pages

14336 pages RAM

574 pages reserved

0 pages shared

12602 pages non-shared

Allocation of length 479232 from process 11843 (sh) failed

DMA per-cpu:

CPU    0: hi:    0, btch:   1 usd:   0

active_anon:0 inactive_anon:0 isolated_anon:0

active_file:0 inactive_file:0 isolated_file:0

unevictable:3721 dirty:0 writeback:0 unstable:0

free:1137 slab_reclaimable:234 slab_unreclaimable:433

mapped:0 shmem:0 pagetables:0 bounce:0

DMA free:4548kB min:4096kB low:5120kB high:6144kB active_anon:0kB

inactive_anon:0kB active_file:0kB inactive_file:0kB unevictable:14884kB

isolated(anon):0kB isolated(file):0kB present:56896kB mlocked:0kB dirty:0kB

writeback:0kB mapped:0kB shmem:0kB slab_reclaimable:936kB

slab_unreclaimable:1732kB kernel_stack:184kB pagetables:0kB unstable:0kB

bounce:0kB writeback_tmp:0kB pages_scanned:0 all_unreclaimable? yes

lowmem_reserve[]: 0 0 0

DMA: 1*4kB 0*8kB 0*16kB 0*32kB 1*64kB 1*128kB 1*256kB 0*512kB 0*1024kB 0*2048kB

1*4096kB 0*8192kB 0*16384kB 0*32768kB = 4548kB

3721 total pagecache pages

Unable to allocate RAM for process text/data, errno 12

init: -/bin/sh exec failed

rage: 0.00, 0.00, 0.00

eth0      Link encap:Ethernet  HWaddr 00:E0:22:FE:47:66 

          inet addr:10.100.4.50  Bcast:10.100.4.255  Mask:255.255.255.0

          UP BROADCAST RUNNING MULTICAST  MTU11500  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:1000

          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

 

lo        Link encap:Local Loopback 

          inet addr:127.0.0.1  Mask:255.0.0.0

          UP LOOPBACK RUNNING  MTU:16436  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:0

          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

 

                           _____________________________________

        a8888b.           / Welcome to the uClinux distribution \

       d888888b.         /       _     _                         \

       8P"YP"Y88        /       | |   |_|            __  __ (TM)  |

       8|o||o|88  _____/        | |    _ ____  _   _ \ \/ /       |

       8'    .88       \        | |   | |  _ \| | | | \  /        |

       8`._.' Y8.       \       | |__ | | | | | |_| | /  \        |

      d/      `8b.       \      \____||_|_| |_|\____|/_/\_\       |

     dP   .    Y8b.       \   For embedded processors including   |

    d8:'  "  `::88b        \    the Analog Devices Blackfin      /

   d8"         'Y88b        \___________________________________/

  :8P    '      :888

   8a.   :     _a88P         For further information, check out:

._/"Yaa_:   .| 88P|            - http://blackfin.uclinux.org/

\    YP"    `| 8P  `.          - http://docs.blackfin.uclinux.org/

/     \.___.d|    .'           - http://www.uclinux.org/

`--..__)8888P`._.'  jgs/a:f    - http://www.analog.com/blackfin

 

Have a lot of fun...

 

 

The detailed log is attached.

 

This case also fails on bf527, but it didn't make kernel panic and the produced

log is ok.

 

If we make the change as in checkin 4784 ( which is applied to

21_strings/basic_string/capacity/char/18654.cc) too, then this case can also

pass on bf537 stamp board.

 

I run 18654 for two times, the first one is before the change, the second one

is after the change.

 

root:/> ./18654.exe

18654.exe: page allocation failure: order:12, mode:0xd0

Hardware Trace:

   0 Target : <0x00124094> { _dump_stack + 0x0 }

     Source : <0x0003c53a> { _warn_alloc_failed + 0x7a } CALL pcrel

   1 Target : <0x0003c53a> { _warn_alloc_failed + 0x7a }

     Source : <0x00124268> { _printk + 0x14 } RTS

   2 Target : <0x00124264> { _printk + 0x10 }

     Source : <0x000104e4> { _vprintk + 0x160 } RTS

   3 Target : <0x000104d8> { _vprintk + 0x154 }

     Source : <0xffa00cd0> { __common_int_entry + 0xd8 } RTI

   4 Target : <0xffa00c6e> { __common_int_entry + 0x76 }

     Source : <0xffa00ab0> { _return_from_int + 0x58 } RTS

   5 Target : <0xffa00ab0> { _return_from_int + 0x58 }

     Source : <0xffa00a86> { _return_from_int + 0x2e } IF !CC JUMP pcrel

 

   6 Target : <0xffa00a58> { _return_from_int + 0x0 }

     Source : <0xffa00c6a> { __common_int_entry + 0x72 } JUMP.L

   7 Target : <0xffa00c68> { __common_int_entry + 0x70 }

     Source : <0xffa0038e> { _asm_do_IRQ + 0x6a } RTS

   8 Target : <0xffa00386> { _asm_do_IRQ + 0x62 }

     Source : <0x00013a50> { ___local_bh_enable + 0x38 } RTS

   9 Target : <0x00013a18> { ___local_bh_enable + 0x0 }

     Source : <0x000140ea> { ___do_softirq + 0xc6 } JUMP.L

  10 Target : <0x000140de> { ___do_softirq + 0xba }

     Source : <0x000140c2> { ___do_softirq + 0x9e } IF CC JUMP pcrel

  11 Target : <0x000140ac> { ___do_softirq + 0x88 }

     Source : <0x0003690e> { _rcu_bh_qs + 0x5a } RTS

  12 Target : <0x000368f4> { _rcu_bh_qs + 0x40 }

     Source : <0x000368c8> { _rcu_bh_qs + 0x14 } IF CC JUMP pcrel

  13 Target : <0x000368b4> { _rcu_bh_qs + 0x0 }

     Source : <0x000140a8> { ___do_softirq + 0x84 } JUMP.L

  14 Target : <0x000140a0> { ___do_softirq + 0x7c }

     Source : <0x00017f66> { _run_timer_softirq + 0xc6 } RTS

  15 Target : <0x00017f00> { _run_timer_softirq + 0x60 }

     Source : <0x00017f4c> { _run_timer_softirq + 0xac } IF !CC JUMP

pcrel (BP)

Stack info:

SP: [0x029f9dc0] <0x029f9dc0> /* kernel dynamic memory */

FP: (0x029f9e9c)

Memory from 0x029f9dc0 to 029fa000

029f9dc0:[000000d0] 0003c53e  00000000  000000d0  00000010  02047724  0000000c

000000d0

029f9de0: 0003c892  00000000  000000d0  00000001  00000000  000200d0  00000000

0000000c

029f9e00: 001a3378  00000001  00000042  001a2964  00000000  029f8008  029f8000

029f8008

029f9e20: 029f8000  00000040  029f8000  011984ac  000200d0  00000000  00001000

00000000

029f9e40: 00000000  00000040  00000000  00000040  001a2964  00000000  00000000

001a2964

029f9e60: 001a2964  00000000  000467f2  00000000  02fb822c  02f9ff2c  0000000c

00000073

029f9e80: 00000000  00000004  0018e9f4  0000000c  0018e5f4  00000000  00000000

(00000000)

029f9ea0:<000140a0> 00c01000  00000c01  029f8000  00000001  02fdfcd0

00046f08  00000000

029f9ec0: 00c01000  02fe9808  029f8000  00000000  04000021  00000003  02fdfd58

ffa00386

029f9ee0: 0019cf6c  00000003  04000021  00000000 <ffa00912> 00046ec4

000000c0  00000000

029f9f00: ffffe000  00000000  00000000  ffc00014  00100000  00000078  04000021

00000000

029f9f20: 00000000  02b4ef84  00008000  00002000  00000000  029fa000  02b4ef84

02b4ef84

029f9f40: 02b70c72  ffa00eb8  02003025  0299e843  02ffc59f  0299e83c  02ffc59e

00000000

029f9f60: 00000000  00000000  00000000  00000000  00000000  00000000  7ffff000

000000c0

029f9f80: 00000137  00000000  00000000  00000000  00000000  0000005b  00001802

00000001

029f9fa0: fffffffc  00000007  00000003  0299eba8  01a00010  02fdfcc4  02fdfcd0

02fe9808

029f9fc0: 02fdfdb4  02fe9808  00000000  02b74ee0  000000c0  00000000  02fe9128

00000000

029f9fe0: 00000000  04000021  00000003  00c01000  00000000  00000000  000000c0

00000006

Return addresses in stack:

   frame  1 : <0x000140a0> { ___do_softirq + 0x7c }

    address : <0xffa00912> { _system_call + 0x6a }

Mem-Info:

DMA per-cpu:

CPU    0: hi:    0, btch:   1 usd:   0

active_anon:0 inactive_anon:0 isolated_anon:0

active_file:0 inactive_file:0 isolated_file:0

unevictable:1803 dirty:0 writeback:0 unstable:0

free:8536 slab_reclaimable:218 slab_unreclaimable:151

mapped:0 shmem:0 pagetables:0 bounce:0

DMA free:34144kB min:4096kB low:5120kB high:6144kB active_anon:0kB

inactive_anon:0kB active_file:0kB inactive_file:0kB unevictable:7212kB

isolated(anon):0kB isolated(file):0kB present:56896kB mlocked:0kB ds

lowmem_reserve[]: 0 0 0

DMA: 20*4kB 6*8kB 10*16kB 2*32kB 2*64kB 1*128kB 1*256kB 5*512kB 2*1024kB

4*2048kB 1*4096kB 2*8192kB 0*16384kB 0*32768kB = 34144kB

1803 total pagecache pages

14336 pages RAM

574 pages reserved

0 pages shared

5206 pages non-shared

Allocation of length 12587008 from process 176 (18654.exe) failed

DMA per-cpu:

CPU    0: hi:    0, btch:   1 usd:   0

active_anon:0 inactive_anon:0 isolated_anon:0

active_file:0 inactive_file:0 isolated_file:0

unevictable:1803 dirty:0 writeback:0 unstable:0

free:8536 slab_reclaimable:218 slab_unreclaimable:151

mapped:0 shmem:0 pagetables:0 bounce:0

DMA free:34144kB min:4096kB low:5120kB high:6144kB active_anon:0kB

inactive_anon:0kB active_file:0kB inactive_file:0kB unevictable:7212kB

isolated(anon):0kB isolated(file):0kB present:56896kB mlocked:0kB ds

lowmem_reserve[]: 0 0 0

DMA: 20*4kB 6*8kB 10*16kB 2*32kB 2*64kB 1*128kB 1*256kB 5*512kB 2*1024kB

4*2048kB 1*4096kB 2*8192kB 0*16384kB 0*32768kB = 34144kB

1803 total pagecache pages

terminate called after throwing an instance of 'std::bad_alloc'

  what():  std::bad_alloc

ABRT

root:/>

root:/>

root:/> ls

16728.exe  dev        init       proc       sys        var

18654.exe  etc        lib        root       tmp

bin        home       mnt        sbin       usr

root:/> ./18654.exe

root:/> ./16728.exe

root:/> version

kernel:    Linux release 3.0.8-ADI-2011R1-svn10254, build #14 Thu Dec 8

05:21:08 CST 2011

toolchain: bfin-uclinux-gcc release gcc version 4.3.5 (ADI-2011R1-RC4)

user-dist: release svn-10560, build #4 Thu Dec 8 05:20:32 CST 2011

 

 

So shall we also apply the change to this case ,either?

 

--- Stuart Henderson                                         2012-03-12 12:13:03

Hi Grace,

Yes, you are correct.  the same fix can be applied, which I have done.

 

Setting as fixed for 2012R1.

 

Stu

 

--- Mingquan Pan                                             2012-05-15 04:03:17

Yes, after check in this fix, this case pass now. Close.

 

 

 

    Files

    Changes

    Commits

    Dependencies

    Duplicates

    Associations

    Tags

 

File Name     File Type     File Size     Posted By

reset_board_log.normal.test    application/octet-stream    207962    Mingquan Pan

linux-uclibc.diff    text/x-patch    39858    Mingquan Pan

libstdc++-4.3.log.gz    application/x-gzip    108782    Mingquan Pan

Outcomes