Hubbry Logo
search
logo

FastCode

logo
Community Hub0 Subscribers
Write something...
Be the first to start a discussion here.
Be the first to start a discussion here.
See all
FastCode

FastCode is an open source programming project that aims to provide optimized runtime library routines for Embarcadero Delphi and C++ Builder. This community-driven project was started in 2003 by Dennis Kjaer Christensen and has since contributed optimized functionality to the 32-bit Delphi runtime library (RTL).

Organized as a competition divided into challenges, FastCode focuses on optimizing specific functions against multiple targets. The project offers benchmarking tools and validation processes for each function contribution. Contributions are scored, with points awarded based on performance against the targets. Embarcadero recognizes and incorporates the code created by the FastCode team into their Delphi codebase. Most participants in this project are assembler developers who utilize processor-specific code. The list of challenges tackled by the FastCode project is extensive; it covers diverse areas ranging from string manipulation functions like PosEx or CompareText to mathematical operations such as Power or Int64Mul.

The project is organized as a competition divided into challenges. Each challenge takes one function and optimizes it against a number of targets. The project provides tools for benchmarking and validating each function contribution. One point is given per contribution (maximally one function per target is given points) and ten points are awarded for a target winner. A list with all contributors and their scores is maintained, and at the end of each year, until 2008, a winner was celebrated. Borland, Codegear and Embarcadero, the owners of Delphi and C++ Builder, have historically sponsored prizes.

The majority of participants in the competition are assembler developers who often utilize processor-specific 32-bit code and extra instruction sets, such as MMX, SSE, SSE2, SSE3, SSSE3 and SSE4.

The project enjoys the support of Embarcadero who recognizes the contributions of the FastCode team and incorporates their code into the codebase for Delphi. The default memory manager for Embarcadero Delphi, FastMM4, is the winner of the FastCode Memory Manager challenge.

The project was first hosted on Robert Lee's OptimalCode site, and its source code's home page is [1], last updated in 2008. The source code contains both the enhanced routines and the testing suites to benchmark the routines. In 2017, the benchmark routines for Move, FillChar and the memory manager have been ported for 64-bit, available at [2].

The FastCode project puts a lot of effort into testing and focus is on providing very-high-quality software. Testing is split into two categories - testing for correctness and testing for speed.

Validation is done on all CPUs from the target set and very often on other CPUs and OSs (Windows XP, Windows Vista, Windows 7 etc.) as well. Validation is done across many different function inputs, both normal usage cases and error usage cases. Validation is done against known correct values and against reference implementations such existing RTL functions.

See all
User Avatar
No comments yet.