Who Will Edit the Editors?
I am often asked to review papers that are written in a language
only superficially resembling English.
In a few cases the writing is so confused that I return the
manuscript, asking for it to be edited by a native speaker of English.
I realize that writing proper English is an additional
hurdle for, possibly brilliant, scientists who are not
native speakers of English, and
I often wondered how authors could address this problem.
Apparently, there are companies that will edit scientific papers
for a modest fee.
Continue reading "Who Will Edit the Editors?"
If STL Had Been Designed by a Committee
I've been reading on XML schema, and it's embarrassingly obvious
that it has been designed by a committee.
Continue reading "If STL Had Been Designed by a Committee"
A Clash of Two Cultures
I dug the following gem from the Usenix
HotOS X Conference
Panel titled "Do we work within existing frameworks or start from scratch?",
summarized by Prashanth Bungale.
Continue reading "A Clash of Two Cultures"
How to Sort Three Numbers
Quick: how do you sort three numbers in ascending order?
Continue reading "How to Sort Three Numbers"
Supporting Java's Foreach Construct
Java 1.5 supports a new
construct for iterating over collections.
The construct can be used on arrays and on all classes in Java's Collection
I searched the internet for an example on how to make my own
classes iterable with this construct, but could not find an example.
Continue reading "Supporting Java's Foreach Construct"
US Military Removes Word Documents from the Web?
On August 25th 2004 the comp.risks forum
run an article I submitted
regarding the large number of Microsoft Word documents available
on US milatary sites (sites in the .mil domain) through Google
(23.50 "U.S. military sites offer a quarter million Microsoft Word documents").
The article documented how such documents could lead to the leakage
of confidential data.
A week later I setup a script to watch the number of Word documents
available through Google searches
to see if and when the military would recognise the threat those
documents posed and remove them.
Continue reading "US Military Removes Word Documents from the Web?"
Working with Unix Tools
A successful [software] tool is one that was used to do something undreamed of by its author.
— Stephen C. Johnson
Line-oriented textual data streams are the lowest useful common denominator for a lot of data that passes through our hands. Such streams can be used to represent program source code, web server log data, version control history, file lists, symbol tables, archive contents, error messages, profiling data, and so on. For many routine, everyday tasks, we might be tempted to process the data using a Swiss army knife scripting language, like Perl, Python, or Ruby. However, to do that we often need to write a small, self-contained program and save it into a file. By that point we've lost interest in the task, and end-up doing the work manually, if at all. Often, a more effective approach is to combine programs of the Unix toolchest into a short and sweet pipeline that we can run from our shell's command prompt. With the modern shell command-line editing facilities we can build our command bit by bit, until it molds into exactly the form that suits us. Nowadays, the original Unix tools are available on many different systems, like GNU/Linux, Mac OS X, and Microsoft Windows, so there's no reason why you shouldn't add this approach to your arsenal.
Continue reading "Working with Unix Tools"
Human Thought and the Design of Computers
Peter J. Denning
wrote an excellent article titled
"The Locality Principle"
in the July 2005 issue of the Communications of the ACM.
The article explained the story behind the
locality of reference, a fundamental principle of computing with many applications.
that appeared in the October issue of the same magazine I commented:
Peter J. Denning's "The Profession of IT" column ("The Locality Principle," July 2005) invoked an anthropomorphic explanation for the prevalence of the locality principle in computational systems, observing that humans gather the most useful objects close around them to minimize the time and work required for their use, and that we've transferred these behaviors into the computational systems we design.
A more intellectually satisfying explanation might be that we are dealing with two parallel and independent evolutionary design paths. Trading some expensive high-quality space (fast memory) in order to gain time performance is a sound engineering decision. It is therefore likely that evolution first adapted the human brain by endowing it with limited but versatile short-term memory and large long-term memory structure that exhibits behavior similar to caching.
Millennia later, we make similar design decisions when building computing systems.
The comment triggered an email exchange with Phillip G. Armour
It was one of the most intellectually satisfying email exchanges I've ever had, and I am reproducing it here, with his kind permission.
Continue reading "Human Thought and the Design of Computers"
MIT's $100 Laptop
The MIT Media Lab is working on a research initiative to develop
a $100 laptop.
This will be distributed through governments to schools to
help the education of the world's students.
These are my notes from a talk
Director of Computing at the MIT Media Lab
gave on the subject, at an event organized by the
Netmode Laboratory .
Continue reading "MIT's $100 Laptop"
Hard Disk Failure
I tell everybody that the question is not whether your hard drive
will fail, but when it will fail.
My laptop's drive started emmitting a loud grinding sound last Saturday.
Continue reading "Hard Disk Failure"
The Other Side of Digital Preservation
We often grumble that digital preservation is risky, and that
modern storage technologies and file formats quickly become outdated
destroying the record of our past.
What we don't appear to appreciate is how much more data we are
able to preserve, thanks to digital technologies.
Continue reading "The Other Side of Digital Preservation"
Slashdot Story: The Future of Windows Software Distribution
Earlier today I posted on Slashdot
describing Microsoft's new third-party software distribution approach.
Continue reading "Slashdot Story: The Future of Windows Software Distribution"
The inclined panel is indeed a computer screen,
and, of course, it is not working.
Another, more reliable, technology has prevailed.
Continue reading "Information Kiosk"
Preparing for the Exams
The (retake) exam period has started.
At the metro the passenger sitting opposite me is obviously a student
frantically sorting the cards containing a 6%-reduced photocopy of her forensic
Continue reading "Preparing for the Exams"
Version Control Talk Demystified
One indication of the importance an
endeavor has in our lives is the vocabulary associated with it. If developers employ a tool or a method,
inevitably they will come up with words to describe their corresponding work in
an accurate and concise way. I recently
heard a colleague describe version control systems (also formally known as
configuration management tools) as boring. I hope that this dictionary
will dispel this myth by documenting a rich technical and social
vocabulary. If you donít work with a
VCS I believe this list will give you plenty of reasons to look at what these
systems can do for you and your projects. On the other hand, if you already use a VCS I hope you will find ideas
on how to use it more productively and how to improve your configuration management
process. And, no matter to which group
you belong to, I am sure youíll find here some new words worth knowing.
Continue reading "Version Control Talk Demystified"
Version Control Systems
A source code control system [is] a giant UNDO key—a project wide time machine.
— A. Hunt and D. Thomas
Sane programmers don't write production code without the help of an editor and an interpreter or a compiler, yet I've seen many software projects limping along without using a version control system. We can explain this contrast if we think in terms of the increased startup costs and the delayed gratification associated with the adoption of a VCS. We humans typically discount the future, and therefore implementing version control in a project appears to be a fight against the human nature. It is true that you can't beat the productivity boost that compilers and editors have provided us, but four decades after punched card programming in assembly language has gone out of fashion we must look elsewhere to reap our next gains in efficiency. And if you or your project is not using a VCS, adopting one may well be the single most important improvement you can undertake.
Continue reading "Version Control Systems"
Everything Old is New Again
In 1984 the new kid on the block was Borland's Sidekick.
A terminate and stay resident (TSR) program for MS-DOS,
it would run in the background, and when it detected
the two shift keys being pressed it would overlay the
(then character) screen with a calculator, a notepad,
a calendar, a dialer or an ASCII table.
Continue reading "Everything Old is New Again"
C++0X Enhancement: Rational Metaprogramming
In a recent article
presented the evolution of C++ toward the 0X standard, and asked the C++
community for ideas regarding C++ enhancements.
This is a proposal to add to C++ support for rational metaprogramming.
Continue reading "C++0X Enhancement: Rational Metaprogramming"
GCC Obfuscated Code
For years I've struggled to understand the
GNU compiler collection internals,
I am ashamed to say, without much success.
I always thought that the subject was intrinsically too complicated
for me, but after struggling to understand a two line gcc
code snippet of a fairly simple operation for more than two minutes,
I realized that the code style may have something to do with my problems.
Continue reading "GCC Obfuscated Code"
C++0X Enhancement: Packaged Libraries
In a recent article
presented the evolution of C++ toward the 0X standard, and asked the C++
community for ideas regarding C++ enhancements.
This is a proposal to add to C++ support for using packaged libraries,
and a standardizing a library distribution format.
Continue reading "C++0X Enhancement: Packaged Libraries"
Tool Writing: A Forgotten Art?
Merely adding features does not make it easier for users to do things—it just makes the manual thicker. The right solution in the right place is always more effective than haphazard hacking.
— Brian W. Kernighan and Rob Pike
In 1994 Chidamber and Kemerer defined a set of six simple metrics for object-oriented programs. Although the number of object-oriented metrics swelled to above 300 in the years that followed, I had a case where I preferred to use the original classic metric set for clarity, consistency, and simplicity. Surprisingly, none of the six open-source tools I found and tried to use fitted the bill. Most tools calculated only a subset of the six metrics, some required tweaking to make them compile, others had very specific dependencies on other projects (for example Eclipse), while others were horrendously inefficient. Although none of the tools I surveyed managed to calculate correctly the six classic Chidamber and Kemerer metrics in a straightforward way, most of them included numerous bells and whistles, such as graphical interfaces, XML output, and bindings to tools like ant and Eclipse.
Continue reading "Tool Writing: A Forgotten Art?"
XML Abstraction at the Wrong Level
Over the last month I've encountered two applications
that use XML at the wrong level of abstraction.
Instead of tailoring the schema to their needs, they
use a very abstract schema, and encode their elements
at a meta level within the XML data.
This approach hinders the verification and manipulation of the corresponding
Continue reading "XML Abstraction at the Wrong Level"
An Open Letter to a Copy-Editor
Copy-editors perform a valuable service.
They take prose that is often rough and unfinished, and
massage it into a professional document.
Unfortunately, sometimes copy editing can go to far
and distort the meaning, especially in technical writing.
Also, my feeling is that across the across-the-board copy editing
performed by many publications results in writing whose language
is uniformly polished, and, yes, bland.
Think of what would happen if the writings of Hemmingway got
While I consider my writing at least five leagues below that level,
I prefer to learn my own way toward perfection, than to battle
with corrections that sometimes change the meaning of what
I write in treacherous ways.
Continue reading "An Open Letter to a Copy-Editor"
Today's Dynamic is Tomorrow's Static
Today at the IEEE Software's
editorial and advisory board
meeting, the issue of service-oriented architectures came up.
Robert Glass wondered whether this was the upcoming fad,
following structured programming and object-oriented programming,
to which Stan Rifkin replied that service-oriented architectures
are a lot more dynamic.
Interestingly, the previous approaches, which we today consider as
static, were also thought-off as dynamic in their day.
Continue reading "Today's Dynamic is Tomorrow's Static"
Cats and Cigarette Lighters
On April 14th, the US Transportation Security Administration
started enforcing a new ban on cigarette lighters.
A month later,
I saw the corresponding announcement posted on a check-in desk
at the Samos international airport.
At the same airport I also saw a free-roaming cat getting its food delivered
directly on the tarmac.
I entered my flight feeling a lot safer.
Continue reading "Cats and Cigarette Lighters"
Warum einfach, wenns auch kompliziert geht?
(Why make it simple, when you can also make it complicated?)
Consider the task of associating code with specific data
Using a multi-way conditional can be error-prone, because
the data values become separated by the code.
It can also be inefficient in the cases where we have to use cascading
Continue reading "Warum einfach, wenns auch kompliziert geht?"
else if statements, instead of a
which the compiler can optimize into a hash table.
In C I would use an array containing values and function pointers.
My understanding is that the Java approach involves using the
Strategy pattern: a separate class for each case,
and an interface "to rule them all".
Ordnung muss sein
A free-form translation of the above German phrase (orderliness must exist)
would be that orderliness is not negotiable.
In the domain of information technology I find this motto particularly
Continue reading "Ordnung muss sein"
Google's Web Accelerator as a P2P CDN
I admire Google's guts in deploying their
Proposing to act as an intermediary for the whole planet's web
traffic takes a lot of courage and a certain amount of audacity.
Interestingly, the system's design can be quite scalable,
through the use of peer-to-peer and personalization technology.
Continue reading "Google's Web Accelerator as a P2P CDN"
Java Makes Scripting Languages Irrelevant?
Simplicity does not precede complexity, but follows it.
— Alan J. Perlis
In computing we often solve a complex problem by adding another level of indirection. As an example, on Unix file systems an index node, or inode, data structure allows files to be allocated concurrently and sparsely, and yet still provide an efficient random access capability. When we want to customize large and complex systems or express fluid and rapidly changing requirements a common tool we employ is to add a scripting layer on top of the corresponding system. An early instance of this approach was employed in Dan Murphy's TECO editor developed on the DEC PDP-1 computer in 1962–63: its command language also doubled as an arcane (to put it politely) macro language.
Continue reading "Java Makes Scripting Languages Irrelevant?"
Solving Singh's Substitution Cipher
Many of us enjoy playing with encryption algorithms.
Simon Singh, before a book promotion trip to Greece,
published a "substitution cipher with a twist".
I would consider solving a substitution cipher aimed
at the general public unfair, but the "twist" made me curious.
Continue reading "Solving Singh's Substitution Cipher"
A Pipe Namespace in the Portal Filesystem
The portal filesystem allows a daemon running as a userland program
to pass descriptors to processes that open files belonging to its
It has been part of the *BSD operating systems since 4.4 BSD.
I recently added a pipe namespace to its FreeBSD implementation.
This allows us to
perform scatter gather operations without using temporary files,
create non-linear pipelines, and
implement file views using symbolic links.
Continue reading "A Pipe Namespace in the Portal Filesystem"
Vatican's Prescient Web Masters
The Vacancy of the Apostolic See web page appears to have been prepared one day BEFORE the Pope's death.
Continue reading "Vatican's Prescient Web Masters"
I have updated the UMLGraph program to
run under Java 1.5.
Continue reading "UMLGraph Update"
A Plea for Usability Design in Children's Electronic Toys
I am not particularly fond of children's electronic toys,
but they constantly arrive at home as presents,
and they also attract the children's attention.
Unfortunately, the usability aspects of most electronic toys for toddlers
and children appear to be ignoring important and well-established
principles of user interface design.
Continue reading "A Plea for Usability Design in Children's Electronic Toys"
Self-Healing Systems Will Age
A number of researchers are advocating the adoption of self-healing
approaches as a way to create more robust systems.
They suggest to copy a page from the book of life, where organisms
with a self-healing capability can survive numerous mishaps and accidents.
However, biological systems have another property, which I believe
is associated with their ability to heal themselves: ageing, and,
Continue reading "Self-Healing Systems Will Age"
Machines should work. People should think.
— Richard Hamming
Continue reading "Dear Editor"
I know that you are nowadays often taken for granted, and that many programmers consider you a relic of an older age. Yet, programmers continue to spend an inordinate amount of time with you, and often listen to your advice. As you have no doubt observed I am often mistreated; in this letter I have written my most common grievances hoping you can convince them programmers to behave better toward me in the future.
XML Versus Text Files
package dependency analyzer can output its results
either as XML or as plain text.
Instead of using the XML output,
I found myself processing the text output using awk.
Am I becoming tied to old-world thinking,
or are text files easier to process?
Continue reading "XML Versus Text Files"
The Efficiency of Java and C++, Revisited
A number of people worked on replicating the results and optimizing
the programs I listed in my earlier blog entry.
Continue reading "The Efficiency of Java and C++, Revisited"
An Open Source Java Metrics Toolset Is Hard to Find
I spent many hours looking for a stand-alone open source metrics toolset
for Java programs.
Unfortunately, I was not able to find a single tool that would
fit my (relatively modest) requiremets.
Continue reading "An Open Source Java Metrics Toolset Is Hard to Find"
The Efficiency of Java and C++
I seem to have trouble convincing my neo-Turk students that Java's design makes
it inherently less efficient than C++.
The arguments often and up in an exchange of comments like:
Continue reading "The Efficiency of Java and C++"
— This (micro) benchmark executes with the same speed when written in Java and C.
— Yes, but a realistic application, like Eclipse takes ages to start up.
— You are only complaining about the cost of the runtime startup
costs and JIT compilation, which are quickly amortized, and, anyway,
Eclipse offers many more features than other IDEs.
and so on.
I therefore wrote a small program to demonstrate the exact problems of
Java's design decisions.
Macro-based Substitutions in Source Code
A friends asks:
"How can one easily replace a method call (which can contain
arguments with brackets in its invocation code) with a simple
Continue reading "Macro-based Substitutions in Source Code"
Maintainability of the FreeBSD System
Last November Ioannis Samoladas and his colleagues published an article
in the Communications of the ACM  that compared the maintainability
of open-source versus-closed source projects.
I applied the maintainability index  they used on the FreeBSD source
repository following the code's maintainability over time, and comparing
the maintainability of different modules.
Here are the results.
Continue reading "Maintainability of the FreeBSD System"
Java: the New Straightjacket
I first learned to program on a home computer in Basic. At first
it was fun, but after a point it became frustrating, when I realized
that I was living inside a walled garden. Many interesting programs,
such as those interfacing with the display controller, simply could
not be written in standard Basic. Luckily, this limitation forced me
to move to Pascal, assembly code, and C.
Continue reading "Java: the New Straightjacket"
The Tools at Hand
The tools we use have a profound (and devious!) influence on our thinking habits, and, therefore, on our thinking abilities.
— Edsger W. Dijkstra
With a shovel excavator a single operator can effortlessly move 720 tons of earth with a single movement; a VLSI fabrication plant allows a designer to create elaborate sub-micron structures. Without tools the thousands employed in a car factory are nothing, with tools they can assemble a car in 18 effort hours. Sometimes, tools can even subsume the importance of their operators. The violinist Ivry Gitlis, considered one of the most talented musicians of his generation, said of his Stradivarius: "I have a violin that was born in 1713. I don't consider it my violin. Rather, I am its violinist; I am passing though its life." Tools are clearly an important and defining element of any profession and activity: tools help us move boulders and atoms, tools help us reach the Moon and our soul.
Continue reading "The Tools at Hand"