REVIEWS COURTESY OF ZXSR

Laser Genius
by Oasis Software
Ocean Software Ltd
1986
Crash Issue 30, Jul 1986   page(s) 94,96,97

(Simon N Goodwin owns the copyright to this review. Please visit http://simon.mooli.org.uk to find original articles and updates, much new material and his contact details.)

LASERS ON STUN

Laser Genius is a Machine Code assembler and monitor. In other words, it's a utility package that helps you to write and test Machine Code programs. But don't fall asleep - this package is unlike anything else we've seen on the Spectrum, and it could have a major impact on Z80 assembler programming.

Since 1982 Spectrum programmers have been presented with a flood of assembler and monitor programs. The early utilities were so limited that it became de rigeur, for a while, to write your own assembler almost as soon as you'd learnt Machine Code!

Despite all of this effort, the products were much of a muchness, and differed mainly in presentation rather than content. Among the best of an indifferent bunch were HISOFT'S ugly but workmanlike DevPac, and PICTURESQUE'S Machine Code System. HISOFT scored on features and PICTURESQUE on presentation. Both systems are commonly used by Spectrum software houses; but all that could change with the arrival of Laser Genius.

The package is split into two parts - an assembler and a monitor. The first lets you enter programs and translate them into Machine Code. The second helps you to test your programs, find bugs and correct them.

For £14.95 you get two cassettes and a 150 page A5 manual, in the inevitable video box. The box looks identical to that of Laser Basic, so you'll have to look closely to find this one in the shops. Genius (originally called Magus in Sinclair advertising) runs on all model of the Spectrum, except for the old 16K model; a special 128K version is promised but has yet to arrive.

TAPE CATALOGUE

The two parts of the package are recorded on different tapes. One both my copies, Tape 1 contained the files intended for Tape 2, and vice versa! OASIS have promised to sort this out.

The first tape holds the assembler, some utilities, and a set of example programs written in assembly language and Phoenix - a new low-level language.

The second tape contains two versions of the monitor, to load into either the top or the bottom of memory on a 48K machine. A relocator is also provided for awkward people who'd like to put the monitor somewhere inbetween.

THE ASSEMBLER

The Laser Genius assembler lets you type in programs and store them on tape or Microdrive. It uses a neat 42 column display, which is handled a little more slowly than the usual 32 columns but still acceptably fast. QL and Enterprise fans will be pleased to discover that labels can be up to 240 characters long, but unchuffed to learn that they can't use underscore characters between words.

There's a full screen editor, and you can even scroll back over past entries. All of the usual commands are there - search, replace, copy, move, renumber, delete, list and print. You must divide your code into numbered paragraphs, each of which can be up to 1K long.

The assembler is very large - maybe too large to suit cassette users - and you're limited to about 16K of text unless you start to shed features. In practice this is not too much hassle as assembly code is stored in a concise, tokenised form. You can get as much in memory with this package as with its competitors, as long as you don't include lots of comments.

Once the buffer is full you can use a INCLUDE command to fetch instructions from a tape or Microdrive file. This has two limitations - 'INCLUDEs cannot be tested (so one file can't INCLUDE another) and the amount of tape fiddling needed is horrendous if you want to assemble to and from cassette. Text is loaded in 2K chunks and you have to swap and stop tapes throughout the assembly process. This is fairly automatic - although slow - when using Microdrives.

The assembler has all the bells and whistles you might expect; it allows macros with parameters and local labels, arbitrary arithmetic and conditional assembly. There's also a library manager built in, which can be persuaded to automatically include pre-written subroutines as required. You can print or interrogate the symbol table to find out what goes where. There's also a neat integer calculator, with support for most number-bases.

Machine Code can be sent to a file or to memory; the format of code files is non-standard, but OASIS supply a conversion utility and you can always drop out to 2X BASIC and save code from there if you wish. You can tell the assembler to generate code for a given address but store it somewhere else - this is vital, given the size of the assembler. Sadly, there's no option to produce self-relocating code.

The assembler error messages are adequate but not outstanding - it's annoying that mismatched ENDs and missing parameters stop the assembly at once, without any check for further errors.

PHOENIX

The icing on the cake is Phoenix, a low-level language which can be mixed into assembly-language programs. Phoenix is a simple language, with support for integer variables, one dimensional arrays, loops, tests, pointers and expressions.

Laser Genius translates Phoenix instructions into a mixture of inline code and subroutine calls. The LIB command adds the required subroutines to your code file. The results should run about as fast as code from a simple Forth or Integer BASIC compiler.

