<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic [ Example 8 ] in Software Archive</title>
    <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950573#M19448</link>
    <description>&lt;STRONG&gt;[ Example 8 ]&lt;/STRONG&gt;

Here is a &lt;STRONG&gt;Configuration Params Problem&lt;/STRONG&gt; and a simple solution looks like:
...
	g_iParam1 = atoi( getenv( "PARAM_1" ) );
	g_iParam2 = atoi( getenv( "PARAM_2" ) );
	g_iParam3 = atoi( getenv( "PARAM_3" ) );
...
Of course, number of parameters defined as Environment Variables needs to be limited but this is a one-line solution compared to multi-line implemntation of different ini-file, cfg-file, or xml-file readers, etc.</description>
    <pubDate>Fri, 22 Nov 2013 23:48:07 GMT</pubDate>
    <dc:creator>SergeyKostrov</dc:creator>
    <dc:date>2013-11-22T23:48:07Z</dc:date>
    <item>
      <title>A Success Story of some software integration: Turbo Disaster, or When failure was Not an option...</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950555#M19430</link>
      <description>Hello everybody,

My name is Sergey Kostrov. I'm an Intel Black Belt Software Developer and am Not an Intel employee. I'd like to share my experience ( a Success Story ) on how some very complex software integration was done a couple of years ago on the &lt;STRONG&gt;ScaLib&lt;/STRONG&gt; project.

So, It is possible that you've heard a very famous expression &lt;STRONG&gt;Failure is Not an option&lt;/STRONG&gt;. Even if the expression was never told by real Mission Control personnel during &lt;STRONG&gt;Apollo 13&lt;/STRONG&gt; mission it is related to those dramatic events. Project managers, flight engineers and controllers &lt;STRONG&gt;never gave up&lt;/STRONG&gt; when trying to find solutions of different problems with the spacecraft.

In October 2010 I had to deal with a very complex software integration. Shortly speaking, a fate of the project was on my shoulders and &lt;STRONG&gt;Failure was Not an option&lt;/STRONG&gt; for me.

In modern &lt;STRONG&gt;Information Technology&lt;/STRONG&gt; industry software systems are very complex and even a little problem could create lots of troubles for a software developer or a team of developers. There is another famous expression and you've also heard it:

&lt;STRONG&gt;Google It!&lt;/STRONG&gt;

What does it actually mean? It means, that a software developer thinks that a problem he/she actually deals with is not a unique one and there is already a solution. That is possible! However, for me it means that the developer is not doing the job in a right way and doesn't try to work hard to find a solution by himself/herself. I'm not going to convince anybody that in order to become a real &lt;STRONG&gt;S&lt;/STRONG&gt;oftware &lt;STRONG&gt;D&lt;/STRONG&gt;eveloper ( can you see that I stressed with capital &lt;STRONG&gt;S&lt;/STRONG&gt; and capital &lt;STRONG&gt;D&lt;/STRONG&gt;? ) an attitude of a &lt;STRONG&gt;Strong Problem Solver&lt;/STRONG&gt; needs to be grown up.

Here is some set of quotes from a &lt;STRONG&gt;Technical Report&lt;/STRONG&gt; I've created in 2010 related to how I solved lots of technical problems, actually overwhelming for just one C++ developer responsible for the integration of a legacy C++ compiler with the &lt;STRONG&gt;ScaLib&lt;/STRONG&gt; project and &lt;STRONG&gt;4 weeks&lt;/STRONG&gt; time frame, &lt;STRONG&gt;without&lt;/STRONG&gt; asking for help from anybody else due to project constraints:

...
&lt;STRONG&gt;DevNote #0026&lt;/STRONG&gt;:
Detected problems and issues over the course of integration &lt;STRONG&gt;Turbo C++ compiler v3.00&lt;/STRONG&gt; with
the &lt;STRONG&gt;ScaLib&lt;/STRONG&gt; project

This is an outlook on what happened with the &lt;STRONG&gt;ScaLib&lt;/STRONG&gt; Project over the course of integration Borland's International Turbo C++ compiler v3.00 in October 2010.

At the end of 2009 a GNU compiler MinGW v3.4.2 was integrated into the Visual Studio 2005 development environment and it significantly helped to clean the C++ codes of the ScaLib library. In the 2nd part of 2010 year a state of the project was considered as a very stable with a very good portability between different Platforms.

A compilation process looked like this:

Every time when the Build was started it has to be done for at least three Platforms, one by one, using two different compilers:

