Archive for the ‘Uncategorized’ Category

Aeon Flux

My memories of the original Aeon Flux are, perhaps appropriately,
fragmentary. Back in the day I didn’t get MTV and in the end I think
I only saw two episodes all the way through. (Remember when MTV was
interesting?) In any case, I remember liking what I saw, so I was
looking forward to the film, although with some caution. After
hearing a bit about it, I entered the theater expecting only
disappointment.

The film itself is an unusual mix. It definitely has its bad
points, which I feel compelled to enumerate. Some of the dialog is
laughable. Stylistically it seems like it can’t decide between a
certain kind of Star Trekian futurism (people in subtly matching
outfits walking easily through crowded outdoor markets), smooth
concrete abstractionism (Flux’s apartment, seemingly located in a
scrubbed out sewer), something more baroque (the library, the
Relical), or something hyper-realistic (close-ups lit to show skin
texture, the unusual posters of the dictator).

Likewise it can’t decide what kind of an action film it wants to
be. The cutting is very choppy and the action scenes are consequently
difficult to follow. At times the settings seem to indicate a more
visually ambitious film is buried in the sub-liminal — the locations
chosen generally impressed me.

Despite its flaws this film did capture elements of the original.
The world is mysterious, post-Picardian Kafka (nicely captured in the
phrase “industrial virus”). The technology is alien and magical and
as viewers we often do not know whether some gadget is taken for
granted in this world where any object can have the function of any
other, where form and function are completely divorced. Perhaps we
are viewing ordinary things. Or perhaps Flux knows as little as we.

It brings to mind the Codex Seraphinianus, which in its own world
is most likely a perfectly ordinary book, no more exotic than an issue
of National Geographic.

The ending was a mild let-down, as were the moments when the film
devolved to mere action and the typical tropes of the genre.

I enjoyed this film quite a bit more than I expected to. In an
artistic sense I found it inspiring, similar to the way that reading a
story by Delany invariably makes me want to write.

C++ compilation

I’ve been spending a lot of time thinking about C and C++
development lately. In particular I’ve been thinking along the lines
of, “how can we make C++ development as easy as Java development?”.
This turns out to touch a lot of different things, and I’m going to
blog more fully about it later. Today I just wanted to share some
thought about one particular problem: building gcjx.

I wrote about this earlier, noting
the incredible performance difference between g++ and jikes
.
Today I went a little bit deeper and built gcjx with the
-ftime-report flag. Then I wrote a little perl script to
summarize the results (I’m only showing the top 4 here, the rest are
all 3% or less):

Pass User Time % Total
parser 113.62 44.6
name lookup 34.34 13.5
symout 26.59 10.4
tree gimplify 18.95 7.4

I think the underlying problem here is that each compilation of a
gcjx source file re-scans many of the gcjx headers and also a fair
chunk of libstdc++, which hugely inflates the amount of
work done. For instance, mangle.cc is a mere 386 lines
of code, but run it through cpp and out comes a whopping 51,997 lines.
Like most sane programs, gcjx doesn’t play odd cpp tricks like
including files multiple times; so much of this work is simply
redundant.

The fix here is to move away from purely textual preprocessing and
move to a more sophisticated model, one that eliminates redundant
work. This is actually not as hard as you might first believe. For
the most part it is an application of better data structures to the
problem, coupled with the observation that, since typically header
files do not interfere with each other via macro tricks, you can gain
efficiency by caching lookup contexts during preprocessing. Perhaps I
ought to write this up more fully; that is pretty sketchy.

I know of two attempts at this already. One is the gcc
compiler server branch
. Unfortunately this project seems to have
been canceled by Apple, as there has not been progress on it in quite
some time. There was little documentation for this project and, I
think, nobody outside Apple really understood what it was about back
when it was active.

The other project in this area is Doug Schaefer’s PDOM work in
the Eclipse CDT. Unfortunately this is for indexing only — as far as
I know there is no code generation planned. (Remedying this is one of
my major prescriptions for improving C++ tools… but you have to wait
for the bigger entry on this topic.)

gcjx generics milestone

Last week I got gcjx to successfully parse and analyze the
Classpath generics branch. I only needed a couple of hacks to get
there :-). More recently I fixed some of the remaining problems with
1.5 code generation — I added code to generate bridge methods and
handle enum-typed switches. Now I’m going to switch back to the tree
back end, with an eye toward merging gcjx to the trunk.