Phoenix looks pretty nasty - like a cryptic cross between Tiny C and Pidgin Fortran - but it's certainly useful if your programs contain lots of non-time-critical arithmetic and data-structure access.

CONVERSION PROBLEMS

If Laser Genius is going to succeed it is going to have to convert users from other assemblers. The LOAD ASCII command is meant to load assembler files from other packages, but it stubbornly refused to work on my Spectrum. I spent several hours trying to load cassette files from DevPac and PICTURESQUE's assembler, and got nowhere.

The instructions didn't seem to make sense and I got some weird results, including an endless stream of blank lines (even after I stopped the tape) and a mysterious 'expression too complex' error where no expression had occurred. OASIS insist that they've tested this facility - I say don't rely on it.

THE ANALYSER

The Laser Genius Monitor is quite amazing. The best feature is called the 'analyser' - a program that interprets your Machine Code in slow motion, checking its behaviour as it runs. It's a sort of glass computer - you can watch the current instruction, register values and memory contents change, and pause the program at any point.

Conditions - expressed in Machine Code or a version of Forth - can be set, so that the computer automatically stops whenever a certain address or area of memory is read or written. If you know that your program is overwriting something it shouldn't, the analyser will find the cause.

Virtual screens are allowed, so the analyser display doesn't have to mess up your graphics - the computer will swap the entire screen contents, or any window, depending upon what's running.

STACK CHECKER

There are some neat examples in the manual, including a fiendish routine called the 'stack checker' which monitors CALL and RET instructions, stopping if you ever try to RETURN from a subroutine without a sensible return address, generated by a CALL, on the stack. You can have up to ten conditional tests working at a time. Register values, flags, opcodes, addresses or whatever are checked after every instruction, so the code runs slowly, but this is a small price to pay for a crash-proof program.

You can write checks to ensure that code is not over-written, and you can use a back trace to find out how a program reached a given point. Conditions are easy to enter and easy to edit. They can only be one line long, but may contain calls to other routines in Forth or Machine Code.

THROUGH THE SQUARE WINDOWS

The monitor display is normally divided into four areas: a register list, memory display, output or disassembly window and an area for commands. As in the assembler, each line may hold up to 42 characters. Some instructions use the whole screen and re-draw the four areas when you enter a new command.

The monitor occupies about 15K of memory, so you can't use it at the same time as the assembler. It supports all the features you'd expect, with the exception of symbolic debugging - you can't use labels and data names from your assembler program when testing. This is a missed opportunity.

However, the built-in disassembler will produce files containing made-up labels that can be loaded into the assembler. This is very useful if you lose your source file or want to steal someone else's code! You can also tell the disassembler about data areas, so that it doesn't by to interpret them as code.

You can stuff bytes into memory, copy blocks, assign registers by name, search for strings, fill areas and compare blocks. You can swap register-sets, or ROMs, and turn interrupts on and off. Values can be stacked or unstacked, and there's a Forth-style backwards calculator in which you put numbers before operations, so that (EVAL 2 2 3 + * will display 10 (2 plus 3, times 2 - geddit?) ). You can choose your favourite base for arithmetic.

There are 8 normal breakpoints available, as well as the ten STOP points. Code runs at full speed between breakpoints. You can step through programs one instruction at a time, with an option to interpret ROM calls or execute them without stopping.

Programs don't have to stop when they reach a breakpoint. You can make them stop after a certain number of loops, or switch into slow (analysed) execution at a given point. You can have the register or memory display, or both, updated between certain instructions, so that you only have to pay attention while critical code is being executed.

With the whole display re-drawn after every instruction, and a single slow breakpoint, you can analyse one instruction per second. If you just update the register display this rises to three instructions per second - a comfortable speed for humans. The analyser can get through about 200 instructions per second if you don't bother to have the screen updated.

FLAWED GENIUS

The manual is the worst part of the package. OASIS have never been very good at documentation, as they admitted when I visited them a couple of months ago. Their latest attempt is better organised than that provided with Laser Basic, but it's still an amateurish effort - chaotic, verbose, and dull to read.

The print is black on dull blue paper; this is meant to discourage photocopying without making the text unreadable, and it's certainly an improvement upon the trendy bright green of previous offerings. There's a fairly comprehensive index at the back of the book - hooray! There's also an enquiry card, which you can send off to OASIS if you need more help. You must use the card, to prove that you've got a kosher copy of the package; a replacement is sent with the reply.