- First step, Visual Studio 2005 compiler ( for Desktop )
- Second step, Visual Studio 2005 compiler ( for Embedded )
- Third step, MinGW v3.4.2 compiler ( for Desktop )

But, I was feeling that two compilers are not enough in order to prove that a quality of portable C++ codes is high. Unfortunately, both compilers, that is, Visual C++ and MinGW v3.4.2, are targeted for Windows Operating Systems.

I suggected to integrate another C++ compiler that doesn't have any Microsoft's or Windows header files. The best candidate for that portability verification task was a compiler from Borland International for an MS-DOS Operating System and I decided to try Turbo C++ version 1.01.

An attempt with Borland International Turbo C++ v1.01 stoped almost instantly. It was unsuccessful because version 1.01 doesn't support C++ templates!

But, I was able to compile many pieces of generic C++ codes in the ScaLib library and it was clear that I'm working in a right direction. So, it was just a matter of time and when Borland International Turbo C++ compiler v3.00 was found on one of my archive CD I decided to start a second attempt.

The key features of the compiler included support of C++ standard 2.1 and version 3.0 templates.

In the morning on &lt;STRONG&gt;October 11th, 2010&lt;/STRONG&gt; I've finally started the integration of Turbo C++ compiler v3.00 and half an hour later the situation could be described with just two words:

&lt;STRONG&gt;TURBO DISASTER!&lt;/STRONG&gt;

I've stepped back in time for almost &lt;STRONG&gt;20 years&lt;/STRONG&gt; and the number of issues and problems was OVERWHELMING. I was simply forced to make records on a clean piece of paper and it was filled on both sides completely in about one hour.

Here is an &lt;STRONG&gt;initial&lt;/STRONG&gt; list of problems detected during first day of integration:

- A project configuration problems for a new MS-DOS based Platform

- A problem with long file names because in MS-DOS only 8.3 file names are supported ( 12 characters in total )

- There is no support of '_stdcall' key word

- There are no 'BOOL' or 'bool' data types

- There is no '_complex' data type

- An issue with a native data type 'int' because by default it is a 16-bit based

- An issue with a native data type 'long double'

- Usage of MAX_PATH macro constant ( Non-Portability Leak )

- Usage of MB_OK macro constant which is used in famous MessageBox function of Win32 API ( Non-Portability Leak )

- Incompatibility of #pragma directives between Visual C+, MinGW and Turbo C++ compilers

- A problem with forward declarations of template functions

- A problem with declaration constructors of a template class as 'inline'

- A problem with declaration of a parameter based on 'typedef enum' type in a constructor of a template class

- A problem with a data type declared as 'typedef enum' because by default it is a 16-bit based

- A problem with default value declaration for a parameter, like ...param = T()..., in a method of a template class

- A problem with global C++ operators 'new' and 'delete'

- A problem with declaration of global C++ operators 'new' and 'delete' inside a '__cplusplus' block:

	#ifdef __cplusplus
	extern "C" {
	#endif
	...
	...
	#ifdef __cplusplus
	};
	#endif

- A problem with ';' at the end of a macro with '()'

- An issue with 'strncpy' CRT-function

- A problem with 'reinterpret_cast', 'dynamic_cast' and 'static_cast' C++ operators ( key-words ) which are not supported by Turbo C++ compiler v3.00

- A problem related to data types alignment because it is supported on a global scale by Turbo C++ compiler v3.00 as a command line option and as a #pragma option directive

- A problem with Turbo C++ compiler v3.00 when compiling sources in RELEASE configuration when a big array of data is created locally, that is on the stack

- Turbo C++ compiler v3.00 creates binaries for a Real-Mode Operating System, that is MS-DOS, and there is no direct support for a Protected-Mode or Flat Memory model

- Turbo C++ compiler v3.00 ( command line version ) couldn't find Turbo Link executable if the installation was done in a different from '..\TC30' folder Note: All search paths were added! It is possible that this is an almost 20-year old bug

- Issues with MS-DOS Real-Mode total memory and Turbo C++ compiler v3.00 Memory models constraints

- A problem with the Turbo Link if a Tiny or Compact Memory models are selected:
	...
	Turbo Link  Version 5.0 Copyright (c) 1992 Borland International
	Error: Group DGROUP exceeds 64K
	...

- Turbo Link was unable to generate COM-executable:
	...
	Fatal: Cannot generate COM file : segment-relocatable items present
	...