NetBeans

I’m going to go out of order a bit here and describe two different
NetBeans talks together, though they happened on different days. Then
I’ll use this as a place to discuss some interesting NetBeans-related
conversations and explorations.

Charlie Hunt gave a talk titled, “NetBeans: Pushing Java
Productivity”. (There’s that word again.) This talk was a run
through of all the new NetBeans features and some future plans. Tim
Boudreau gave a talk about Matisse and other things — this talk was
largely demos of some of the new things. I freely intermix stuff the
two of them said here.

The new NetBeans release includes Matisse (a Swing GUI builder),
new editor features for productivity, newly rewritten CVS support (no
SVN yet, but planned for the near future). There is now support for
JSF, Struts, and JBoss in the IDE — Eclipse probably lags a bit here.

This revision of NetBeans looks a lot like Eclipse. Astoundingly
so in some cases, for instance the editor window has a small vertical
pane on the right which represents errors and warnings, exactly the
way Eclipse does. I wondered whether NetBeans was copying Eclipse, or
whether both of the are copying some standard-but-unknown-to-me IDE
approach.

Bad News

First the bad news for NetBeans. In some important ways Eclipse
remains superior. NetBeans does not have an integrated compiler.
Instead it invokes ant. It does parse and understand a Java source
file when you open it — but this means that, unless you do a full
compilation, you won’t have a global view of all the errors in your
project. When you go to run your project, NetBeans does a real
compilation. Contrast this with Eclipse, where it compiles in the
background, has global knowledge of your program (and can do things
like mark up the project view to show which files have errors in them
— before the file is opened), and where running a test case doesn’t
mean that you have to wait for a rebuild. This is core stuff,
directly impacting your workflow, and Eclipse is just better.

I’m told a future NetBeans will integrate with the compiler better
(there is some JSR for the compiler API. This stuff scares me given
what it would imply for gcjx…).

Eclipse’s CVS support also looked better offhand, but I didn’t
play with NetBeans’ myself.

Tim and I had a long talk about Classpath, NetBeans, Eclipse,
Swing, and SWT. While I’m not really a fan of SWT’s implementation,
the simple fact is that it is open source and readily runnable with
gcj. On the other hand Swing requires a major development effort,
which we’re still undertaking. And while we definitely plan to be
able to run NetBeans, we’re not there yet. And in short — feature
comparisons aside (features are in constant flux anyway) — this is
why I’m an Eclipse user and promoter.