The first really annoying thing is the fact that Amstrad, 48K and 128K Spectrum users all get the same manual. Throughout the text there are notices saying 'Amstrad Tape Users'and 'Spectrum Microdrive only'. The information is muddled together, often in the same paragraph, and sometimes there are references to Amstrad options with no mention of the Spectrum equivalent.

The comparative programming examples are only listed in Amstrad BASIC, with a glib notice to say that they can 'easily' be converted to run on the Spectrum. There's no explanation of the workings of WHILE..WEND, nested IF..THEN..ELSE, and the Amstrad PLOT command, so Spectrum users who are unfamiliar with other versions of BASIC are going to have problems. This is just lazy, especially as there's blank space to be taken up at the back of the book.

The manual can't make its mind up whether to be a tutorial or a reference guide. There are some diagrams and lots of useful examples, printed in a contrasting typeface, but the core of the book is simply a list of the commands and facilities available. This is too much information for anyone to take in as a constant stream.

At the end of each half of the book there's a collection of appendices listing keys, commands and error-messages.

There are some silly typos, like repeated references to a need for 10241K of memory! Some commands are referred to long before they're explained, and the order in which topics are discussed leads to problems: for instance, there' s a table of 20 arithmetic operators in the section explaining how the editor works. One of the editing keys is wrongly documented and another (TAB, Shift 9) isn't listed at all.

Most of the information you need is in the manual, although there's an annoying lack of information about compatibility with add-ons such as disk drives and printer interfaces. The package works well with Microdrives and adequately with tapes; the assembler loading program will make a Microdrive copy for you, but you have to make up your own loader for the monitor, using addresses in the manual. There's no support for disks at present - an awful mistake, in my view. OASIS say that they've had lots of enquiries and may produce an OPUS disk version.

It seems that the package is compatible with the ZX printer (just) or any other printer connected to ZX BASIC stream 3. The manual only mentions the KEMPSTON interface, but I got a ZX LPRINT working without any problems. I'm told that the Interface 1 serial port will also work if you open it from BASIC before loading Laser Genius.

GENERAL CONCLUSION

This is a complicated package, and the documentation makes it seem more so. In its present state, Laser Genius is not suited to the beginner but the experienced Machine Coder should be able to work it all out after a few days of frustration.

Laser Genius deserves to be a real success, but it is let down by three things: the manual, the apparent lack of compatibility with other packages, and the lack of support for disk users. We'll keep you posted if OASIS manage to sort out any of these problems.

In technical terms Laser Genius is streets ahead of the competition, and should make it possible to write programs on the Spectrum which - previously - would have simply been impossible to test and finish property. If you can already program the Spectrum in machine code, and you've got a Microdrive, I'd recommend this package. At £14.95 it is good value for the monitor alone.


REVIEW BY: Simon N Goodwin

Transcript by Chris Bourne

Sinclair User Issue 52, Jul 1986   page(s) 69

Label: Ocean IQ
Author: Oasis
Price: £14.95
Memory: 48/128K
Reviewer: Tony Kendle

Laser Genius is arguably the most powerful utility yet produced by the Ocean/Oasis partnership, one which will appeal to professionals as much as aspiring amateurs. It's a complete assembler/dissassembler/monitor/debugger machine-code programming suite.

Most assembler/monitors follow tired, predictable formats, unchanged since the dawn of the Z80. The only selling points are how many lines of code can be assembled in so many passes and in how many seconds.

Such things may be important to the most jaded and crusty programmer but for most people compilation time is a minute fraction of the effort put into sweating over writing the code and, worse, then debugging it.

Laser Genius is easily powerful enough to compete by existing standards but also represents a fundamental rethink about which features make an assembler/monitor useful to most people.

The editor is flexible and simple to use. It behaves as a screen editor in that you can scroll the program and make changes anywhere on screen but the source code is also divided into separate numbered 'paragraphs'. These give you some of the advantages of a line editor as well, eg jump to Line 20, delete Lines 40 to 57 As you type in each Z80 instruction it is syntax checked before being added.

Source code can be loaded in from other assemblers, eg Devpac but then it is tokenised making it more compact and faster to compile.

Although it can be fiddly with cassettes it is possible to assemble very long files saved on tape and link several together using the *Include command.

There is also a process by which you can automatically include some routines from a large library in your current program. To complement this the graphics source code used in Laser Basic will be made available later in the year.

Traditional assembler features such as macros and conditional assembly are supported but there is also a small, high-level logic compiling language, Phoenix, which can be freely mixed with the normal Z80 code.