- Turbo C++ compiler v3.00 fails to compile some C++ codes and exits with an error message: "FATAL ERROR: GP FAULT"

- A problem with some protected mode instructions generated by Turbo C++ compiler v3.00 in case of Large or Huge Memory models of an application

- The Windows NTVDM crashed when an illegal CPU instruction was executed in a test application

- Math related problems:
	...
	Floating point error: Divide by 0.
	Abnormal program termination
	...

- A complitely unexplained error messages "Multi-Bit ECC Error System Halted" and "Divide Error" when executing an application compiled for a Huge Memory model

- Dynamic memory management related problems with a Memory Tracing subsystem in case of selecting different Memory models for a test application

And many, many another issues and problems appearing over the course of firsttwo weeks of integration.

I would split these problems into 3 groups:

- Project configuration due to 8.3 file names in MS-DOS
- Not Portable "Leaks" in the C++ source codes of the ScaLib library
- Turbo C++ compiler v3.00 related

At the end of the second day, when almost &lt;STRONG&gt;99 percent&lt;/STRONG&gt; of all source codes were commented out (!), I had a plan on how to move ahead and about &lt;STRONG&gt;4 weeks&lt;/STRONG&gt; later Turbo C++ compiler v3.00 integration was completed.

And what's the point? It is simple: If I would try to follow the &lt;STRONG&gt;Google It!&lt;/STRONG&gt; approach the integration of the C++ compiler would be never completed and the project would be possibly canceled. As of today 5 different C++ compilers ( 14 versions ) are integrated with the ScaLib project and in terms of portability this is a really unique one.

I also would like to address my message to modern software developers:

&lt;STRONG&gt;Guys, you need to fight problems and you should not expect that somebody will give you a solution!&lt;/STRONG&gt;

Good Luck to everybody!

Best regards,
Sergey Kostrov

Senior C++ Software Developer
Intel Black Belt Software Developer ( since September 2012 )
Calgary, Alberta, Canada

Note: &lt;STRONG&gt;ScaLib&lt;/STRONG&gt; stands for &lt;STRONG&gt;Set Of Common Algorithms Library&lt;/STRONG&gt;</description>
      <pubDate>Sun, 06 Oct 2013 03:11:53 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950555#M19430</guid>
      <dc:creator>SergeyKostrov</dc:creator>
      <dc:date>2013-10-06T03:11:53Z</dc:date>
    </item>
    <item>
      <title>Hello Sergey,</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950556#M19431</link>
      <description>&lt;P&gt;Hello Sergey,&lt;/P&gt;
&lt;P&gt;Could you pls elaborate on &lt;STRONG&gt;How You Solved the problem&lt;/STRONG&gt;? that is something I could learn from. I am not faint hearted myself, but the problem described is a programer's nightmare.&lt;/P&gt;
&lt;P&gt;The wish to integrate good, proven, compact DOS-based programs and tools into gigantic, super-feature-rich, megabyte-length Windows environment is not so uncommon.&lt;/P&gt;</description>
      <pubDate>Sat, 19 Oct 2013 08:52:32 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950556#M19431</guid>
      <dc:creator>zalia64</dc:creator>
      <dc:date>2013-10-19T08:52:32Z</dc:date>
    </item>
    <item>
      <title>&gt;&gt;...Could you pls elaborate</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950557#M19432</link>
      <description>&amp;gt;&amp;gt;...Could you pls elaborate on How You Solved the problem? that is something I could learn from...

I will provide a &lt;STRONG&gt;couple&lt;/STRONG&gt; of examples. However, a complete list of all solved problems ( and solutions ) is very long and it doesn't make sense to post it.

Let me know if you need a Turbo C++ v3.x compiler for tests, etc.</description>
      <pubDate>Fri, 25 Oct 2013 21:59:00 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950557#M19432</guid>
      <dc:creator>SergeyKostrov</dc:creator>
      <dc:date>2013-10-25T21:59:00Z</dc:date>
    </item>
    <item>
      <title>&gt;&gt;...Could you pls elaborate</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950558#M19433</link>
      <description>&lt;P&gt;&amp;gt;&amp;gt;...Could you pls elaborate on How You Solved the problem? that is something I could learn from.&lt;/P&gt;
