From lechner@cs.uml.edu  Mon Aug 21 00:12:38 2006
Received: from saturn.cs.uml.edu (cs.uml.edu [129.63.8.2]) by earth.cs.uml.edu (8.12.11.20060308/8.11.6) with ESMTP id k7L4Cc6S010229; Mon, 21 Aug 2006 00:12:38 -0400
Received: from saturn.cs.uml.edu (localhost [127.0.0.1]) by saturn.cs.uml.edu (8.12.9/8.12.9) with ESMTP id k7L4CbXi210726; Mon, 21 Aug 2006 00:12:38 -0400 (EDT)
Received: (from lechner@localhost) by saturn.cs.uml.edu (8.12.9/8.12.9/Submit) id k7L4Cbap220806; Mon, 21 Aug 2006 00:12:37 -0400 (EDT)
From: Bob Lechner <lechner@cs.uml.edu>
Message-Id: <200608210412.k7L4Cbap220806@saturn.cs.uml.edu>
Subject: Re: BDE issues :)
To: sfrye@cs.uml.edu (Scott Frye)
Date: Mon, 21 Aug 2006 00:12:37 -0400 (EDT)
Cc: lechner@cs.uml.edu (Bob Lechner)
In-Reply-To: <Pine.LNX.4.64.0608200735400.12433@mercury.cs.uml.edu> from "Scott Frye" at Aug 20, 2006 07:52:44 AM
X-Mailer: ELM [version 2.5 PL2]
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Content-Length: 7550
Lines: 174
X-Status: 
X-Keywords:                 
X-UID: 1066
X-Evolution: 00000554-0000
Status: RO

RJLRef: $RBGB/bdeStatusReply2sfrye060820.txt
(linked from $PH/06f522)

> From sfrye@cs.uml.edu  Sun Aug 20 07:52:51 2006
> Subject: BDE issues :)
> Professor,
> 
> #1 - as far as the tex files go, I will try to link them to the idraw 
> directory under bde/doc/idraw.  I did have a copy of it but didn't think 
> to look there.  I tried to makethe changes on my machine but I don't think 
> my TEX editor is up to the task.  It generated a one page pdf file.  The 
> program that the woman at work used was UltraEdit with a Tex plugin.  I'm 
> going to try to get my hands on a copy sometime.

[RJL:see previous msg.]

> 
> #2 refactoring of pr_util without fixing BDE!  I'll keep this in mind. 
> Maybe I'll stumble across some solutions to BDE bugs along the way, maybe 
> not.  Maybe we are getting to a point where we should just rewrite BDE 
>
[RJL: rewrite bde from scratch? Perhaps so. I MIGHT, if I were you,
without my investment in bde-code-reading and no Linux PC at home.
But I balk at the sheer code volume to restart, and am highly motivated 
to prove that my refactoring-with-ghost-vars approach will work 
on pr_util code migration from chgen to gencpp. 
So I am stuck with trying to regain a working version of bde for 06f522
and beginning this gvars_refactoring process frm that start point.

Some key architectural ideas in bde and chgen/gencpp are designed 
to permit the  following changes, so I believe the work can be modularized
into tasks and partitioned among a team .

Items 3 and 11 have a big impact on productivity and so have max priority. 


I will try listing them again -  from memory
(without definition because I go off into tangents that way:-)

1. Packaging for PCVS and the Eclipse IDE

2. Absorbing pr_util changes since 04f523 into chgen (v14)
   (retaining schema independence from bde).

3. Eliminating the version# byte from pfkeys (and removing pr_init() from pr_load.c).
   (A MAJOR code reduction, that permits version control of DB tables by CVS.)

4. Refactoring bde to use chgen13's pr_accessors.c instead of pr_{get,set}_type.

5. Refactoring bde to use pr_util from gencpp This includes: 
	(a) combining chgen's intrusive parent-child lists with gencpp's STL
   Vector container classes for individual table types;
   and  (b) migrating from chgen13's pr_accessors.c to gencpp's equivalent 
   XX::{get,set)field class methods.).

6. Enhancing LCP to support pointers to guard condition evaluation functions
   along with pointers to state action routines. (Ref: TRAIL paper)

7. Refactoring bde's state actions as [guarded] single calls. 
   This will permit migration of bde toward LCP state model 
   interpretation and auto-generation of its table-driven control flow
   by gencpp enhancements.