Phoenix provides you with Repeat... Until and While loops, If... Then and End...If conditional tests, extended function definitions, variables and arrays and more. Such concepts are typically complex, or at least tedious, to simulate in machine code.

The monitor/disassmebler is typically the weakest part of most commercial packages but the Oasis version has many good points. The screen display is windowed to show a memory dump, the register and stack display and the disassembly. A virtual screen can be defined so that you can switch instantly between the monitor panel and a screen showing the effects of your graphics program.

The various Roms which may be present (48K, 128K, Interface One) may be switched in or out and disassembled.

Code can be disassembled to tape, with labels inserted instead of absolute addresses so that it is ready for re-assembly after modification.

As well as normal running speeds code can be single-stepped or 'slow run' with varying degrees of screen display up-date. Break-points can be set to stop the code or to trigger one of the slow modes.

Most impressive of all is an 'analyser', based on a small and simple Forth-like language. Using this you can effectively 'program' the monitor to behave as you wish. For example, every time register HL is loaded with address x you can program it to display the virtual screen. The most obvious application is for intelligent debugging. You can cause a break to occur in response to the most precise and complicated combination of events - something that ordinary break-points just cannot handle. Invaluable stuff.

Microdrives are supported throughout and there are special options for 128K machines, eg Ram page selection.


REVIEW BY: Tony Kendle

Overall5/5
Summary: Very powerful machine-code tool. Accessible to a beginner, sophisticated enough for a professional.

Award: Sinclair User Classic

Transcript by Chris Bourne

Your Computer Issue 10, Oct 1986   page(s) 37

SUPER SOFTWARE

Ian Duerden looks at the latest package from the Ocean/Oasis label.

Following the launch of Laser Basic Laser Compiler, Laser Genius is the third in the series of utility packages from OccanIQ/Oasis. Laser Genius is a full package for machine code development and includes an Editor, Assembler, Monitor and a new concept in programs of this type, an Analyser.

The package arrives in the Ocean standard big box containing cassettes or disc and a fairly comprehensive 150-page manual. Many of the commands and facilities are standard and can be found on most other Assembler/Disassembler packages but it is all the extra commands and services not found on other utilities which make Laser Genius an out-and-out winner.

