Window or Not ?
Vroom - Window Processing
QTIPS - Window Symbol Tables
VROOM - Window Processing II
@ATTACK - @HW
Uncommon Knowledge - WC_Reset%
Reader's Clinic - Related Windows
Window or Not?
Reader's Clinic - Scribe Replace Processes in Window
Soft Windows
QTIPS - Window Bug and Debugging Window Bug
Overlapping Windows And Window Menus
QTIPS - New Catalyst Option
QTIPS - Collectors on the fly
QTIPS - Blank Menus in Windows
QTIPS - Moving Objects the EASY way.
DOS Interfacing (Part II)
Reader's Clinic - Preventing Records Being Amended
How Indexes Are Updated
A RevTechie Replies - And Miscellaneous Jottings - Mike Pope - Revelation Technologies (UK) Ltd
Caching in on the Frames Array - Mike Pope
RTP Series - RTP9
RTP Series - RTP50
VERBatim - V25
@ATTACK - @Files
Utility Diskette # 3 - Part I
Playing with Scan Codes
QTIPS - Compiling Protection Code
QTIPS - Invalid Code and Command
QTIPS - Code/Command Help
Compiling 64K on a Shoestring by Blaise Wrenn (LexStat Systems Ltd)
@ATTACK - @Attrbt.Ptr
@ATTACK - @Query.Table
REVMEDIA Revisited
Uncommon Knowledge - WC_Table_Exit_Mode%
QTIPS - New Catalyst Option
Version 3 Technical Highlights - Deleting Tables Programmatically
Version 3 Technical Highlights - Aliasing Tables Programmatically
Version 3 TCL Subroutines - Creating Tables
Version 3 TCL Subroutines - Deleting Tables
Version 3 TCL Subroutines - Aliasing Tables
Symbol Table Structure
RTP Series - RTP27
QTIPS - Printing Large Variables from the Debugger
VERBatim - V87
VERBatim - V26
Viewer
VERBatim - V65
QTIPS - Using INIT.VIEW with Printers
REVMEDIA Revisited
QTIPS - Sub-Headings in RLIST (Revisited)
Reader's Clinic - Template Name at Pre-Init
Video Control
Reader's Forum
QTIPS - Command Line Options
QTIPS - Invalid Code and Command
QTIPS - Code/Command Help
Utility Diskette # 4
Viewer
QTIPS - Using INIT.VIEW with Printers
REVMEDIA Revisited
QTIPS - Sub-Headings in RLIST (Revisited)
Reader's Clinic - Functions and Subroutines
Argument passing - Subroutines and Functions - Mike Pope
QTIPS - Break-On Date Fields
IConvs / OConvs
QTIPS - Using @Upper.Case and @Lower.Case with Foreign Languages
@ATTACK - @Lower.Case
@ATTACK - @Upper.Case
Sorting out Collation Sequences by Mike Pope
Form.List.S
Make.Index
Index Sub Revisited
QTIPS - Make.Index 2.11+
QUERY.SUB
Version 3 Technical Highlights - Creating New Accounts Programmatically
Version 3 TCL Subroutines - Creating New Accounts
Version 3 TCL Subroutines - Creating Tables
VERBatim - V17
VERBatim - V6
VERBatim - V125
Utility Diskette # 3 - Part I
Version 3 Technical Highlights - Copying Rows Programmatically
Version 3 TCL Subroutines - Copying Rows
QTIPS - Form Processor
QTIPS - Reusing Symbolics in Windows
Soft Windows
QTIPS - Query Windows - Changing Colours
Reader's Clinic - Template Name at Pre-Init
Caching in on the Frames Array - Mike Pope
Advanced Revelation Assembler Interface Module - Yves Pattyn, Technical Manager, Distribase, France
File Variables
LINEAR HASH FILE STRUCTURES - Part 1
QTIPS - File Handle Structure
@ATTACK - @Record
@ATTACK - @Reduction.Done
Collector Windows
Soft Windows
Reader's Clinic - Template Name at Pre-Init
Vroom
RTP Series - RTP32
Utility Diskette # 3 - Part I
REVMEDIA Revisted
Version 2
RTP Series - RTP19
VERBatim - V22
Reader's Clinic - Scaled Masked Decimal Conversions
VROOM - Window Processing II
Base Conversions
IConvs / OConvs
User Defined Conversions
QTIPS - Skipping Prompts
Bugs and PCs - Xlate with Multipart Keys
VROOM - Window Processing II
Indexing on Xlates
Collector Windows
QTIPS - Reusing Symbolics in Windows
QTIPS - Hiding Symbolic Source Code
RTP Series - RTP42
RTP Series - RTP51
Reader's Clinic - AREV Runtime
@ATTACK - @PDisk.On
Advanced Revelation Initialisation Sequence (Overview) by Mike Pope
AREV Comes to Czechoslovakia Les Palenik, Cosmotron Systems
@ATTACK - @Reduction.Done
Prompt Help
VERBatim - V6
QTIPS - BASIC Options
The End of the Line - Mike Pope and Hal Wyman
Collector Windows
QTIPS - Reusing Symbolics in Windows
SecureUser
VERBatim - V86
Advanced Revelation Initialisation Sequence (Overview) by Mike Pope

RevMedia FKB

