The Old New Thing
Practical development throughout the evolution of Windows.
Latest posts
Microspeak: Sats
I introduced this Microspeak last year as part of a general entry about management-speak, but I'm giving it its own entry because it deserves some attention on its own. I just want to have creative control over how my audience can interact with me without resorting to complex hacking in a way that is easy to explain but ups our blogging audiences sats to a new level that may also stimulate a developer ecosytem that breeds quality innovation... Ignore the other management-speak; we're looking at the weird four-letter word sats. Sats is short for satisfaction metrics. This falls under the overall obsession on...
Ha ha, the speaker gift is a speaker, get it?
As a thank-you for presenting at TechReady11, the conference organizers gave me (and presumably the other speakers) a portable speaker with the Windows logo printed on it. The speaker underneath the logo is the X-Mini II Capsule Speaker, and I have to agree with Steve Clayton that they pack a lot of sound in a compact size. Great for taking on trips, or even picnics. It's been a long time since I last recommended a Christmas gift for geeks, so maybe I'll make up for it by giving two suggestions this year. The second suggestion is a response to a comment from that old article: My bicycle lock is just a lapt...
Why doesn't Win32 give you the option of ignoring failures in DLL import resolution?
Yuhong Bao asked, via the Suggestion Box, "Why not implement delay-loading by having a flag in the import entry specifying that Windows should mimic the Windows 3.1 behavior for resolving that import?" Okay, first we have to clear up the false assumptions in the question. The question assumes that Windows 3.1 had delay-loading functionality in the first place (functionality that Yuhong Bao would like added to Win32). Actually, Windows 3.1 behavior did not have any delay-load functionality. If your module imported from another DLL in its import table, the target DLL was loaded when your module was load...
Hey there token, long time no see! (Did you do something with your hair?)
Consider a system where you have a lot of secured objects, and suppose further that checking whether a user has access to an object is a slow operation. This is not as rare as you might think: Even though a single access check against a security descriptor with a small number of ACEs might be fast, you can have objects with complicated security descriptors or (more likely) users who belong to hundreds or thousands of security groups. Since checking whether a security descriptor grants access to a token is potentially¹ O(nm) in the number of ACEs in the security descriptor and the number of groups the user be...
Flushing your performance down the drain, that is
Some time ago, Larry Osterman discussed the severe performance consequences of flushing the registry, which is a specific case of the more general performance catch: Flushing anything will cost you dearly. A while back, I discussed the high cost of the "commit" function, and all the flush-type operations turn into a commit at the end of the day. , [see correction below] , , they all wait until the data has been confirmed written to the disk. If you perform one of these explicit flush operations, you aren't letting the disk cache do its job. These types of operations are necessary only if you're trying to main...
The contractually obligatory beeper, and the customers who demand them
One of the fun parts of meeting with other developers, either at conferences or on my self-funded book tour, is exchanging war stories. Here's one of the stories I've collected, from somebody describing a former company. As is customary, I've removed identifying information. One day, the engineering team were instructed that the team was being issued a beeper, and that a member of the engineering team had to be on call at all times. This new requirement was the handiwork of the sales team, who landed a big contract with a customer, but the customer insisted on a support contract which included the ability to t...
How do I customize the order of items in the All Programs section of the Start menu?
The items in the All Programs section of the Start menu are grouped into two sections, although there are no visible divider lines between them. We saw earlier that the Fast Items lost their special status in Windows Vista and are sorted with the regular items. Another change from Windows XP is the order of the remaining two groups: Windows XP put folders above non-folders, because that was the sort order imposed by the method so that folders sorted above files in regular Explorer windows. This deviation from standard sort order starting in Windows Vista was introduced because the guidan...
Was there really an Opera billboard outside Microsoft main campus?
Maybe somebody took a picture.c
What happens to a named object when all handles to it are closed?
A customer had a question about named kernel objects: I understand that handles in a process if leaked will be destroyed by the kernel when the process exits. My question would be around named objects. Would named objects hold their value indefinitely? If I run a small utility app to increment a named counting semaphore, the count of that named semaphore could be lost when that app exits? I would expect it to always hold its current value so that transactions across processes and across time could be held even if no process is holding on to it. When the last handle to a named kernel object (such as a na...