&lt;P&gt;I meant the strategy of attack. The 'list of problems' as a starter is self-evident.&lt;/P&gt;
&lt;P&gt;Given the fact that each patch may insert new hidden bugs, a long list of patches ensures troubles. Obviously, you did not do a lengthy point-by-point patch through. Obviously, you had a better strategy.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It was proved to me on my first year, that a normal person (me) can't calculate a 5x5 determinant, using pen and paper in the straight-forward way. How? I checked and re-checked my results, and never got two successive equal numbers. That lesson helped me avoid long lists of patches.&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 26 Oct 2013 08:32:08 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950558#M19433</guid>
      <dc:creator>zalia64</dc:creator>
      <dc:date>2013-10-26T08:32:08Z</dc:date>
    </item>
    <item>
      <title>I too am interested in how</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950559#M19434</link>
      <description>&lt;P&gt;I too am interested in how you tackled this!&lt;/P&gt;
&lt;P&gt;By the way, why did you choose Turbo C++ 3, an ancient DOS C++ compiler? &amp;nbsp;It's very impressive that you got it working, but I'm still puzzled why this would be a target. &amp;nbsp;Does ScaLib have DOS users?&lt;/P&gt;
&lt;P&gt;If you want a non-GCC, non-MS compiler, especially Borland, why not a modern version of Borland / Embarcadero C++ Builder? &amp;nbsp;If you used, say, Embarcadero C++Builder XE3 (two versions old now) you could have a non-MS but modern 32 and 64-bit C++ compiler. &amp;nbsp;In fact the 64-bit version would be quite useful since it's a brand new compiler for the company based on CLANG. &amp;nbsp;The 32-bit one is decent but would give you some useful compatibility checks; it's not CLANG-based but is the updated descendant of the Borland C++ compiler chain. &amp;nbsp;In addition, you could use it for cross-platform checks, since it compiles for OSX and iOS as well.&lt;/P&gt;
&lt;P&gt;This isn't a criticism, just curiosity about why you chose the target you did, and perhaps also a suggestion for a compile target that users of your library might find useful. &amp;nbsp;(I think you'll find more people using C++Builder for Windows, OSX, or iOS than using Turbo C++ for DOS.)&lt;/P&gt;</description>
      <pubDate>Tue, 05 Nov 2013 08:03:23 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950559#M19434</guid>
      <dc:creator>David_M_23</dc:creator>
      <dc:date>2013-11-05T08:03:23Z</dc:date>
    </item>
    <item>
      <title>&gt;&gt;...why did you choose Turbo</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950560#M19435</link>
      <description>&amp;gt;&amp;gt;...why did you choose Turbo C++ 3, an ancient DOS C++ compiler?..

In order to &lt;STRONG&gt;break ALL dependencies&lt;/STRONG&gt; on Microsoft APIs, like Win32 API, and deviated CRT functions ( there are lots of them and many Windows developers simply Do Not know about it. Please believe me! ). That is why the codes are &lt;STRONG&gt;99.99%&lt;/STRONG&gt; portable.

Consider Turbo C++ version 3.x as some kind of Supreme C++ Normalizer. When codes are compiled with Turbo C++ it instantly detects any deviations in codes from a 20-year-old C++ standard 2.1 and version 3.0 templates. At the same time Turbo C++ is Not used for any performance evaluations.

&amp;gt;&amp;gt;...Does ScaLib have DOS users?..

There are &lt;STRONG&gt;No&lt;/STRONG&gt; any MD-DOS customers however Turbo C++ version 3.x forces a developer to implement codes in as clean as possible way. For example, an executable just &lt;STRONG&gt;24KB&lt;/STRONG&gt; in size ( Not MB! ) could be created. The executable of a such small size doesn't do too much and it is a demonstration of efficient and highly optimized internal solutions.

For example, the library has a set of linear algebra algorithms and one of them is Strassen Heap Based matrix multiplication algorithm. The same codes could be compiled for 16-bit MS-DOS, 32-bit Desktop and Embedded, and 64-bit Desktop operating systems with five ( 5 ) different major versions of C++ compilers ( and already 15 different editions / updates ):

