MessiandNeymar

  • Subscribe to our RSS feed.
  • Twitter
  • StumbleUpon
  • Reddit
  • Facebook
  • Digg

Monday, March 26, 2012

Cliff Click's deep dive into Constant Propagation techniques

Posted on 9:19 PM by Unknown

Cliff Click has published the third episode of his description of lattice-building techniques for constant propagation in optimizing compilers:

  1. Too Much Theory
  2. Too Much Theory, Part 2
  3. Too Much Theory, Part 3

The series starts off with a promise:

I’ve been wrestling with some tricky bugs and I’d thought I’d share the pain. For fun, I’m going to toss in evidence that All Your Existing Optimizing Compilers Are Broken, and least they are if they attempt a data-flow style Constant Propagation on a language with a class hierarchy and a distinguished NULL pointer (e.g. Java, C++).

The meat of the series is the explanation of the general approach to constant propagation, using a lattice data structure to describe various important classes of partially-known values.

The series closes by finally getting to the originally-promised bug:

The Constant Propagation algorithm relies on having a lattice – and lattices are defined as having a unique lower-bound (and unique upper-bound) for any two elements. This structure does NOT have a unique lower-bound, and so is no longer a lattice! For some particular Java program and some particularly bad luck with our CP algorithm – the CP algorithm can hang indefinitely, or miss some constants on some runs – but find those constants on other runs for the same Java program. Garbage-In Garbage-Out. CP is technically wedged.

It's heavy going, but Click does his typical superb job of description and explanation, and if you've spent much time studying compilers, you'll find this well worth your time. The articles are laden with references to background information, so if you find you want to learn more about Partial Evaluation, or Sparse Conditional Constant Propagation, or Constant Folding, you'll have plenty to read and pursue.

By the way, it appears that Click has left Azul Systems, and has founded a new startup: 0xdata. Big data systems are all the rage nowadays, and 0xdata seems to have all the right buzzwords:

H20 brings database like interactiveness to Hadoop. It can be installed as a standalone or on top of existing Hadoop installation. It leverages data in HDFS and other familiar components in the Hadoop ecosystem such as Hive and Pig.
Click's high end performance bona fides are as robust as they get, so it should be interesting to follow the 0xdata work...
Email ThisBlogThis!Share to XShare to FacebookShare to Pinterest
Posted in | No comments
Newer Post Older Post Home

0 comments:

Post a Comment

Subscribe to: Post Comments (Atom)

Popular Posts

  • Shelter
    I meant to post this as part of my article on Watership Down , but then totally forgot: Shelter In Shelter you experience the wild as a moth...
  • Parbuckling
    The enormous project to right and remove the remains of the Costa Concordia is now well underway. There's some nice reporting on the NP...
  • The Legend of 1900: a very short review
    Fifteen years late, we stumbled across The Legend of 1900 . I suspect that 1900 is the sort of movie that many people despise, and a few peo...
  • A Very Short Review of The Hangman's Daughter
    By way of the quite-nice Kindle Owners Lending Library , I recently read Oliver Potzsch's The Hangman's Daughter . At least part of ...
  • Jones v Anand
    If you think grandmaster chess is boring, with lots of positional strategic maneuvering, you owe it to yourself to play through the game bet...
  • A Glorious Defeat: a very short review
    Somewhat unexpectedly, Timothy Henderson's A Glorious Defeat: Mexico and Its War with the United States found its way to my nightstand....
  • Unbroken: a very short review
    Laura Hillenbrand's Seabiscuit: Three Men and a Racehorse was a massive worldwide hit, and became a movie hit as well. It took her seve...
  • One Day: a very short review
    I'm about two years late (typical), but I finally got around to David Nicholls's One Day . The book's concept is to tell a story...
  • Rim fire winding down
    I hadn't been over to Inciweb's Rim Fire status page in a while, so I dropped in to see how the progress goes. This is the long, sl...
  • XCOM Enemy Unknown
    I don't have much time to play video games, so I tend to go many months between games, looking for just the right one. I've been pla...

Blog Archive

  • ►  2013 (165)
    • ►  September (14)
    • ►  August (19)
    • ►  July (16)
    • ►  June (17)
    • ►  May (17)
    • ►  April (18)
    • ►  March (24)
    • ►  February (19)
    • ►  January (21)
  • ▼  2012 (335)
    • ►  December (23)
    • ►  November (30)
    • ►  October (33)
    • ►  September (34)
    • ►  August (29)
    • ►  July (39)
    • ►  June (27)
    • ►  May (48)
    • ►  April (32)
    • ▼  March (30)
      • 30 days has September, April, June, and November ...
      • Online reviews
      • I don't know what the game will be like ...
      • Every day you get in your life is precious
      • Last year, it took a full hour!
      • Bill Slawski's Top Ten SEO Patents list
      • Cliff Click's deep dive into Constant Propagation ...
      • A great example of the power of generators
      • I have no idea what it will be like to play ...
      • I'm really enjoying Dan Boneh's online cryptograph...
      • BATS IPO Algorithmic Snafu?
      • The complicated task of trying NOT to keep up with...
      • It's not just a game...
      • Internet scale, administrations, and operations
      • Followup, followup, followup
      • Perfectly named for your career
      • rands on hacking
      • Mapping the past
      • Mark your calendars!
      • The Google I/O 2012 website is live
      • Software in the courts
      • Great gaming post
      • Link dumping, March 2012 edition
      • Are some algorithms simply too hard to implement c...
      • The Stanford online cryptography class is up and r...
      • A fine use of the web
      • RSA 2012 has come and gone
      • How will the field of software analysis emerge?
      • Satan's Trifecta
      • I love style guides
    • ►  February (10)
Powered by Blogger.

About Me

Unknown
View my complete profile