I think it would be perfectly fine — cool, even — to set up
Classpath and friends to build with NetBeans the same way I set them
up to build with Eclipse. I gave a quick try to this at the airport,
using a NetBeans CD conveniently handed out at the conference, but ran
aground on a quirk (NetBeans doesn’t like your source to appear in
. — which is where Classpath puts it). Bummer! (I
found a number of other oddities too, like the lack of a “Save As”
action — maybe I’ll be spending some quality time with their bugzilla
soon.

Also it strikes me that in some ways Emacs is still the state of
the art. For instance people gush endlessly about the “new” Mozilla
search “non-dialog” — umm, that is Emacs isearch. So, now NetBeans
has abbrevs… yay, color me unenthused that the IDEs are catching up
on basic editing skills. Ahh, I’m being excessively snarky.

Matisse

The bad news is pretty bad. However, the good news is also pretty
damn good. In fact the good things in NetBeans are just amazingly
awesome.

By which I mean, Matisse gives a really awesome demo. Matisse is
a Swing GUI builder that plugs in to NetBeans. It purports to let you
build cross-platform applications correctly. It comes with a new
layout manager called GroupLayout (which, it is claimed,
is open source, but I have not verified this) which handles all the
details, for instance this is where information about
platform-specific spacing differences is kept. It also has some nice
tricks like aligning font baselines even across different widget
types.

Matisse tries hard to make it easy to build sensible GUIs, but
doesn’t actually force you to. For instance, in the demo, as Tim
dragged UI elements around, guidelines would appear showing suggested
drop points. This kind of thing is very handy, he was able to create
new composite widgets with proper spacing and proper resize behavior
in just a couple of minutes.

I still think that Swing kind of looks like crap on Linux. It
should be indistinguishable from any other application, and
unfortunately that is not the case yet. This is something that
Classpath can, and should, solve.

Fun quote: “you can’t spend an hour on Matisse”. Meaning, it is
too easy to use to take up that much time.

Sharing

On stage Tim demoed something that I thought was really cool and
revolutionary. NetBeans has a built-in IM client, and Tim was talking
to a co-developer in the Czech Republic. Tim chose “share this
project” and, over IM, the code was transferred to his colleague, who
then proceeded to edit it — and the changes showed up instantly in
Tim’s workspace.

This is so damn cool. I’ve been wanting something like this for
quite a while… not every change is worth sending to version control,
and sometimes you really want to use the pair-programming style.
(Also it would be super great to be able to share a debug session, but
I don’t know if NetBeans can do that yet.) Anyway I’ve thought about
having this in Eclipse, but NetBeans is actually already there.
Amazing.

Currently you need an account on share.java.net to get this
functionality. That seems smart for them, in a building-a-portal way
— and sourceforge or savannah should offer IM service like this. In
combination with the Eclipse Mylar plugin this would be quite cool;
for instance open a project and be available for talking with other
developers from that project. They plan to look at a jxta-based
implementation soon, meaning the sharing could really be P2P. I think
this would be friendlier for users.

Eclipse is working on similar functionality as part of the ECF project. This is now
definitely on my must-examine list, not only for shared hacking on
Classpath, but also for integration with Medi8. Shared movie editing
seems like a cool idea.

Other NetBeans stuff

My notes say that Charlie’s talk was full of unsubtle anti-Eclipse
jabs. Which it was. Come on guys, rise above.

NetBeans has an ant debugger (nice idea, didn’t see a demo). It
has a PDE-like thing for writing NetBeans plugins (the demo here was
about the same as Bob’s, making me suspect that they both chose the
only easy thing). You can make rich client applications using the
NetBeans base (does Gnome have this yet? I think these days I would
probably pick Eclipse RCP as the base for a traditional-style
application). NetBeans makes it really easy to download and install
the latest LookingGlass. It seems to me that we could do this for all
of Fedora, by providing a way to say “I want package X”, and then
fetch the SRPM and turn it into an Eclipse project. Well, except for
the fact that most SRPMs are probably not really suitable for hacking
inside today’s Eclipse 🙁

You can set background wallpaper in NetBeans. This is useless but
they did ask, “Can Eclipse do this?”. Seriously, come on guys.

By the way, LookingGlass gives a really nice demo. Things whirl
and slide around, and pulse organically. But does it help my
productivity? Or just make me reach for the motion sickness pills?

Tim hinted at scriptable refactoring coming in NetBeans. Hmm,
sounds like something I wanted.

There is a J2ME plugin for NetBeans that allows debugging on the
actual device you are using — they’ve found the device emulators to
be somewhat flaky and so debugging on a live device is more useful.
This sounds pretty hand for folks in the J2ME space. Maybe I
misunderstood this though, since Michael Koch tells me that not many
devices actually support this.

Muito Sou Java

Geir talked again about Apache, Harmony, and Geronimo. It was
again basically the same talk, so I didn’t note much. He did say that
Intel’s contribution of the JCE framework (no providers, they use GNU
Crypto, Jessie, and Bouncy Castle for that) included 3000 test cases
— definitely need to investigate that for Mauve.

He also said that “Apache is not out to compete with anyone else”.
I don’t recall if this came from the Harmony part or the Geronimo part
of the talk. It seems to apply equally well to either. I’m not
really sure what this means, as in a way some kinds of competition are
inevitable and not contingent on our intentions. In the Classpath
world we’ve (for the most part) handled this by recognizing that,
while the VMs do compete in some ways, in general our interests — in
a solid, complete class library and in free Java implementations in
general — outweigh our differences. Start with that, work
together for a while, have a few beers and late night chats together,
and one day you wake up with real trust and a real community. (I know
Geir understands this in a deep way. This is for any journalists out
there looking for a controversy 🙂

One way not to compete would be to work harder to cooperate, i.e.,
move license harmony back to the front burner instead of the current
situation, which is that the majority of folks on both sides (me
included) are just hoping it will magically fix itself. Magical fixes
just don’t happen.

Max Rydahl Andersen, JBoss

Max is a Dane living in Switzerland. Sometime I wonder whether
giving these personal details of the speakers crosses some line of
etiquette. I do it just to personalize these writeups in a small way.

This was about Hibernate 3.1 — what’s next. My first note is
that his powerpoint presentation was cool, in that he could highlight
parts of a slide with a yellow highlighter (software) pen, which
marked up the slide as if it were an image (i.e., not restricted to
textual selections). I wonder what program that is.

So what is new? JBoss is writing NHibernate, for one thing. I
wonder whether stuff like this makes Sun nervous. Maybe not — the
crowd at this event was pretty rah-rah-Java; and just like at the
Denver JUG I didn’t find anybody planning to move development to .NET,
which rather surprised me (e.g., I talked to a guy from a Delphi shop
that is moving to Java — not C#).

I don’t know diddly about Hibernate and I didn’t take many notes
on it as a result. The Hibernate eclipse plugin that he demoed looks
nice, though I don’t recall why. And, he said on the Hibernate web
site there is a “help wanted” search you can do, to see how you can
help out. This struck me as a nice idea and I think for Classpath we
should either have an automated “FIXME finder”, or perhaps “stub
finder”. Or, change the cpbot to assign you a “FIXME” to fix on
request. In case you’re, like, bored or taskless or something. Ha,
ha.

Sun’s View of Open Source

Simon Phipps gave a nice presentation on Sun’s view of open
source. This covered a lot of ground, with a lot of ideas, and
unfortunately my notes on it are rather fragmentary since I was sleep
deprived. Bah.

Early in the talk he made a prediction, which is that due to Peter
Jackson’s engagement with the fans (the parallel to an open source
company is obvious — breaking down barriers between supplier and
customer, having a conversation instead of an ivory tower), King Kong
is going to make money. Hmm. I will make a counter prediction, which
is that since monster movies are intrinsically boring, and that since
we’re all deadly tired of remakes, it will not do very well. This
film, sorry Peter, is already on my must-miss list.

Simon talked about one important aspect of standards, which is
that standards mean substitutability. The idea here is that if there
is a governing standard then you can switch implementations with
little cost.

However, according to Simon, neither open source nor open
standards is enough. And, dammit, my notes are so vague here as to be
useless.

My recollection is that this was a somewhat pro-Java (there are
standards) and anti-Linux (LSB being what it is) approach. He didn’t
say what standards cover Open Solaris though :-). My notes say that
he did tout the Debian/Solaris project. That was interesting to me
since I thought there would be a licensing smackdown here. Maybe that
will come from the FSF instead. Simon also talked a lot about the
CIO’s point of view, which is super important if you’re delivering to
enterprise customers. And, he made the point that the needs of
development are not the same as the needs of deployment (I think
meaning something like, open source alone is great for development,
but freedom in deployment requires the substitutability delivered by
standards).

I felt bad that I didn’t take better notes. This was an important
talk. I disagreed with a lot of it; as I remember it many of the
assertions were a bit too binary, whereas in reality there is a
continuum of, say, compatibility even if standards are in force — a
quick survey of C++ compilers is instructive (Simon, I suspect, would
argue, correctly, that C++’s approach is a poor one and that
Java-style test compatibility kits are more useful). Anyway, it is
hard to express one’s disagreement cogently when one doesn’t even
remember the material. Sigh.

ObjectWeb Consortium

François Letellier gave a talk. He represents the ObjectWeb
Consortium, the makers of JoNAS. His talk was not very technical but
instead more economically focused. He was the only person at the
whole conference to mention the 4 Freedoms — bravo! And, any slide
about free software that mentions Nash equilibria and societal
externalities is cool by me. (Yes. Any slide.)

Once again though I fell down on the note-taking. He described
ObjectWeb’s approach as “open source with governance”. I think that
is pretty smart, as in general I prefer explicitness and transparency.
The GNU style (cf GCC) is more anarchic — there is governance but it
is often implicit, or largely embodied in tradition, or simply not
discussed much as if it were my crazy aunt who I keep locked in the
attic.

He said the software industry can best be viewed as competing
networks of firms. Good observation.

Update

Graydon pointed out I inverted the sense of an important clause.
Fixed.

Floyd Marinescu

Floyd is a
friendly guy, from Canada, formerly of theserverside.com, who is going
to launch his own site soon. It sounds quite good; I’m looking
forward to it and I’ll post about it when it is live.

Unfortunately I missed the first part of Floyd’s talk about trends
in Java, since I got locked in a bathroom. You’d think this would be
hilarious, but really it was just boring and mildly irritating. One
of the other guys called Bruno on his cell phone and after a short
wait maintenance physically removed the lock.

Floyd had many examples of AOP to present. I dislike AOP quite a
bit, since I think it violates the heuristic that says that it is
better to have local constructs be lexically signified. (There. I
put that in the most obscure and highfalutin way I could think of. Am
I pomo yet?)

I didn’t write down the examples but one idea was architectural
enforcement — where the AOP insertions can check that your code is
following some rule supplied by the framework. But see what I mean
here? It would be better to enforce these rules statically, using
compiler-level tools (perhaps in addition to dynamic checks if that is
really needed — though these too should, ideally, be done in a way
akin to verification).

About 15% of the audience planned to use AOP, and Floyd said this
was about what he found globally. Floyd is a gold mine of this sort
of information.

Dependency injection is a must-learn trend according to him. So
are annotations, everybody likes them. (C#’s influence on the
language is easily felt, but I suppose the web services guys would
have pushed for this regardless — look at xdoclet to see why.) I’m
probably going to use annotations for the next generation of GDirect,
for what it’s worth, as it is a natural fit. Floyd had a nice list of
known best practices for annotation use — most of these can be
thought up pretty easily, but it is smart to just distribute the
information like this, I think, to try to get good penetration of the
ideas early on.

He said that many shops are moving back to OO design and POJO
applications. I’m not really a J2EE type guy but I gather that this
is a change from how web applications are written today. The new
buzzword here is “domain driven design”, which really just means
“OO”. Buzzword proliferation is a disease and the UN ought to combat
it.

Scripting is a good “new” trend, with Groovy soaking up most of
the press gravy lately. Both NetBeans and Eclipse folks are
investigating scripting the IDE. Got Emacs? Though one nice thing is
that since the JRE provides a consistent platform, the scripting
language choices matter a lot less; you can pretty much write
scripting goo in any language you prefer.

“Domain specific languages” is also a new trend, just like it has
been for the last 10 years. “Software engineering” is the endless
renaming of existing ideas, and the history of it is largely the story
of IBM introducing the same ideas that it likes, over and over, with
different names each time, until they finally take hold.

Floyd also talked about Ruby on Rails (as did many here, mostly to
argue against it), and AJAX. (Ean pointed out that Project
Blackwood
, which got little uptake, is really just AJAX for Java
applets. This seems like a cool thing to revive.) Running out of
time he mentioned “SOA” (service oriented architecture). I didn’t
know what this meant, but this
explanation
seemed relatively clear.

To sum up he hit on something that was repeated a couple of times,
namely the importance of open source Java for emerging economies like
Brazil. “Emerging” is the official phrase — I heard it 2-3 times. I
think “developing” is reserved for poorer places.

I was glad to hear this from someone! There’s a quote I like
which goes something like: “Philosophy is the middle ground between
science and religion, open to attack from both sides”. This describes
work on gcj perfectly — the free software world and the Java world
are similarly unenchanted. The Brazilian Java community, though,
really gets what we’re about, and why we’re important, and this is why
I was so happy to come here to talk. The point here is, we have a lot
of free infrastructure below the JVM, and we have a lot of free
applications above the JVM — but that crucial middle layer is a
proprietary zone with all the attendant pitfalls. Our vision is to
change this, and we’re actually quite close to that.

Sou Java

A couple days later the Sou Java event started. This was held
only in Sao Paulo. The first talk was given by Robert Brewin, a
Distinguished Engineer at Sun. He is very tall, and one supposes this
is not unrelated to his lofty position. By contrast I suspect those
of us in the audience felt, suddenly, that we were Undistinguished.
He’s also an avid surfer.

His talk had the unwieldy title, “Java and the Developer, Platform
and Tools, Trends and Futures” and started with a joke about cariocas
(the Brazilian word for someone from Rio).

Some interesting facts: Brazil is number 4 in the world for
developer population, after the US, India, and the EU considered as a
whole. Also, there are apparently 4.5 million Java developers. (Now
one feels for Onno’s plight, as his job, I think, is to grow this to
some absurd number like 20 million.)

His talk is what I described in my notes as “a typical OSS talk”,
which is somewhat ironic considering that the JDK is not OSS. The
fact is, the folks I meet from Sun all understand OSS fairly well, and
sympathize, and even work on it in various ways (make no mistake
slashdotters — Sun is a major open source supporter), but also often
hold on to a fear about potential platform forks by unfriendly
entities (read: Microsoft). Personally I think these fears are
somewhat outdated, given that .NET exists, but nevertheless I can
sympathize. The existence of Classpath does complicate the picture
though, and my guess is that in this instance Sun will follow the
time-honored tradition of open-sourcing projects only once they are
already obsolete. Good news for Classpath, I suppose, but another sad
example of the inefficiency and short-sightedness of the system.

The various Sun communities look great on paper — big numbers,
like 7 million NetBeans downloads. More on NetBeans later, there were
many talks about it.

On to trends… Sun’s general trend is toward OSS and community.
Cool beans. This is exemplified by Open Solaris, which came up a
number of times during the week. Fun fact: apparently it took 5 years
and was quite expensive to turn Solaris into an OSS project.
Apparently they had to do a full code audit and contact many different
organizations to get a grip on the IP issues. So, this is another
area where OSS rocks; GNU projects basically all have a better paper
trail than this.

A Few Notes on Productivity

One point he made is that the complexity of programs is increasing
(which I agree is indisputably true) and that past metrics of programs
don’t apply. He said that nowadays programmers don’t write systems,
but instead integrate sets of systems. (This is true in the Java
world, the C world is still more like 1995, and the C++ world has in
some ways taken a fatal tack toward the deeper past.)

He also said that lack of productivity is a major concern. A few
talks echoed this concern over the next days, but I was struck by the
fact that nobody made an attempt to define what productivity actually
was.

My perspective is that productivity is about maximizing the amount
of functional, bug-free code that can be written in a given amount of
development time. Furthermore, a real measure of productivity would
recognize that more time is spent in maintenance than in development,
and skew results accordingly. From this perspective I think it
becomes pretty clear that some of Java’s design goals are on target,
particularly, “reading is more important than writing”. (And honestly
on this basis I have misgivings about generics… they are clearer in
some situations, and have caught a few buglets in Classpath, but are
actually quite complex for what they provide.)

Anyway, my thinking in this area has led me to conclude that what
Java needs is, most likely, features adding more quality assurance to
the language. Generally I translate this into Eiffel-like code
invariants to better support safe derivations, and perhaps some kind
of hygienic macro support to allow things like transactions and other
higher-level application-specific modifications of control flow while
preserving “lexicalness”. (This can be done currently using anonymous
classes, but the effect is rather clunky.) On the topic of macros
though it is generally agreed that I am a nut.

Back to the Party

Bob then talked about handling complexity, for which his remedy is
sensible standards and sensible simplifications. Also he thinks that
ease of development is important, meaning that attention must be paid
to the entire application lifecycle (agreed; and both Eclipse and
NetBeans are still missing important parts of this; for example
neither has a built-in bug tracking interface, let alone more complex
things like making releases or tracking cross-release API
compatibility). He says we shouldn’t consider just “tools” but should
also look at the platform and the language. To me this is a natural
continuation of the Java approach, which is to try to consider the
system as a whole (and which explains why the compiler and the library
are not fully separable).

Another remedy for complexity is focus, namely being able to
orient to the task at hand and avoid noise. In the Eclipse world,
Mylar is exploring this area.

He made a claim, without supporting evidence, that the new
enum support helps productivity. It probably does reduce
bug rates by some small degree, but I would say little given typical
Java coding practices. He also gave what my notes describe as a
“bogus example” of using annotations — annotations are cool and do
help, but I saw some disturbing evidence at this conference that
future Java programs, particularly in the J2EE domain, are going to
end up looking like “@ soup”.

Another quote: “applications can be too complex for most
developers”. I suppose that can be true. At our airport meeting,
Simon said that in his opinion programmers do not really use
programming languages, but rather use the associated libraries.
There’s truth in this and Bob’s point may be that a typical
application can provide a bewilderingly large API profile, with
overlapping abstractions, complicated deployment schemes, and the
like. All true.

In this vein, we’ve known for a long time that personality is an
important component of programming in most environments, likewise the
social organization of teams and corporations, and the emotional
skills of managers. There is a lot of room for improvement in this
area.

But, these talks are more narrowly construed and so Bob didn’t
dive into a psychosocial analysis of the typical Java hacker. Instead
he then gave a demo of writing a NetBeans plugin. NetBeans is coming
along well. I’ll post a full entry on it soon.

Brazil

I’m back from Brazil. This was a fairly bizarre experience — Sao
Paulo is enormously big (20 million people) and also the world’s best
argument for zoning laws; Ean Schuessler is a virtuoso of weird on the
level of Survival Research Labs; and for some unfathomable reason
Bruno refers to me only by my last name, which would seem military if
the city and its inhabitants weren’t so militantly disorganized.

Over the next few days I’ll write up my notes from this trip.
Well, the ones I can understand (I wonder what “The Big B! And on!”
might mean… all I can recall is that it is something snarky), and
the ones that are suitable for public consumption.

The chaos — and I don’t want to overemphasize this, as it was not
inconvenient and in fact lovable in a certain way — began as I got
through customs. Instead of seeing Bruno (or one of his countless
friends who he got to help him with the conference), instead I was
greeted by Simon Phipps holding a sign with my name on it. Simon is a
great talker and we sat at a cafe in the airport for a couple of hours
and had the first of the many interesting conversations I would have
over the next week.

Also I wanted to mention that Bruno and the rest of the Sou Java
crew did an excellent job with this conference. It was very well-run,
and both the speakers and the audience were excellent. Also the
organizers went far beyond the call to make sure we had an easy time
getting around in Sao Paulo.

Maratona

The first event was called the “Maratona 4 Java”. It took place
in a number of different cities around Brazil (and in Austin, TX). I
stayed in Sao Paulo for this, though. For this we went to a
university, seemingly hours away, which is big enough to be considered
its own city within SP.

Geir talked first, about Harmony of course. I didn’t take too
many notes on this, as it largely seemed to be the same talk he gave
at OSCON. However he did mention that he now works at Intel. And, he
mentioned the code contributions Harmony has gotten since OSCON;
namely some core class library code from IBM, some of the security
code from Intel, and various other bits. I was a bit surprised to
find that Tcl is now an Apache project. Also he mentioned about the
idea that it would be cool if Sun donated code to Harmony.

Flavio Bergamaschi

Flavio Bergamaschi from IBM gave a talk called “The IBM
Contribution to Apache Harmony”. Flavio is a Brazilian who lives in
England and seems to be a kind of senior engineer — one recurring
theme for me this week was that these larger companies have relatively
rich internal career paths, and many of the participants here had
“juice” but were not in management. I suppose that is one of the
benefits offered by employment at an enormous company like IBM or Sun.
As I (gracefully) age I find I think more and more about what my job
might look like in ten years, or twenty.

Flavio is super friendly and knowledgeable. He spoke in Portugese
so I mostly took notes based on his slides… which were quite good —
next time I give a talk I plan to make nice graphics and stuff like
that. Up until now I’ve been embarrassingly low-touch.

One note I have is, “functional units allows separable life-cycle
and trivial switching implementation”. I’m not totally sure what this
refers to, but I think to this idea that keeps coming up on the
Harmony list about managing the core classes via some OSGi-based class
loader scheme. I did finally think of a concrete benefit this could
provide — if you have a core library that depends on something like,
say, Apache’s commons-logging (think mx4j), you could use that while
not exposing its existence on the boot class path to application
classes (which is critical). Given that we haven’t actually run into
this in practice, though, I still suspect this approach is a lot of
complexity for little gain. I find the posts on the Harmony list
about this to be quite vague… be concrete, people, not abstract!

IBM’s medium term vision for Harmony is: run the Eclipse compiler
on it by 3Q05 (this works with the IBM Harmony contribution if you use
the closed-source VM they provided), run Eclipse and Derby by 4Q05,
and run Geronimo by 3Q06. I think gcj can do all of that today :-).
This is an aggressive schedule for a new project.

I took a quick stroll through IBM’s code contribution a few weeks
back. It includes a bunch of NIO-based character set encoders;
Classpath largely relies on iconv, so this is probably
worth picking up. (Though for gcj, it is less clear… one point I
make in my talks is that with gcj and Classpath, we efficiently reuse
a lot of other free software, which is good at development time and
good at runtime.)

Me

I gave a talk next, which was another revamp of a fairly standard
gcj talk I give — it covers our goals, what we can do, some
information about the implementation and the status, and a short demo
(in this case of Eclipse and of AWT). My notes on this are mostly
about my emotional state, as I’ve found that to be the most important
part of a presentation (once I realized that I have already mastered
the actual content). I thought it went pretty well overall.

In the question section, Geir suggested we revamp gcj-jit to work
properly. He also suggested that we hook into class loaders to
compile entire jars at once. We’ve discussed this before on the gcj
list, and unfortunately I think that, first of all, it isn’t trivial
as many class loaders do a lot of work by hand (I think the OSGi
loaders do this) — meaning that we would have to break our rule about
not requiring application-level changes. Also, compiling an entire
jar at once is notably unfriendly to the system (though we could use
aot-compile-rpm to work around this).

Evolving the Java Language

Next up were a couple of guys who, I think, came from the local
university. They had a presentation on evolving the Java language
that they got from Sun. I only read the slides of this talk as it was
given in Portugese.

The slides were quite nice though. They touched on a number of
things I think about in the isolation tank in the basement bathroom.
So, for instance, the slide about Java Principles said that Java is
designed with the idea that reading code is more important than
writing it, that simplicity matters (having a clear semantic model,
and having programs mean the same thing everywhere — in contrast to C
and C++). They are most interested in new features that improve
developer productivity while preserving simplicity and clarity; though
the slides didn’t indicate how the language designers go about
measuring this. Language design remains unscientific in this respect.

There was some mention of putting XML support directly in the
language, but they skipped this slide too quickly. I’ve heard of this
before but never really looked into it; hopefully I’ll pass on gcjx
maintainership before this, whatever it is, becomes real.

There was also a list of rejected features, which includes just
about everything that I hear requests for — multiple inheritance,
operator overloading, AOP, continuations, preprocessing or macros,
multiple dispatch, and multiple return values.

One point that was made is that Java is also a platform. Folks
can write their own languages which implement some of these features
and simply compile to the JVM. This won’t help with things like
continuations though, which I think would require VM support… I
asked about that but didn’t get a really good answer.

It sounds like javascript and/or groovy will be part of the
official platform soon, like in Mustang. We’ll name the next
generation VM “Yikes” in honor of this.

Update

Mark pointed out that I misspelled everybody’s name. I fixed
that.

Cacao and Eclipse

Today, for no readily discernible reason, I set up Cacao with Eclipse project files.
This gives another easy way to hack on Classpath — you can check out
Classpath, then check out Cacao, and as soon as it is done building
(this happens automatically) you will have a fully working Classpath
development environment. Changes to Classpath will be immediately
available to Cacao, so your development cycle will be nicely short.

Some folks (hi Mark) report that they can’t get the auto-building
to work in Eclipse, but it always works for me. I can go from zero to
a fully working Classpath development environment in about 15
minutes… maybe we’re using different versions of Eclipse or
something.

Thread Patterns

This
blog entry
is a must-read for anybody on the GCC lists. I wonder
whether the k00ks know who they are. Or, worse, if I am one 😉

Snow

First snow here in Boulder. Incredibly late this year… a few
storms have come by but they’ve hopped over us and hit Denver instead.

Gdb Stuff

This
gdb patch
from Michael Snyder is pretty cool. It adds new
checkpoint and restart commands to gdb; the
former is used to save a copy of the debuggee’s state at the current
moment, and the latter is used to resume debugging at the saved point.
The implementation is nicely simple — make the inferior program fork
and just let it hang around until we’re ready to use it. This
functionality seems pretty useful; I often will do multiple debug
sessions starting at the same point, and this is a way to avoid
lengthy startup procedures. Maybe it needs a
restart-checkpoint command, which brings a new copy of
the inferior to the foreground, leaving a pristine copy waiting for
future restarts.

Also, any patch that adds a variable named
forky_forky can’t be bad.

This isn’t the only potentially cool thing going on in gdb-land.
Over the last few months there has also been a fair amount of talk
about debugging in reverse (here’s
one thread
). This is one of those features I’ve wanted for
years…