.

Low-overhead components

My personal dream of an ideal programming language is one that allows defining flexible, configurable components that can be coupled together with very little overhead, producing in the end code that, if reverse-engineered, would appear to be hand-written and optimized for the specific task at hand. Preconfigured component configurations / presets would be available for common use, favoring safety and feature-completeness, but for performance-critical cases, the programmer could break them down and strip out unneeded features to reduce overhead, or customize by injecting their own components into the mix. Continue reading →

Installing PHP and Apache module under /home

Let’s say you have your own Apache 2 setup in your home directory, and you want to build and install PHP as well, and set it up as an Apache module without root privileges (e.g. if you want to use a different PHP version than the one installed globally).

You may run into problems such as PHP’s configure script not detecting apxs2 (and thus not building an Apache module). Continue reading →

Very Sleepy fork

I got fed up with waiting/pestering Richard Mitton (aka Kayamon / @grumpygiant) to integrate the Very Sleepy patches I’ve sent him last year or putting the code on a software forge, so I’m publishing my patches on GitHub myself.

Very Sleepy is a polling Windows profiler with a wxWidgets-based GUI. This is a fork of the latest released version at the time of writing (0.82).

There have been a few more forks of Very Sleepy (e.g. here and here), but these are based off older versions. It’s possible that their changes had already been merged into the official version.

Update: I’ve continued development of my fork, at the above-mentioned location. Check the GitHub project for the changelog, downloads, and more information.

Update 2: Very Sleepy CS is now Very Sleepy!

DHCP test client

While trying to set up my home network, I was dismayed that there was no simple way to test the DHCP server. Snooping packets is limited to examining existing traffic.

DHCP test tools exist (DHCPing and dhquery), however both are outdated and don’t work with the latest versions of their requirements, and both won’t work on Windows.

I’ve written a simple DHCP “client” which can receive and decode broadcasted DHCP replies, as well as send out DHCP “discover” packets. The tool is cross-platform, and should work on Windows and major POSIX systems.

Source, Windows binaries.

64-bit CacheSet

SysInternals CacheSet has a limitation: it is unable to set a cache size larger than 4GB. This is due to the fact that it is a 32-bit application, and the respective API (NtSetSystemInformation) accepts new settings as a 32-bit byte count.

The solution: use the 64-bit API, which uses 64-bit integers. I’ve written a very simple 64-bit CacheSet-alike – just enter the desired cache size (in bytes). You can use the original CacheSet to check the new settings (just don’t hit “Apply”, or your settings might get clobbered).

Source, download.

KeyboardEmperor

If you use Windows and like speed, you may have heard of Keyboard King, a program that allows accelerating your keyboard repeat rate to over Windows’ maximum limit. However, if you did use Keyboard King, you probably ran into its shortcomings: the method it uses to accelerate the repeat rate is buggy, because the approach it uses is insufficient.

Enter KeyboardEmperor, a kernel-mode hack that changes the repeat rate value directly in Windows’ USB keyboard driver. Continue reading →