- Turbo C++ v3.x
- Borland C++ v5.x
- MinGW v3.4.2 &amp;amp; v4.8.1
- Microsoft Visual C++ v6.x ( SP5 )
- Microsoft Visual Studios 2005, 2008, 2010, 2012
- Intel C++ v7.x
- Intel C++ v8.x
- Intel C++ v12.x ( two updates are supported )
- Intel C++ v13.x ( two updates are supported )</description>
      <pubDate>Thu, 14 Nov 2013 02:59:07 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950560#M19435</guid>
      <dc:creator>SergeyKostrov</dc:creator>
      <dc:date>2013-11-14T02:59:07Z</dc:date>
    </item>
    <item>
      <title>I was asked already by a</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950561#M19436</link>
      <description>I was asked already by a couple of IDZ users about what exactly I did to complete that integration. That's a really big subject and I could write a book with many chapters about it. However, here are a couple of very simple examples which could help you to understand what kind of problems I had to deal with...</description>
      <pubDate>Fri, 22 Nov 2013 23:36:02 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950561#M19436</guid>
      <dc:creator>SergeyKostrov</dc:creator>
      <dc:date>2013-11-22T23:36:02Z</dc:date>
    </item>
    <item>
      <title>[ Example 1 - Part A - MS</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950562#M19437</link>
      <description>&lt;STRONG&gt;[ Example 1 - Part A - MS compatible C++ compilers ]&lt;/STRONG&gt;

// &lt;STRONG&gt;MSC compilers&lt;/STRONG&gt;

Compatible Data Types ( size in bytes ):
        RTbool       -  1
        RTchar       -  1
        RTuchar      -  1
        RTbyte       -  1
        RTubyte      -  1
        RTlong       -  4
        RTulong      -  4
        RTint8       -  1
        RTuint8      -  1
        RTint16      -  2
        RTuint16     -  2
        RTint32      -  4
        RTuint32     -  4
        RTfloat      -  4
        RTm128float  -  4
        RTdouble     -  8
        RTm128double -  8
        RTint        -  4
        RTuint       -  4
        RTint64      -  8
        RTuint64     -  8
        RTclock_t    -  4
        RTm128int    -  4
Incompatible Data Types ( size in bytes ):
        RTtime_t     -  4
        RTtchar      -  2
        RTlongdouble -  8

// &lt;STRONG&gt;ICC compilers&lt;/STRONG&gt;

Compatible Data Types ( size in bytes ):
        RTbool       -  1
        RTchar       -  1
        RTuchar      -  1
        RTbyte       -  1
        RTubyte      -  1
        RTlong       -  4
        RTulong      -  4
        RTint8       -  1
        RTuint8      -  1
        RTint16      -  2
        RTuint16     -  2
        RTint32      -  4
        RTuint32     -  4
        RTfloat      -  4
        RTm128float  -  4
        RTdouble     -  8
        RTm128double -  8
        RTint        -  4
        RTuint       -  4
        RTint64      -  8
        RTuint64     -  8
        RTclock_t    -  4
        RTm128int    -  4
Incompatible Data Types ( size in bytes ):
        RTtime_t     -  4
        RTtchar      -  2
        RTlongdouble -  8</description>
      <pubDate>Fri, 22 Nov 2013 23:36:53 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950562#M19437</guid>
      <dc:creator>SergeyKostrov</dc:creator>
      <dc:date>2013-11-22T23:36:53Z</dc:date>
    </item>
    <item>
      <title>[ Example 1 - Part B - GCC</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950563#M19438</link>
      <description>&lt;STRONG&gt;[ Example 1 - Part B - GCC compatible C++ compilers ]&lt;/STRONG&gt;

// &lt;STRONG&gt;MGW compilers&lt;/STRONG&gt;

Compatible Data Types ( size in bytes ):
        RTbool       -  1
        RTchar       -  1
        RTuchar      -  1
        RTbyte       -  1
        RTubyte      -  1
        RTlong       -  4
        RTulong      -  4
        RTint8       -  1
        RTuint8      -  1
        RTint16      -  2
        RTuint16     -  2
        RTint32      -  4
        RTuint32     -  4
        RTfloat      -  4
        RTm128float  -  4
        RTdouble     -  8
        RTm128double -  8
        RTint        -  4
        RTuint       -  4
        RTint64      -  8
        RTuint64     -  8
        RTclock_t    -  4
        RTm128int    -  4
Incompatible Data Types ( size in bytes ):
        RTtime_t     -  4
        RTtchar      -  2
        RTlongdouble - 12</description>
      <pubDate>Fri, 22 Nov 2013 23:37:35 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950563#M19438</guid>
      <dc:creator>SergeyKostrov</dc:creator>
      <dc:date>2013-11-22T23:37:35Z</dc:date>
    </item>
    <item>
      <title>[ Example 1 - Part C -</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950564#M19439</link>
      <description>&lt;STRONG&gt;[ Example 1 - Part C - Borland compatible C++ compilers ]&lt;/STRONG&gt;

// &lt;STRONG&gt;BCC compiler&lt;/STRONG&gt;

Compatible Data Types ( size in bytes ):
        RTbool       -  1
        RTchar       -  1
        RTuchar      -  1
        RTbyte       -  1
        RTubyte      -  1
        RTlong       -  4
        RTulong      -  4
        RTint8       -  1
        RTuint8      -  1
        RTint16      -  2
        RTuint16     -  2
        RTint32      -  4
        RTuint32     -  4
        RTfloat      -  4
        RTm128float  -  4
        RTdouble     -  8
        RTm128double -  8
        RTint        -  4
        RTuint       -  4
        RTint64      -  8
        RTuint64     -  8
        RTclock_t    -  4
        RTm128int    -  4
Incompatible Data Types ( size in bytes ):
        RTtime_t     -  4
        RTtchar      -  2
        RTlongdouble - 10

// &lt;STRONG&gt;TCC compiler&lt;/STRONG&gt;

Compatible Data Types ( size in bytes ):
        RTbool       -  1
        RTchar       -  1
        RTuchar      -  1
        RTbyte       -  1
        RTubyte      -  1
        RTlong       -  4
        RTulong      -  4
        RTint8       -  1
        RTuint8      -  1
        RTint16      -  2
        RTuint16     -  2
        RTint32      -  4
        RTuint32     -  4
        RTfloat      -  4
        RTm128float  -  4
        RTdouble     -  8
        RTm128double -  8
        RTint        -  4
        RTuint       -  4
        RTint64      -  8
        RTuint64     -  8
        RTclock_t    -  4
        RTm128int    -  4
Incompatible Data Types ( size in bytes ):
        RTtime_t     -  4
        RTtchar      -  1
        RTlongdouble - 10</description>
      <pubDate>Fri, 22 Nov 2013 23:38:12 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950564#M19439</guid>
      <dc:creator>SergeyKostrov</dc:creator>
      <dc:date>2013-11-22T23:38:12Z</dc:date>
    </item>
    <item>
      <title>[ Example 1 - Part D ]</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950565#M19440</link>
      <description>&lt;STRONG&gt;[ Example 1 - Part D ]&lt;/STRONG&gt;

There is a small subset of some data types which create Binary Compatibility problems.

So, take a look at a section with Incompatible Data Types:

// &lt;STRONG&gt;MSC compilers&lt;/STRONG&gt;

...
Incompatible Data Types ( size in bytes ):
        RTtime_t     -  4
        RTtchar      -  2
        RTlongdouble -  8

// &lt;STRONG&gt;ICC compilers&lt;/STRONG&gt;

...
Incompatible Data Types ( size in bytes ):
        RTtime_t     -  4
        RTtchar      -  2
        RTlongdouble -  8

// &lt;STRONG&gt;MGW compilers&lt;/STRONG&gt;

...
Incompatible Data Types ( size in bytes ):
        RTtime_t     -  4
        RTtchar      -  2
        RTlongdouble - 12

// &lt;STRONG&gt;BCC compiler&lt;/STRONG&gt;

...
Incompatible Data Types ( size in bytes ):
        RTtime_t     -  4
        RTtchar      -  2
        RTlongdouble - 10

// &lt;STRONG&gt;TCC compiler&lt;/STRONG&gt;

...
Incompatible Data Types ( size in bytes ):
        RTtime_t     -  4
        RTtchar      -  1
        RTlongdouble - 10

Even if &lt;STRONG&gt;RTtime_t&lt;/STRONG&gt; equals to 4 in all these cases this is Not Compatible (!) data type and take a look at MSDN to read a topic about what is wrong with the data type.</description>
      <pubDate>Fri, 22 Nov 2013 23:39:02 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950565#M19440</guid>
      <dc:creator>SergeyKostrov</dc:creator>
      <dc:date>2013-11-22T23:39:02Z</dc:date>
    </item>
    <item>
      <title>This is how a log-file looks</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950566#M19441</link>
      <description>This is how a log-file looks like when a Binary Compatibility of Data Types is Passed, for example on a 16-bit platform:
...
***********************************
Configuration - COS16_TCC - Debug
CTestSet::InitTestEnv - Passed

* CCommonSet Start *
&amp;gt; CCommonSet Methods &amp;lt;
GetPlatformName - COS16_TCC
GetPlatformName - Passed
GetPlatformType - 16-bit
GetPlatformType - Passed
&lt;STRONG&gt;VerifyDataTypes - Data Types Verified&lt;/STRONG&gt;
&lt;STRONG&gt;VerifyDataTypes - Passed&lt;/STRONG&gt;
GetHardwareParams - Passed
GetSoftwareParams - Passed
&amp;gt; CCommonSet Algorithms &amp;lt;
* CCommonSet End *

Memory Blocks Allocated   :     1
Memory Blocks Released    :     1
Memory Blocks NOT Released:     0
...</description>
      <pubDate>Fri, 22 Nov 2013 23:39:34 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950566#M19441</guid>
      <dc:creator>SergeyKostrov</dc:creator>
      <dc:date>2013-11-22T23:39:34Z</dc:date>
    </item>
    <item>
      <title>[ Example 2 ]</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950567#M19442</link>
      <description>&lt;STRONG&gt;[ Example 2 ]&lt;/STRONG&gt;

There are some issues with measurements of time intervals and a workaround needs to be used. Here is a simple
demonstration of how results look like on 32-bit and 16-bit platforms when a portable version of a &lt;STRONG&gt;CrtRdtcs&lt;/STRONG&gt; function is used:

&lt;STRONG&gt;[ MinGW C++ compiler ]&lt;/STRONG&gt;
...
&amp;gt; Test1144 Start &amp;lt;
Sub-Test 5   - [ CrtRdtsc ]
Sub-Test 5   - 1 sec delay between calls to [ CrtRdtcs ] - 1586180388 clock cycles
Test Completed in 1000 ticks
&amp;gt; Test1144 End &amp;lt;
...

&lt;STRONG&gt;[ Turbo C++ compiler ]&lt;/STRONG&gt;
...
&amp;gt; Test1144 Start &amp;lt;
Sub-Test 5   - [ CrtRdtsc ]
Sub-Test 5   - 1 sec delay between calls to [ CrtRdtcs ] - 18 clock ticks
Test Completed in 1000 ticks
&amp;gt; Test1144 End &amp;lt;
...

Note: There are 18.2 ticks in a second on a 16-bit platform. This is a limitation of a Timer Interrupt ( INT 8 ) and how programmable controller of interrupts is initialized by default, for example in MS-DOS, PhysTech-DOS, DR-DOS and similar operating systems.</description>
      <pubDate>Fri, 22 Nov 2013 23:40:23 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950567#M19442</guid>
      <dc:creator>SergeyKostrov</dc:creator>
      <dc:date>2013-11-22T23:40:23Z</dc:date>
    </item>
    <item>
      <title>[ Example 3 ]</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950568#M19443</link>
      <description>&lt;STRONG&gt;[ Example 3 ]&lt;/STRONG&gt;

Support for some simple Intel intrinsic functions on a 16-bit platform when Turbo C++ compiler is used, like &lt;STRONG&gt;_mm_prefetch&lt;/STRONG&gt; or &lt;STRONG&gt;_mm_sfence&lt;/STRONG&gt;. That's the problem because inline assembler is Not supported by a Turbo C++ compiler.</description>
      <pubDate>Fri, 22 Nov 2013 23:41:34 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950568#M19443</guid>
      <dc:creator>SergeyKostrov</dc:creator>
      <dc:date>2013-11-22T23:41:34Z</dc:date>
    </item>
    <item>
      <title>[ Example 4 ]</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950569#M19444</link>
      <description>&lt;STRONG&gt;[ Example 4 ]&lt;/STRONG&gt;

There is No support for &lt;STRONG&gt;__restrict__&lt;/STRONG&gt; keyword by Turbo C++ compiler and a macro-based workaround needs to be used.</description>
      <pubDate>Fri, 22 Nov 2013 23:42:32 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950569#M19444</guid>
      <dc:creator>SergeyKostrov</dc:creator>
      <dc:date>2013-11-22T23:42:32Z</dc:date>
    </item>
    <item>
      <title>[ Example 5 ]</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950570#M19445</link>
      <description>&lt;STRONG&gt;[ Example 5 ]&lt;/STRONG&gt;

There are internal problems with Turbo C++ compiler. For example, it fails to build an executable in Debug configuration when a copy constructor is declared in some class. At the same time, in Release configuration an executable could be successfully built.</description>
      <pubDate>Fri, 22 Nov 2013 23:43:39 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950570#M19445</guid>
      <dc:creator>SergeyKostrov</dc:creator>
      <dc:date>2013-11-22T23:43:39Z</dc:date>
    </item>
    <item>
      <title>[ Example 6 ]</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950571#M19446</link>
      <description>&lt;STRONG&gt;[ Example 6 ]&lt;/STRONG&gt;

Exact Binary Compatibility of Data Types breaks if data transferred between platforms using TCP/IP or RS-232. If a union, like

typedef union tagSomeUnion
{
	char A;
	char B;
	char C;
	size_t D;
} SomeUnion;

is used then there is No Binary Compatibility and this is why:

&lt;STRONG&gt;16-bit platform&lt;/STRONG&gt;: sizeof( SomeUnion ) = 2 bytes
&lt;STRONG&gt;32-bit platform&lt;/STRONG&gt;: sizeof( SomeUnion ) = 4 bytes
&lt;STRONG&gt;64-bit platform&lt;/STRONG&gt;: sizeof( SomeUnion ) = 8 bytes

and so on.

&lt;STRONG&gt;Note&lt;/STRONG&gt;: Microsoft's &lt;STRONG&gt;RPC&lt;/STRONG&gt; manages Binary Compatibility very good but I didn't have a Microsoft C++ compiler version 1.5 ( for MS DOS ). Next, Turbo C++ compiler doesn't provide any support for &lt;STRONG&gt;RPC&lt;/STRONG&gt; on a 16-bit platforms. Also, it doesn't have a 16-bit Interface Definition Language ( IDL ) compiler to compile the IDL files with declared interfaces. Tools from competitors, like &lt;STRONG&gt;CORBA&lt;/STRONG&gt; or &lt;STRONG&gt;DCE&lt;/STRONG&gt;, do not help as well since I don't think they were ever released for 16-bit platforms.</description>
      <pubDate>Fri, 22 Nov 2013 23:46:11 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950571#M19446</guid>
      <dc:creator>SergeyKostrov</dc:creator>
      <dc:date>2013-11-22T23:46:11Z</dc:date>
    </item>
    <item>
      <title>[ Example 7 ]</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950572#M19447</link>
      <description>&lt;STRONG&gt;[ Example 7 ]&lt;/STRONG&gt;

Here is a &lt;STRONG&gt;8.3-Problem&lt;/STRONG&gt; with files names on 16-bit platforms and this is how it affects sources:
...
#if ( defined ( _MSC_COMPILER_A_ ) || defined ( _ICC_COMPILER_B_ ) || defined ( _GCC_COMPILER_C_ ) )
	#include "../../Include/SomeFileWithLongName.h"
#endif
#if ( defined ( _ Turbo C++ Compiler _ ) )
	#include "../../Include/SomeFi~1.h"
#endif
...</description>
      <pubDate>Fri, 22 Nov 2013 23:47:22 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950572#M19447</guid>
      <dc:creator>SergeyKostrov</dc:creator>
      <dc:date>2013-11-22T23:47:22Z</dc:date>
    </item>
    <item>
      <title>[ Example 8 ]</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950573#M19448</link>
      <description>&lt;STRONG&gt;[ Example 8 ]&lt;/STRONG&gt;

Here is a &lt;STRONG&gt;Configuration Params Problem&lt;/STRONG&gt; and a simple solution looks like:
...
	g_iParam1 = atoi( getenv( "PARAM_1" ) );
	g_iParam2 = atoi( getenv( "PARAM_2" ) );
	g_iParam3 = atoi( getenv( "PARAM_3" ) );
...
Of course, number of parameters defined as Environment Variables needs to be limited but this is a one-line solution compared to multi-line implemntation of different ini-file, cfg-file, or xml-file readers, etc.</description>
      <pubDate>Fri, 22 Nov 2013 23:48:07 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950573#M19448</guid>
      <dc:creator>SergeyKostrov</dc:creator>
      <dc:date>2013-11-22T23:48:07Z</dc:date>
    </item>
    <item>
      <title>[ Example 9 ]</title>
      <link>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950574#M19449</link>
      <description>&lt;STRONG&gt;[ Example 9 ]&lt;/STRONG&gt;

There is No any support for 64-bit integer types on 16-bit platforms and a very simple solution based on a Single Precision Floating Point data type ( float ) is used. But, there is a limitation and, for example, a valid range of unsigned 64-bit integers values is from 0 to 16777216 ( that is, from 0 to 2^24 ).</description>
      <pubDate>Fri, 22 Nov 2013 23:48:57 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/A-Success-Story-of-some-software-integration-Turbo-Disaster-or/m-p/950574#M19449</guid>
      <dc:creator>SergeyKostrov</dc:creator>
      <dc:date>2013-11-22T23:48:57Z</dc:date>
    </item>
  </channel>
</rss>

