StackProbe - A Low-overhead Java Profiler
Among many open-source and commercial profilers, I could not find an easy to use and low-overhead java profiler. Most profilers use bytecode instrumentation to inject their code into the code of the profiled application. Bytecode instrumentation not only does significantly slow the profiled application down, but it also changes its profile. The overhead is high especially for very short, usually inlined methods, like getters or setters. Sometimes it can introduce a fake bottleneck in the application and mislead the programmer into optimizing wrong parts of the code.
The main features of StackProbe are:
- Flat thread and method profile
- Contextual profile with call-trees
- User-controlled overhead
- Uniform overhead: no method of the profiled program affected more than other methods
- Measurement of running, sleeping and waiting time
- Results given with error estimate
- Safe remote profiling of production systems
- Fast method search
- Method and thread filters for even lower overhead
- Comparing profiles
- No configuration
- No bytecode injection
- Results given in seconds
- Nice and intuitive GUI
Get the profiler from the StackProbe site
A Soft Real-Time Garbage Collector for C++
The garbage collector (GC) helps you to manage dynamic memory in C++ easily, with low risk of memory corruption or memory leaks. This GC is precise, does not make long pauses and is quite fast. Measurements show the CPU overhead to be usually less than 3% in real-world applications which is much better result than that of Boost smart pointers. By the way, my smart pointers can reclaim reference cycles.
My GC works on Linux, FreeBSD, OpenBSD and possibly other Unix-like systems.
This piece of code was developed as a part of my master thesis. At first it I thought it would be a simple implementation of reference counting pointers needed in the simple C++ servlet engine but soon I found out this technique to be inadequate. Then the algorithm was changed to mark and sweep, and in the end to concurrent mark and sweep to add some real-time capabilities. Writing this was a really challenging experience. The package contains also a simple servlet engine ideal for writing C++ applications configured via HTTP. However, I do not recommend to use this library for writing web applications, as there are better languages and tools for it (e.g. Java, Python or Ruby).
Download the GC source code with documentation (3 MB)
XLAB - An Analog Circuits Simulator
XLAB is a Windows application that enables you to draw an electronic circuit and then simulate its behaviour. It can calculate voltages, currents, do transient analysis, draw frequency characteristics, perform FFT and much more. Some semiconductor elements are modelled with SPICE equations. Complicated circuits with transistors, op-amps, RLC, controlled voltage/current sources, digital gates, etc. can be simulated.
This is probably the largest program I have ever written. I worked on it mostly while I attended the high school. It is fully written in Delphi and consisted of more that 40,000 lines of code. I wasn't so good at object programming then as now, and the design is quite bad. There are lots of spaghetti code in there. I gave up development in 2001.
Download the final XLAB release (710 kB)
Download the complete source code (1 MB)