8. Migrating the X11-specific GUI of bde to a subclass under the fox PI-GUI,
   and perhaps under 05f523/ralmonte's generic GUI on top of fox
   (fox as a special case of a wider class of PI-GUI platforms). 
   [Ref: $PH/05f523/bde2fox (linked from $PH/06f522/05s523bde2foxProject)]

9. Evolving 05s523bde2foxProject to support MSWindows GUI as well as X11.
 
10.Resume work on logging and replay for bde, as a test case for
   generic code generaton by gencpp.

11. Last but not least: improving bde's make process by
  (a) removing Makefile dependence for fully concurrent builds of 4 versions.
  (b) avoiding redundant compilation of unchanged files in src and pr_util*.
  (This may require a more modern process than imake and gmake)
[end RJL]

> 
> #3 BDE Errors.
> Since I've been using the xmkmfnolog.csh most of the compile problems have 
> gone away.  I was under the impression that this only had to be used the 
> 1st time and that afterwards, I could use the make command.  I THINK this 
> might still work as long as I always apply it to the root bde directory as 
> you recommended.
> 
> However, I am still getting some errors like:
> 
> ../src/fileio.cc: In function .void printrowcounts(char*).:
> ../src/fileio.cc:872: error: .get_rcount. was not declared in this scope
> 
> I traced the problem down to the definition of the get_rcount macro.  This 
> macro is defined in bde/pr_util_nolog/i386-linux/probj/dprint.h.
> 
> However there is no include for this file in my version of fileio.cc.

[RJL: I spent a month or more debugging set_rcount and moving it around
 so it can become useful. Right now it's only for debugging the part
of bde.cc, init.cc and calls to fileio.cc iand *menu* files 
that PRECEDE X11's event loop. This is because I can't get any printouts
or File/Save* output, just empty or non-existxent files.

Nor can I get Create_HGDialog box to recognize any pr_loaded HG-rows.
My comments in fileio.cc  suggest that last year's merge and/or my
revs may have merged file-read and HG_row-selection code  blocks
by losing some critical code here. 

My bdegen13/bde compiles OK right now, but has not been fully checked in.
dprint.h is #included indirectly from graph.h I believe.

I have been giving my gdb runs more detailed inspections, 
by extracting and summarizing outputs, which is time-consuming,
in $RBGB/test/bde*<date.time>. using $RBGFB/test/cmd.<date> as 
a starting point (modified online).

Look at $RBGB/prep.csh which sets up command abbrev'ns for testing. 
($RBGB is ~lechner/bde2alpha_rl/sandbox/bdeNT050526/bdegen13/bde)


dprint,h is multiply #included by nested #includes.
(94*schema.h is #included in dprint.c only 
because I put printrowcounts() there.
That won't last - other dprint functions are schema-invariant,
but printrowcounts() is schema-dwaspecific.
Nevertheless, both  should be auto-generated from chgen 
for an arbitrary schema.sch input. 
Here is the evidence:
-----
grep "dprint.h" */*.{h,c,cc} > $RBGB/dprint.h.includes.060820
[edited to remove obsolete file refs and comments-RJL060820]
-----------------------------------------------------
pr_util_log/94sbde_schema.h:18:#include "dprint.h"
pr_util_nolog/94sbde_schema.h:18:#include "dprint.h"

pr_util_log/dprint.c:38:#include "94sbde_schema.h"  // #includes "dprint.h"
pr_util_nolog/dprint.c:38:#include "94sbde_schema.h"  // #includes "dprint.h""
pr_util_nolog/pr_load.c:39:/* includes dprint.h but not lut.h */

src/handler.cc:125:#include "dprint.h"
src/leftmenu.cc:99:#include "dprint.h"
src/menubar.cc:102:#include "94sbde_schema.h"   /* for dprint.h */
src/leftmenu_cb.cc:206:#include "dprint.h"      // for EP and DP macros
src/menubar_cb.cc:128:#include "94sbde_schema.h"      /* for dprint.h */
src/strdup.cc:81:#include "dprint.h"
---------------------------------------------------------
[end RJL]

> 
> I did a diff against your copy and found MANY differences (diff file at 
> bottom of email) but a cvs status indicates that I have the latest 
> version.  It looks like the version in your directory doesn't even call 
> get_rcount like the version in cvs does.
> 
> Have you checked the latest version of this file into cvs?  I will try to 
> compile with your version later this weekend if I get some time and see if 
> it fixes the error.
> 

[RJL: No - see above. I will try to update CVSROOT repository tomorrow.
It's time-consuming since I must edit cvs diffs into reviision comments.

CVS checkin will include pr_util_[no]log mods that chgen does NOT
produce, so do NOT rerun chgen. 

My current pr_util_nolog version compiles, so your copy should also.

My pr_util_log version probably compiles but its sources do NOT YET 
track my runtime bug'fixes' in pr_util_nolog.]
[end RJL]

> Have a nice weekend, despite the rain... :)
[Thanks - RJL]
[cut]

From lechner@cs.uml.edu  Mon Aug 21 00:17:06 2006
Received: from saturn.cs.uml.edu (cs.uml.edu [129.63.8.2]) by earth.cs.uml.edu (8.12.11.20060308/8.11.6) with ESMTP id k7L4H6I5010276; Mon, 21 Aug 2006 00:17:06 -0400
Received: from saturn.cs.uml.edu (localhost [127.0.0.1]) by saturn.cs.uml.edu (8.12.9/8.12.9) with ESMTP id k7L4H5Xi225662; Mon, 21 Aug 2006 00:17:05 -0400 (EDT)
Received: (from lechner@localhost) by saturn.cs.uml.edu (8.12.9/8.12.9/Submit) id k7L4H5Ls207213; Mon, 21 Aug 2006 00:17:05 -0400 (EDT)
From: Bob Lechner <lechner@cs.uml.edu>
Message-Id: <200608210417.k7L4H5Ls207213@saturn.cs.uml.edu>
Subject: Re: BDE issues :)  (this reply: LaTex/UEdit/ghostview only) (fwd)
To: sfrye@cs.uml.edu (Scot Frye)
Date: Mon, 21 Aug 2006 00:17:05 -0400 (EDT)
Cc: lechner@cs.uml.edu (Bob Lechner)
X-Mailer: ELM [version 2.5 PL2]
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Content-Length: 5351
Lines: 134
X-Status: 
X-Keywords:                 
X-UID: 1067
X-Evolution: 00000556-0000
Status: RO

