On Time RTOS-32 Documentation
Welcome
RTTarget-32
RTTarget-32 Programming Manual
Introduction
Running Win32 Programs without Win32
The i386 Microprocessor
RTLoc: Locating a Program
Running a Program on the Target
Cross Debugging
Using an IDE
The RTTarget-32 API
Demo Programs
Advanced Topics
Choosing a Locate Method
Running with or without Paging
Running at CPL 0 or 3
Installing Hardware Interrupt Handlers
Catching NULL Pointer Assignments
Catching Stack Overflows
Running without Run-Time System
Avoid Repeated Downloads
Configuration for Debug and Release Builds
Using Data Compression
Using DLLs through RTLoc
Loading DLLs through a File System
RAM File System
Installable File System
Multithread Applications
Using the MetaWINDOW Graphics Library
Using the 387 Emulator
Using Non-Volatile Memory
APIC Mode
Multiprocessor Applications
Custom MP Floating Pointer Structure
RTVmf-32
RTRth-32
Performance Optimizations
Compiling and Linking with On Time RTOS-32
Redistributable Components of RTTarget-32
RTLoc Error Messages
RTTarget-32 Reference Manual
RTKernel-32
RTFiles-32
RTIP-32
RTPEG-32
RTUSB-32
|
Running without Run-Time System
RTTarget-32 fully supports the run-time systems of the supported compilers. This simplifies porting programs that use the run-time system extensively. However, there is some overhead involved. Depending on the application's use of the run-time system, up to 100k of memory can be required to support it.
Simple applications that don't need the heap can be significantly reduced in size if the run-time system is eliminated. However, all calls to run-time system functions (such as malloc, free, printf, etc.) must be removed. Section Compiling and Linking with On Time RTOS-32 explains how RTTarget-32's special startup code can be used to eliminate the compiler's run-time system.
Advantages of the Run-Time System
- Easy porting. Existing software containing calls to the run-time system can run under RTTarget-32, often with no or only minor modifications.
- Ease of programming. The functionality of the run-time system can be used for the benefit of the application.
- Availability of the heap. Dynamic memory management using malloc, free, realloc, etc., is fully supported.
- C++ features can be used. The run-time system takes care of automatic constructor/destructor calls, exception handling, etc.
- Run-time checks of the run-time system can be used. For example, most compilers can be instructed to generate calls to run-time system routines for stack overflow or other checks.
Benefits of running without a Run-Time System
- Lower resource requirements. Programs without the run-time system are much smaller.
- No Heap. Most Win32 programs expect a heap of at least 64k to be available, even if the application requires much less heap space. Without the run-time system, there is no need to allocate a single byte of heap memory.
RTTarget-32 does not support eliminating the Delphi run-time system for Pascal programs. However, due to Delphi's smart linker, the Pascal run-time system's size can be next to negligible. If unit SysUtils is not used, the Delphi run-time system does not allocate any heap space for its internal housekeeping.
Generally, the use of the run-time system is recommended. It should be eliminated only if low resource requirements must be met.
Advanced Topics
Catching Stack Overflows
Avoid Repeated Downloads
|