head	1.2;
access;
symbols
	RELENG_6_4_0_RELEASE:1.1.1.1.34.1
	RELENG_6_4:1.1.1.1.34.1.0.4
	RELENG_6_4_BP:1.1.1.1.34.1
	RELENG_6_3_0_RELEASE:1.1.1.1.34.1
	RELENG_6_3:1.1.1.1.34.1.0.2
	RELENG_6_3_BP:1.1.1.1.34.1
	RELENG_6_2_0_RELEASE:1.1.1.1
	RELENG_6_2:1.1.1.1.0.42
	RELENG_6_2_BP:1.1.1.1
	RELENG_5_5_0_RELEASE:1.1.1.1
	RELENG_5_5:1.1.1.1.0.40
	RELENG_5_5_BP:1.1.1.1
	RELENG_6_1_0_RELEASE:1.1.1.1
	RELENG_6_1:1.1.1.1.0.38
	RELENG_6_1_BP:1.1.1.1
	RELENG_6_0_0_RELEASE:1.1.1.1
	RELENG_6_0:1.1.1.1.0.36
	RELENG_6_0_BP:1.1.1.1
	RELENG_6:1.1.1.1.0.34
	RELENG_6_BP:1.1.1.1
	RELENG_5_4_0_RELEASE:1.1.1.1
	RELENG_5_4:1.1.1.1.0.32
	RELENG_5_4_BP:1.1.1.1
	RELENG_4_11_0_RELEASE:1.1.1.1
	RELENG_4_11:1.1.1.1.0.30
	RELENG_4_11_BP:1.1.1.1
	RELENG_5_3_0_RELEASE:1.1.1.1
	RELENG_5_3:1.1.1.1.0.28
	RELENG_5_3_BP:1.1.1.1
	RELENG_5:1.1.1.1.0.26
	RELENG_5_BP:1.1.1.1
	RELENG_4_10_0_RELEASE:1.1.1.1
	RELENG_4_10:1.1.1.1.0.24
	RELENG_4_10_BP:1.1.1.1
	RELENG_5_2_1_RELEASE:1.1.1.1
	RELENG_5_2_0_RELEASE:1.1.1.1
	RELENG_5_2:1.1.1.1.0.22
	RELENG_5_2_BP:1.1.1.1
	RELENG_4_9_0_RELEASE:1.1.1.1
	RELENG_4_9:1.1.1.1.0.20
	RELENG_4_9_BP:1.1.1.1
	RELENG_5_1_0_RELEASE:1.1.1.1
	RELENG_5_1:1.1.1.1.0.18
	RELENG_5_1_BP:1.1.1.1
	RELENG_4_8_0_RELEASE:1.1.1.1
	RELENG_4_8:1.1.1.1.0.16
	RELENG_4_8_BP:1.1.1.1
	RELENG_5_0_0_RELEASE:1.1.1.1
	RELENG_5_0:1.1.1.1.0.14
	RELENG_5_0_BP:1.1.1.1
	RELENG_4_7_0_RELEASE:1.1.1.1
	RELENG_4_7:1.1.1.1.0.12
	RELENG_4_7_BP:1.1.1.1
	RELENG_4_6_2_RELEASE:1.1.1.1
	RELENG_4_6_1_RELEASE:1.1.1.1
	v5_2_20020615:1.1.1.1
	RELENG_4_6_0_RELEASE:1.1.1.1
	RELENG_4_6:1.1.1.1.0.10
	RELENG_4_6_BP:1.1.1.1
	v5_2_20020518:1.1.1.1
	RELENG_4_5_0_RELEASE:1.1.1.1
	RELENG_4_5:1.1.1.1.0.8
	RELENG_4_5_BP:1.1.1.1
	RELENG_4_4_0_RELEASE:1.1.1.1
	RELENG_4_4:1.1.1.1.0.6
	RELENG_4_4_BP:1.1.1.1
	v5_2_20010512:1.1.1.1
	RELENG_4_3_0_RELEASE:1.1.1.1
	RELENG_4_3:1.1.1.1.0.4
	RELENG_4_3_BP:1.1.1.1
	RELENG_4_2_0_RELEASE:1.1.1.1
	v5_1_20001009:1.1.1.1
	RELENG_4_1_1_RELEASE:1.1.1.1
	PRE_SMPNG:1.1.1.1
	RELENG_4_1_0_RELEASE:1.1.1.1
	v5_1_20000701:1.1.1.1
	RELENG_4_0_0_RELEASE:1.1.1.1
	RELENG_4:1.1.1.1.0.2
	RELENG_4_BP:1.1.1.1
	v5_0:1.1.1.1
	v5_0_990821:1.1.1.1
	NCURSES:1.1.1;