Scot - THis haS been saved to $CASE/latex/latex2psInfo.060820
RJL06021

Forwarded message:
> From lechner@cs.uml.edu  Sun Aug 20 17:29:55 2006
> From: Bob Lechner <lechner@cs.uml.edu>
> Message-Id: <200608202129.k7KLTt0h104741@saturn.cs.uml.edu>
> Subject: Re: BDE issues :)  (this reply: LaTex/UEdit/ghostview only)
> To: sfrye@cs.uml.edu (Scott Frye)
RJLRef: $CASE/latex/latex2psInfo.060820
> 
> > From sfrye@cs.uml.edu  Sun Aug 20 07:52:51 2006
> > Subject: BDE issues :)
> > 
> > Professor,
> > 
> > #1 - as far as the tex files go, I will try to link them to the idraw 
> > directory under bde/doc/idraw.  I did have a copy of it but didn't think 
> > to look there.  I tried to makethe changes on my machine but I don't think 
> > my TEX editor is up to the task.  It generated a one page pdf file.  The 
> > program that the woman at work used was UltraEdit with a Tex plugin.  I'm 
> > going to try to get my hands on a copy sometime.
> > 
> 
> >From RJL:
> 
> I bought UltraEdit (approx $40) on JHeines advice last year.
> It's a nice editor with bracket-matching and line-numbering features.
> Lots of language syntaxes are suported.
> 
> Here is what it says re: LaTex 
> under Syntax Highlighting (Advanced Menu/Config):
> 
> ---------------
> LaTex/Tex Specific
> 
> TeX/LaTeX is quite different from other languages and each command starts with a '\'.  To better facilitate the use of UltraEdit for editing TeX/LaTeX files the "LATEX_LANG" keyword was added.  When this keyword is present, UltraEdit has special handling for syntax highlighting to allow words to be appropriately handled and highlighted with the '\', and with consecutive words.
> 
> This also allows the recognized words to be placed in the wordfile without all of them being on the same line.  If the word begins with '\' then the second character is used to determine which line the word should be on.  All words beginning with '\a' should be on the same line as other words beginning with '\a' or 'a'.  In the same way, all words beginning with '\b' should be on the same line as other words beginning with '\b' or 'b' but on a different line from those starting with '\a' etc.
> 
> Below is an example portion of a word file for TeX/LaTeX:
> 
> /L4"TeX/LaTeX" LATEX_LANG File Extensions = TEX LATEX
> 
> /C1
> 
> 
> Note: Any of the normal comment indications may also be used 
> (line comments, block comments).
> ------------------
> 
> I don't know about other potential aspects of a Tex 'plugin'.
> POSSIBLY it supports xvdi and dvi2ps after which there can be ps2pdf.
> 
> 
> But Mercury supports what (I think) you need. 
> Unfortunately ghostview seems to be missing from Mercury/RedHat Linux.
> I have not tested these for year, but here is a DFD:
> -----------------
> (/usr/bin/latex)	
> 	|
>     [name.tex]
> 	|
> 	V
> (/usr/bin/xdvi)
> 	|
>     [name.dvi
> 	|
> 	V
> (/usr/bin/dvips)
> 	|
>     [name.ps] ---> (ghostview is missing?)------
> 	|\                                     |  
> 	| \__________________________________  |
> 	V                                    \ |
> (/usr/local/bin/ps2pdf)                       \|/
> 	|                                   print?
> 	V
>     [name.pdf]
> -----------------
> 
> BTWay, ghostview DOES work on saturn, but only inside an xterm window.
> 
> I created a symlink to $CASE/95f523//95sbde/bde bde
> in $CASE/94f523/94fbde/ltang:
> ------------
> total 28
> drwxr-xr-x   3 7021 4096 Aug 20 17:14 .
> drwxr-xr-x  11 7021 4096 Dec  3  2002 ..
> lrwxrwxrwx   1 fac    26 Aug 20 17:14 bde -> ../../../95s523/95sbde/bde
> drwxr-xr-x   2 fac  4096 Aug 17 21:41 writepu
> mercury(122)>
> mercury(136)> ls $CASE/94f523/94fbde/ltang/bde/doc/
> -------------------------
> 94fbde_report.tex      bdeUserGuide.log      idraw
> 96fbdecode_report.tex  bdeUserGuide.ps       index.html.bak
> aareadme               bdeUserGuide.tex      lcp_architecture.3may96.idraw
> bdeUserGuide.aux       bdeUserGuide.tex.bak  newfigures.hlp
> bdeUserGuide.bbox2.ps  bdeUserGuide.toc      public_html
> bdeUserGuide.dvi       CVS
> --------------------------
> 
> mercury(135)> ls $CASE/94f523/94fbde/ltang/bde/doc/idraw
> ------------------------
> 93sbde3_Bpt_create.idraw      bdetreeHG000001.bbox2.ps
> 94fbde.idraw                  bdetreeHG000001.ps
> 94fLinkCreate_SM.idraw        caption_create_move.idraw
> 94fNodeLinkDelete_SM.idraw    caption_delete.idraw
> 95sLinkCreate_SM.idraw        caption_resize.idraw
> 95sLinkDelete_SM.idraw        caption_text_create.idraw
> 95sNodeDelete_SM.idraw        caption_text_delete.idraw
> 96sbdesym.idraw               caption_text_move.idraw
> bbox.hlp                      caption_text_restyle.idraw
> bdeabort.dat                  caption_text_select.idraw
> bde_project_guidelines.idraw  CVS
> bdetree.24oct95.ps            guildline.idraw
> bdetree.dat                   sample.dat
> bdetreeHG000001.bbox1.ps
> mercury(136)>
> ------------------------
> 
> On saturn, I called ghostview then File/Open 
> I was able to view one state diagram, and also bdetree.24oct95.ps.
> (.idraw is a subset of .ps). 
> (cd to the right path first - it is tedious insode ghostview.)
> It's too bad idraw is not available currently.
> 
> --------
> saturn.cs.uml.edu(7)> which idraw
> idraw: Command not found.
> saturn.cs.uml.edu(8)> which ghostview
> /usr/local/bin/ghostview
> --------
> 