DocumentV2I3A4
TitleVROOM - Window Processing II
KeywordsWINDOW
PROCESSING
OCONV
SYMBOLIC
RLIST
VROOM
TextThe last issue dealt WITH the way in which window FLOW can impair
performance specifically in relation to OCONVs and symbolics EXAMPLE code
to deal WITH this problem by REMOVING the OCONVs and symbolics at pre save
and restoring them pre read is presented below Note that the best
performance improvements will be seen where the OCONVs and symbolics make
reference to other files eg code table lookups To use the program enter
compile and catalog it and then put commuter CALLS to it on the PRE INIT
PRE READ and PRE SAVE hooks (EG Pre Save Code = S Pre Save Command =
STRIPPER PRE SAVE The code listing that follows is longer than our
preferred length but this in view of the numerous comments contained therein
it is felt to be acceptable

SUBROUTINE STRIPPER(BRANCH)
*
* Author AMcA WITH acknowledgements to Stefan Gilboy of ICS (Sales) for
* the original idea
* Date April 1990
*
BEGIN CASE
CASE BRANCH = "PRE INIT" ; GOSUB PRE INIT
CASE BRANCH = "PRE READ" ; GOSUB PRE READ
CASE BRANCH = "PRE SAVE" ; GOSUB PRE SAVE
END CASE
RETURN

PRE INIT:
*
* It is necessary to make a copy of all of the symbolics and OCONVs so
* that they can be restored later when they have been removed Anywhere
* can be used this EXAMPLE uses REGISTER(2) Note that as this logic
* takes place at PRE INIT the template structure is still in @RECORD so
* this is manipulated
*
CTR = @RECORD<1> + 1
NEW_REG = ""
FOR X = 2 TO CTR
*
* Note that we store the field name and OCONV for EVERY prompt
* regardless of the relevance of same It is a moot point whether the
* extra checks required to implement the extra logic might slow the
* program down sufficiently to nullify the benefits accrued therefrom
*
NEW_REG = @RECORD : @VM : @RECORD
*
* Don't null down key prompts as this seems to cause PROBLEMS under
* some circumstances For all other fields though remove the field
* name if symbolic to prevent recalculation and the OCONV
*
IF X > 2 THEN
IF @RECORD = "S" THEN @RECORD = ""
@RECORD = ""
END
NEXT
*
* Now store NEW_REG in REGISTER(2)
*
@RECORD = FIELDSTORE(@RECORD "÷" 37 1 NEW_REG)
RETURN

AREV COMMON:
*
* Note cannot be done at top of program as it is not loaded until
* AFTER PRE INIT
*
$INSERT AREV COMMON
RETURN

PRE READ:
GOSUB AREV COMMON
*
* If @ID is null then this is the "Dummy" pre read highlighted in the
* last issue Under these circumstances it makes no sense to reload the
* missing information
*
IF @ID # "" THEN
FOR X = 1 TO W CNT
W(X)<2> = REGISTER(2)
W(X)<13> = REGISTER(2)
NEXT
END
RETURN

PRE SAVE:
GOSUB AREV COMMON
*
* Remove information
*
FOR X = 1 TO W CNT
IF W(X)<3> = "S" THEN W(X)<2> = ""
W(X)<13> = ""
NEXT
RETURN


Improving OCONV Performance
As evidenced in the last issue OCONVs are called an inordinate amount of
times in entry windows If user DEFINED OCONVs which produce DISK i/o are
being used then PERFORMANCE will degrade dramatically It is therefore only
practical to examine ways of decreasing this overhead

One simple but effective improvement that can easily be made is to examine
the VALUE that the program is being asked to OCONV and then compare it with
the value last OCONVed If the two values are the same then there is no
point in recalculating the value simply use the result produced last TIME
The decision of where to store this information is a purely personal one but
the higher fields in @RECORD are convenient if you remember to null them
down on a Pre Save

The following logic serves to illustrate this It assumes the basic
structure of the user DEFINED CONVERSION has been DEFINED and the DATA to
convert is in PASSED_DATA whilst the data to return is in RETURNED_DATA

* Normal OCONV code precedes
IF PASSED_DATA = @RECORD<100 1> THEN
RETURNED_DATA = @RECORD<100 2>
END ELSE
@RECORD<100 1> = PASSED_DATA
GOSUB CALCULATE_CONV
@RECORD<100 2> = RETURNED_DATA
END

Note that in the EXAMPLE given above the passed data is stored in value one
of the field and the OCONVed result is stored in field 2 This will
obviously not work if the field being OCONVed is MVed

Improving SYMBOLIC PERFORMANCE RLIST
It is frequently the case that symbolics make reference to other symbolics
As these need to be recalculated every time they are referenced this can
reduce list PERFORMANCE Extrapolating upon the technique used above we
could modify our symbolics so that those symbolics that others used could
place their result both in @ANS and @RECORD The other symbolics could
reference this field and if null calculate the appropriate value and insert
it This means that in any list STATEMENT the same symbolic would only ever
be calculated once regardless of how many times it was referenced This sort
of approach is simple to implement the only problem is remembering to
modify new symbolics in LINE WITH pre existing ones

The PERFORMANCE improvements gained can be significant in one disk
intensive operation at a client recently list SPEED was improved by an
order of magnitude by applying this technique The following code
illustrates the technique USING two DICTIONARY items HOURS_TO_DATE and
AMOUNT_TO_DATE (assume CALCULATE_HTD and CALCULATE_ATD exist and return the
relevant information)

* Hours to date stored temporarily in @RECORD<100>
IF @RECORD<100> THEN
@ANS = @RECORD<100>
END ELSE
GOSUB CALCULATE_HTD
@ANS = HTD
@RECORD<100> = HTD
END

* Amount to date stored temporarily in @RECORD<101>
IF @RECORD<101> THEN
@ANS = @RECORD<101>
END ELSE
IF @RECORD<100> THEN
HTD = @RECORD<100>
END ELSE
HTD = {HOURS_TO_DATE}
@RECORD<100> = HTD
END
GOSUB
CALCULATE_ATD
@ANS = ATD
@RECORD<101> = ATD
END


(Volume 2 Issue 3 Pages 4 6)
[revmedia/copyrigh.htm]

Page last modified: 30/01/03