locks; strict;
comment	@# @;


1.2
date	2007.01.20.07.39.17;	author rafan;	state dead;
branches;
next	1.1;

1.1
date	99.08.24.01.06.47;	author peter;	state Exp;
branches
	1.1.1.1;
next	;

1.1.1.1
date	99.08.24.01.06.47;	author peter;	state Exp;
branches
	1.1.1.1.34.1;
next	1.1.1.2;

1.1.1.2
date	2007.01.20.08.21.19;	author rafan;	state dead;
branches;
next	;

1.1.1.1.34.1
date	2007.04.06.17.50.02;	author rafan;	state dead;
branches;
next	;


desc
@@


1.2
log
@- Resolve conflicts
- Remove files that are removed in vender branch

Approved by:	delphij
@
text
@#!/usr/bin/perl
#
# tracemunch -- compactify ncurses trace logs
#
# The error logs produced by ncurses with tracing enabled can be very tedious
# to wade through.  This script helps by compacting runs of log lines that
# can be conveniently expressed as higher-level operations.
#
# ($Id: tracemunch,v 1.2 1995/10/06 15:02:37 esr Exp $)

$putattr="PutAttrChar\\('(.)' = 0x.., {A_NORMAL}\\) at \\(([0-9]+), ([0-9]+)\\)";
$waddnstr="waddnstr\\(0x([0-9a-f]+),\"([^\"]+)\",[0-9]+\\) called {A_NORMAL}";

sub transaddr
{
    $arg = $_[0];

    $arg =~ s/$curscr/curscr/ if ($curscr);
    $arg =~ s/$newscr/newscr/ if ($newscr);
    $arg =~ s/$stdscr/stdscr/ if ($stdscr);

    return $arg;
}

while (<STDIN>)
{
CLASSIFY: {
	# Transform window pointer addresses so it's easier to compare logs
    	$awaiting = "curscr" if ($_ =~ /creating curscr/);
    	$awaiting = "newscr" if ($_ =~ /creating newscr/);
    	$awaiting = "stdscr" if ($_ =~ /creating stdscr/);
	if ($awaiting && $_ =~ /newwin: returned window is 0x([0-9a-f]+)/)
	{
	    $curscr = "0x$1" if ($awaiting eq "curscr");
	    $newscr = "0x$1" if ($awaiting eq "newscr");
	    $stdscr = "0x$1" if ($awaiting eq "stdscr");
	    $awaiting = "";
	}

	# Compactify runs of PutAttrChar calls (TR_CHARPUT)
	if ($_ =~ /$putattr/)
	{
		$putattr_chars = $1;
		$starty = $2;
		$startx = $3;
		while (<STDIN>)
		{
			if ($_ =~ /$putattr/) {
				$putattr_chars .= $1;
			} else {
				last;
			}
		}
		print "RUN of PutAttrChar()s: \"$putattr_chars\" from ${starty}, ${startx}\n";
		redo CLASSIFY;
	}

	# Compactify runs of waddnstr calls (TR_CALLS)
	if ($_ =~ /$waddnstr/)
	{
		$waddnstr_chars = $2;
		$winaddr = $1;
		while (<STDIN>)
		{
			if ($_ =~ /$waddnstr/ && $1 eq $winaddr) {
				$waddnstr_chars .= $2;
			} else {
				last;
			}
		}
		$winaddstr = &transaddr($winaddr);
		print "RUN of waddnstr()s: $winaddr, \"$waddnstr_chars\"\n";
		redo CLASSIFY;
	}

	# More transformations can go here

	# Repeated runs of anything
	$anyline = &transaddr($_);
	$repeatcount = 1;
	while (<STDIN>) {
	    if (&transaddr($_) eq $anyline) {
		$repeatcount++;
	    } else {
		last;
	    }
	}
	if ($repeatcount > 1) {
		print "${repeatcount} REPEATS OF $anyline";
	} else {
		print $anyline
	}
	redo CLASSIFY if $_;

	} # :CLASSIFY
}

# tracemunch ends here
@


1.1
log
@Initial revision
@
text
@@


1.1.1.1
log
@Import unmodified (but trimmed) ncurses 5.0 prerelease 990821.
This contains the full eti (panel, form, menu) extensions.
bmake glue to follow.

Obtained from:	ftp://ftp.clark.net/pub/dickey/ncurses
@
text
@@


1.1.1.1.34.1
log
@MFC: ncurses 5.6-20061217

Approved by:	delphij (mentor)
Tested by:	several people on stable@@
@
text
@@


1.1.1.2
log
@Remove files that are no longer exist.

Approved by:	delphij
@
text
@@

