SabreTalk Migration
Semantic Designs can provide your organization with highly accurate automated conversion of legacy SabreTalk applications to C, C++ or other languages such as Java and C#. Our SabreTalk translator is built on top of Semantic Designs' advanced configurable compiler technology DMS®. With DMS, we are able to translate legacy programming technologies at a fraction of the cost and time of a manual rewrite.
Click to Request Translator Demonstration
SabreTalk Translation Highlights:
Flexibility
- Freedom to choose target technologies
- No third party dependencies
- Translate multiple & mixed languages
Code Quality
- Translations based on in-depth code analysis
- Smart heuristics for code refactoring
- Elimination of gotos
- Removal of dead and redundant code
Efficiency with 99+% Automation
- Shorter project timeframes lower costs & risk
- No code freeze until cut over
- Translate multiple & mixed languages
Converts SabreTalk-with-Prisym
- SabreTalk declarations/code converted to maintainable C/C++
- Folds multiple modules into single module
- Replaces macros with defined C/C++ equivalents
Experience
- Project team of PhD. Computer Scientists
- Proven track record
- Decades of investment in DMS
A key concern is, What will translated code look like? Weak translators convert code blindly line-by-line, with virtually no understanding of how the context of the code should shape its translation. Such translated code preserves the properties of the original SabreTalk, sometime the point of even preserving the syntax. Even if such code works, it not be maintainable and will ultimately cost the organization sorely.
Semantic Designs translators parse the original code with tools that have the same understanding as the original compilers.
A SabreTalk program translation
Here we show you a small sample of SabreTalk translated to C by SD's translation technology. Click here to see the the C code generated.
A simple SabreTalk program
We have chosen to provide a small SabreTalk program to prevent the reader from being overwhelmed by the complexities that occur in real examples.
OPTIONS=TRACE
FINDCUST: PROC;
/* TINY SABRETALK PROGRAM */
%INCLUDE EB0EB,SW00SR,INVDB,INVCES;
DCL FOUND BIT(32);
DCL CUSTNAME CHAR(64) BASED(CUSTPTR);
DCL BUFFER CHAR(100) BASED(BUFPTR);
DCL INVPTR BIT(32);
DCL DEADVAR BIT(32);
DCL SUB BIN(15) DEF EBW096;
/**************************/
START (CUSTPTR=#RG1);
INVDBPTR = INVDBCR2;
BSTR(BUFFER,1,1) = 0;
CSTR(BUFFER,2,99) = CSTR(BUFFER,1,99);
BSTR(EBSW01) = '00'X;
INVPTR = INVDBA90(SUB);
FNDEAD: FOUND=0;
IF INVPTR = 0
THEN GOTO FNDC45;
GOTO FNDOPEN;
FNDREAD: DBRED 'REF=INVCES','REG=R1',
KEY1=(PKY=#INVCESK),
UP,BEGIN,ERRORA=FNDC45
(#RG1=INVPTR,#RG3=SW0PTR,
SW0PTR=#RG3,INVPTR=#RG1);
IF SW00RTN > 0
THEN GOTO FNDC45;
CALL SETFOUND;
FNDC45: DBCLS 'REF=INVCES',RELFC
(SW0PTR=#RG3);
EXIT:
BACKC(#RG1=BUFPTR);
FNDOPEN: DBOPN 'REF=INVCES','REG=R1',
FADDR=?INVPTR,HOLD
(SW0PTR=#RG3);
GOTO FNDREAD;
SETFOUND: PROC;
FOUND = 1;
END SETFOUND;
DEADPROC: PROC;
FOUND = 0;
END DEADPROC;
END FINDCUST;
Each client has different goals and these can change the chosen target technology.
- Target language of C, C++, Java or C#.
- Mapping of Sabretalk concepts, including embedded assembler code, system macros, and TPFDF macros.
- Mapping of database queries to the client's database of choice.
- Staying on TPF or moving to a cloud-based solution.
One should note that the translator should chose fixed data types for variables compatible with their usage in the Sabretalk program or the database schema, but with a different or detailed representation better suited for for the target language.
Which combination of choices is made can determine very different style of translated code. The translator needs to be configured to account for the client's target technology choices.
SabreTalk program automatically translated to C
This output is reproduced exactly as SD's translator (configured for targetting the C code for running on a TPF system, and interacting with other existing program segments in HLASM and C) The translator produces nicely formatted target language code as a standard by-product.
Click here to see original SabreTalk program
/* OPTIONS=TRACE */
#include …/* TINY SABRETALK PROGRAM */
#include
Click here to see original SabreTalk program
One can get good code like the above, from a translator, if one has the right foundation technology such as SD's DMS Software Reengineering Tookit®. As a practical matter, you can't get good code from an off the shelf translator, because every application system has unique properties: languages, OS features, scripting languages, screens, databases, and a correspondingly unique set of target technologies as decided by the client. It takes some effort to configure DMS for the client's particular source and target software configurations. The effort is rewarded by the maintainability of the result.
Configuring a custom migration tool to match client needs
Semantic Designs can provide custom configuration of migration tools and migration support to your organization, providing high quality, maintainable code translations.