A Basic loader provides the option of changing colours or altering line feed characters before loading the three programs comprising the Assembly part of the package - the assembler, the toolkit and the hash (#) extension. The toolkit contains most of the commands needed to use the assembler: the hash extension contains a number of pseudo-operations, with the character printed in front, their purpose being to provide an integer-based compiled language called Phoenix.

Using this language it is possible to produce programs to test ideas or algorithms before compiling them to machine code without losing speed or program size. Phoenix can be mixed with machine code or used as a stand-alone program, so if you have difficulty using or learning assembly code it is possible to write your programs using it.

Because Phoenix is a fully-structured language it is relatively complex and will take a fair amount of time to learn. The commands available are numerous but well-documented and the manual contains a number of examples written in Basic, machine code and Phoenix for you to study and use.

The Editor contained in the Assembler is a hybrid of the best of the editors on the market, mixing line and screen editing functions in one program.

Each source code must have a line number - not unusual - but where Laser Genius again differs is that it checks the syntax of each line as it is entered, making for extremely fast assembling of source code. The line numbers are arbitrary as you can input source code in paragraphs, enabling you to structure your programs much more easily. Where errors occur a message will appear on the screen explaining the type of error; you can then use the cursor keys to make corrections.

It is possible to assemble code in a variety of ways - stand-alone, linked with a previously-assembled program, or to assemble selected subroutines from a library: each can be displayed on the screen or dumped to a printer, or both, but you do lose assembler speed with those two options.

First impressions of the Monitor are similar to those of the Assembler. It is typical of others already on the market and anyone who has stayed up half the night single-stepping through a program in an attempt to find a bug will know what I mean but again Ocean have a new idea, an Analyser.

It allows up to 10 selective 'stop' conditions to be defined. With the stop condition set you can run your programs normally: the analyser then traces each step of the program automatically. If you wish to find a particular value for a particular register before it writes to the screen the analyser will trace the program to that point and then list all the values on to the screen for you to examine. That can save hours or even days in tracking elusive bugs which tend to perpetrate many machine code programs.

The Analyser uses a dialect of Forth as the controlling language. First, it executes much faster than Basic and, second, it is compact and relatively easy to learn. Anyone with some knowledge of Forth should be able to find their way around reasonably quickly: others who have not used the language will be able to glean sufficient information from the manual to be able to master the analyser in a short time.

The manual contains a fair amount of information. It is not perfect by any means but explains the workings of both programs reasonably well. If there is a criticism it is that the section on Phoenix could have been more explicit. Apart from that it allows you to experiment as you proceed.

The package is suitable for the inexperienced user, who will not need to upgrade to something better, and the experienced programmer who needs more than most other packages can offer.

Laser Genius must be the best value package on the market in terms of price and what it has to offer. Where else could you find such a time-saving, debugging tool plus a new language and compiler all in one Assembler/Disassembler package?


REVIEW BY: Ian Duerden

Transcript by Chris Bourne

ZX Computing Issue 27, Jul 1986   page(s) 24

CAROL BROOKSBANK LOOKS AT THE LATEST TO OCEAN'S IQ RANGE OF UTILITIES.

Ocean IQ
£14.95

This addition to Ocean's IQ series is an Editor/Assembler and Monitor/Analyser. Despite the slightly alarming handbook, (a quarter-inch thick) the program is very easy to use - flexible and user-friendly. Wherever possible the user is given choices. For instance, the assembler accepts decimal, hex, binary or octal input. Each instruction can have a line number or you can assign one number to groups of instructions. Disassembly can be in decimal or hex. Labels can be any length you like up to 240 characters, and you probably know how impossible it becomes to use labels that convey anything at all after a while if the assembler limits you to six characters. Attention to this sort of detail makes the user feel very comfortable with this program.

EDITOR/ASSEMBLER

There are two tapes. The first, the Editor/Assembler, has all the features you would expect and numerous extra ones. Macro labelling allows procedure definition in the listing. A special set of commands constitute a high level language - Phoenix - which is really intended for testing algorithms, but they can be mixed freely with assembly language, so there is no need to convert a tested routine. A calculator, accessible from the editor, accepts input in all four arithmetic conventions, and will output in whichever base is specified, and in unsigned or two's complement arithmetic.

The editor takes care of tabulation, and you can mix upper and lower case freely. Opcodes are converted to upper case, but labels and notes remain as you entered them. LOOP, Loop, and loop being recognized as different labels. Error messages are very specific; for example "Space required" above the line you are trying to enter, and a cursor at the spot where the space is needed. String search, find and replace are available, and sections of the listing can be copied, moved or deleted.

The label table can be saved separately and merged into later modules of a long program, avoiding the need to assemble existing modules just to get the labels into memory. You can discard any which are only used inside a subroutine and just carry forward the entry point labels.

Assembly is to screen, tape, microdrive, disk or printer. Conditional assembly is available, so that if your program needed, say, to drive a printer interface, you could write subroutines to drive different ones, set the conditional facility to assemble just one and ignore the others, and produce several versions of the program from one listing. The code produced by the assembler is in a special form, so there is a conversion program to translate it to normal code. Either form of code, or the source text, can be saved to tape, microdrive or disk.

MONITOR/ANALYSER

The MonitorfAnalyser on the second tape is just as powerful. Versions residing high or low in memory are offered, and either can be relocated so that there is no clash between the monitor and the program being examined. The monitors main screen is divided into tour windows: top left - disassembly listings or the memory map; top right - the current state of flags, interrupts, and registers and the top nine items on the stack; centre screen - the contents of the address in the memory pointer and program counter, and the contents, in hex and ASCII, of 64 addresses, with the one in the memory pointer near the middle with a cursor; bottom screen - commands and messages.

Disassembly, which can also be to the whole screen, can be saved with absolute addresses for calls and Jumps, or with labels generated allowing the code to be relocated.

The debugging and testing facilities are excellent. You can single step through the code, with the register and stack display updated after ever step. Instructions may be skipped and subroutines called may run at normal speed or single step. Slow running is available, with subroutines at normal or slow speed, with four types of information update. Eighteen types of breakpoint are offered, ranging from the ordinary one returning control to the monitor, to ones which continue in slow mode or resume normal speed execution.

GENIUS

This is a very versatile test and debugging program and the whole package is most impressive. The one area where I feel improvements could be made is printer interfacing, because Kempston 'E' is the only one guaranteed to work with it.

It seems a pity that such a versatile program in every other direction should not support a wide range of interfaces.

This apart, Laser Genius is a first-class package, straightforward enough for the beginner and versatile enough for the expert. The price amazes me. The program I have been using until now cost me over £22 and has half the facilities this one offers for £14.95. Clearly, excellence is the hallmark of the IQ series.


REVIEW BY: Carol Brooksbank

Transcript by Chris Bourne

All information in this page is provided by ZXSR instead of ZXDB