bug-gnu-utils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

diff 2.8.1 dumps core on HPUX 10.20


From: Jost Martin
Subject: diff 2.8.1 dumps core on HPUX 10.20
Date: Fri, 29 Nov 2002 11:56:00 +0100

Hello,

I'm trying to compile diff 2.8.1 on HPUX 10.20 using the HP ANSI-C-Compiler.

This works, 'diff --version' works too, but even simple diffs make diff 
core-dump:
delphi:/pd-sw/tools/diffutils/diffutils-2.8.1/src> ./diff version.c 
version.c.~1~
Bus error (core dumped)

Compiling works smoothly, I just get two warnings about exceeding the optimizer 
limits.
Linking gets:
cc  +DAportable -Aa +O2  -D_POSIX_SOURCE -D_HPUX_SOURCE -D_XOPEN_SOURCE 
-D_XOPEN_SOURCE_EXTENDED  -L/pd/libs/lib/ -o diff  analyze.o context.o diff.o 
dir.o ed.o ifdef.o io.o normal.o side.o util.o version.o ../lib/libdiffutils.a
/usr/ccs/bin/ld: (Warning) LDW instruction from file analyze.o(0x168c) accesses 
nonaligned data - check alignment options.
/usr/ccs/bin/ld: (Warning) LDW instruction from file context.o(0x178) accesses 
nonaligned data - check alignment options.
/usr/ccs/bin/ld: (Warning) LDW instruction from file context.o(0x388) accesses 
nonaligned data - check alignment options.
/usr/ccs/bin/ld: (Warning) LDW instruction from file context.o(0x828) accesses 
nonaligned data - check alignment options.
/usr/ccs/bin/ld: (Warning) LDW instruction from file io.o(0xf0c) accesses 
nonaligned data - check alignment options.
/usr/ccs/bin/ld: (Warning) LDW instruction from file util.o(0xd90) accesses 
nonaligned data - check alignment options.
/usr/ccs/bin/ld: (Warning) LDW instruction from file util.o(0xe14) accesses 
nonaligned data - check alignment options.
/usr/ccs/bin/ld: (Warning) LDW instruction from file util.o(0xe68) accesses 
nonaligned data - check alignment options.

[Those sound highly suspect ...]

Backtrace gets: (Sorry, as usual, the problem disappears when compiling with 
debug-info)
#0  0xa41c in find_identical_ends () from 
/home/pd/pd-sw/tools/diffutils/diffutils-2.8.1/src/./diff
#1  0xa528 in read_files () from 
/home/pd/pd-sw/tools/diffutils/diffutils-2.8.1/src/./diff
#2  0x504c in diff_2_files () from 
/home/pd/pd-sw/tools/diffutils/diffutils-2.8.1/src/./diff
#3  0x796c in compare_files () from 
/home/pd/pd-sw/tools/diffutils/diffutils-2.8.1/src/./diff
#4  0x7074 in main () from 
/home/pd/pd-sw/tools/diffutils/diffutils-2.8.1/src/./diff

So I tried purify with debug-infos.
This is what I got:
[The first message seems to be caused, by the fact, that purify can't find 
/usr/lib/nls/loc/locales.1/C]

****  Purify instrumented ./diff (pid 22136 at Fri Nov 29 10:49:33 2002)
  * Purify 2001a.04.00 HP-UX (32-bit) Copyright (C) 1992-2001 Rational Software 
Cor
p.  All rights reserved.
  * For contact information type: "purify -help"
  * For TTY output, use the option "-windows=no"
  * Command-line: ./diff version.c version.c.~1~
  * Options settings: -purify \
    -purify-home=/pd/rational/releases/purify.hp.2001a.04.00
  * License successfully checked out.

****  Purify instrumented ./diff (pid 22136)  ****
PAR: Bad function parameter:
  * This is occurring while in:
        shl_load       [libdld.1]
        setlocale_r    [libc.1]
        setlocale      [libc.1]
        main           [diff.o]
        _start         [libc.1]
        $START$        [crt0.o]
  * shl_load("/usr/lib/nls/loc/locales.1/C", 0x8, 0x0) file (arg #1) not 
instrument
ed.
    Check that it is a valid shared library.

****  Purify instrumented ./diff (pid 22136)  ****
ABR: Array bounds read:
  * This is occurring while in:
        find_identical_ends [io.o]
        read_files     [io.o]
        diff_2_files   [analyze.o]
        compare_files  [diff.o]
        main           [diff.o]
        _start         [libc.1]
  * Reading 4 bytes from 0x400189b8 in the zero'd data, bss section (1 byte at 
0x40
0189b8 illegal).
  * Address 0x400189b8 is       16 bytes past start of global variable 
"ignore_rege
xp".
    This is defined in diff.

****  Purify instrumented ./diff (pid 22136)  ****
ABR: Array bounds read:
  * This is occurring while in:
        diff_2_files   [analyze.o]
        compare_files  [diff.o]
        main           [diff.o]
        _start         [libc.1]
        $START$        [crt0.o]
  * Reading 4 bytes from 0x400189b8 in the zero'd data, bss section (1 byte at 
0x40
0189b8 illegal).
  * Address 0x400189b8 is       16 bytes past start of global variable 
"ignore_rege
xp".
    This is defined in diff.

****  Purify instrumented ./diff (pid 22136)  ****
ABR: Array bounds read:
  * This is occurring while in:
        analyze_hunk   [util.o]
        print_normal_hunk [normal.o]
        print_script   [util.o]
        print_normal_script [normal.o]
        diff_2_files   [analyze.o]
        compare_files  [diff.o]
  * Reading 4 bytes from 0x400189b8 in the zero'd data, bss section (1 byte at 
0x40
0189b8 illegal).
  * Address 0x400189b8 is       16 bytes past start of global variable 
"ignore_rege
xp".
    This is defined in diff.

****  Purify instrumented ./diff (pid 22136)  ****
Current file descriptors in use: 4
FIU: file descriptor 0: <stdin>
FIU: file descriptor 2: <stderr>
FIU: file descriptor 26: <reserved for Purify internal use>
FIU: file descriptor 27: <reserved for Purify internal use>

****  Purify instrumented ./diff (pid 22136)  ****
Purify: Searching for all memory leaks...

Memory leaked: 0 bytes (0%); potentially leaked: 0 bytes (0%)

Purify Heap Analysis (combining suppressed and unsuppressed blocks)
                         Blocks        Bytes
              Leaked          0            0
  Potentially Leaked          0            0
              In-Use          5         2541
  ----------------------------------------
     Total Allocated          5         2541

****  Purify instrumented ./diff (pid 22136)  ****
  * Program exited with status code 1.
  * 4 access errors, 4 total occurrences.
  * 0 bytes leaked.
  * 0 bytes potentially leaked.
  * Basic memory usage (including Purify overhead):
    543936 code
    107096 data/bss
    32168 heap (peak use)
    528 stack
  * Shared library memory usage (including Purify overhead):
    156672 dld_pure_p3_c0_105182148_B1020_114688.sl (shared code)
    9664 dld_pure_p3_c0_105182148_B1020_114688.sl (private data)
    3289088 libc.1_pure_p3_c0_105182148_B1020_1867776 (shared code)
    184320 libc.1_pure_p3_c0_105182148_B1020_1867776 (private data)
    12288 libdld.1_pure_p3_c0_105182148_B1020_12288 (shared code)
    4096 libdld.1_pure_p3_c0_105182148_B1020_12288 (private data)

Martin





reply via email to

[Prev in Thread] Current Thread [Next in Thread]