Thursday, April 17, 2008

Falling Slowly

Falling Slowly, performed by Glen Hansard and Markéta Irglová in the movie Once, is the recent Oscar winner, the Academy Award for Best Original Song.
I don't know you
But I want you
All the more for that
Words fall through me
And always fool me
And I can't react
And games that never amount
To more than they're meant
Will play themselves out

Take this sinking boat and point it home
We've still got time
Raise your hopeful voice you have a choice
You've made it now

Falling slowly, eyes that know me
And I can't go back
Moods that take me and erase me
And I'm painted black
You have suffered enough
And warred with yourself
It's time that you won

Falling slowly sing your melody
I'll sing along

The second sleepless night this week, after listening to such amazing movie songs. Smile with tears, and sing with thanks and hope.

Friday, April 11, 2008

Building CIL on Leopard

Following the standard configure/make approach to build CIL on Mac OS X Leopard (10.5), one may encounter the following error:
Compiling obj/x86_DARWIN/feature_config.ml to bytecode
File "obj/x86_DARWIN/feature_config.ml", line 4, characters 1-2:
Unbound value n
make: *** [obj/x86_DARWIN/feature_config.cmo] Error 2


It is due to the echo command in the file Makefile.in (around line 230):
echo -n " (* EXTRAFEATURES: *)" >> $@
Because Leopard follows the UNIX specification more strictly, the syntax echo -n is no longer supported by /bin/sh.

To fix it, replace echo -n with printf, or use /bin/echo, or just omit the -n option.

See #1940018.

Monday, April 07, 2008

Gong Qi

Some pictures shot on Feb 10 during the Chinese new year, at Baoluo, Wenchang, Hainan. It's my friend Feng's hometown; I went there with him to see the famous "Gong Qi" ceremony.

"Gong" (literally, "lord") may refer to a chief or a leader of the early migrates to the Hainan island from the Mainland (one thousand years ago? not sure), as some people tell. If so, I guess the purpose of the ceremony may be similar to the thanksgiving. But some other people say it is related to Xian Furen (Madam Xian), a leader of the Yue peoples in southern China (in the 6th century), and the Feng family is her descendants.

Every year a lot of people come back from cities and share the time.


Fireworks after the ceremony.


Feng's little boy. Cute? :-)


The quiet village.

Wednesday, March 19, 2008

New Labels

To be consistent with the name of this blog that embraces a filesystem naming style, I am introducing the following labels for my posts.

/dev/random, replaces "code", which is inspired by the homonymous column in the USENIX magazine ;login:.

/media, replaces "movies" and "music" for entertainment.

/mnt, for mount points, replaces "travel". Of course it includes trips more than those to mountains.

/usr/X11R7, where the X Window System resides, replaces "photos". When will it be replaced by "/usr/X11R8"?

/var, replaces "uncategorized" for scribblings, e.g., the current post.

Sunday, March 02, 2008

Small Patch for bddbddb

Here's a small bug for bddbddb. If there is a small sized domain (e.g., only 2 functions in the Domain F), and some constant strings in a Datalog file (e.g., 4 additional function names used in the rules), the resulting size of the domain will be out of range (e.g., the size of F is 6 rather than 2, which requires a different bit size) and an exception is raised (e.g., Exception in thread "main" net.sf.javabdd.BDDException: 6 is out of range).

Usually this doesn't hurt because the size of a domain is large enough and it's unlikely to cross the boundary of the BDD size. Though it would fail to compute a call graph for a simple hello-world program.

A possible patch for the method namedConstant in net/sf/bddbddb/Domain.java.
Index: Domain.java
===================================================================
--- Domain.java (revision 654)
+++ Domain.java (working copy)
@@ -114,6 +114,8 @@
if (false && map == null) throw new
IllegalArgumentException("No constant map for Domain " + name + " in
which to look up constant " + constant);
if (map == null) map = new IndexMap(name);
if (!map.contains(constant)) System.err.println("Warning:
Constant " + constant + " not found in map for relation " + name);
- return map.get(constant);
+ int index = map.get(constant);
+ size = BigInteger.valueOf(index + 1L).max(size);
+ return index;
}
}

Wednesday, February 27, 2008

New Macbook Pro

I was told by fishy yesterday that the new Macbook Pro was out, 15-inch screen, clocked at 2.4GHz, with 2G memory and 200G hard drive. Cool. Say goodbye to my 4-year-old PowerBook, which has been crashing since last September. It's time to get in and code on a new laptop. :-)

Monday, January 28, 2008

Another Acceptance

My paper on region safety has been accepted to PLDI 2008. Many thanks to sunnymonkey!