MessiandNeymar

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

Monday, July 23, 2012

Simple hardware lessons for a software guy, part 2

Posted on 8:05 PM by Unknown

It's more than just networking hardware that mystifies software guys like me. Take, for example, the incredibly sophisticated memory caches that are found on modern CPUs.

I recently came across a superb paper by Paul McKenney of IBM's Linux Technology Center: Memory Barriers: a Hardware View for Software Hackers.

McKenney's paper sets out to teach software types like myself just enough about the design and implementation of cache coherency algorithms in modern multi-core processors so that we can write software that is both correct and efficient.

The hardware designers cannot help directly here, since the CPUs have no idea which variables are related, let alone how they might be related. Therefore, the hardware designers provide memory-barrier instructions to allow the software to tell the CPU about such relations. The program fragment must be updated to contain the memory barrier

The paper is clear and straightforward, with great diagrams and examples. I particularly enjoy the "quick quiz" format, in which McKenney intersperses review questions in the text, and provides answers at the end of the paper so you can periodically stop, take the quiz, check your answer, and keep going.

If you've ever wondered about the MESI protocol, or about store buffers, or about writeback, snooping, and invalidation, or how the DEC Alpha processor impacted the Linux kernel memory-ordering primitives, don't hesitate, dig right in!

This is the sort of paper that every system software engineer should read, understand, and periodically re-read. Thank you IBM and Paul McKenney for making it available!

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...
  • 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...
  • Rediscovering Watership Down
    As a child, I was a precocious and voracious reader. In my early teens, ravenous and impatient, I raced through Richard Adams's Watershi...
  • Must be a heck of a rainstorm in Donetsk
    During today's Euro 2012 match between Ukraine and France, the game was suspended due to weather conditions, which is a quite rare occur...
  • Beethoven and Jonathan Biss
    I'm really enjoying the latest Coursera class that I'm taking: Exploring Beethoven’s Piano Sonatas . This course takes an inside-out...
  • Starting today, the games count
    In honor of the occasion: The Autumn Wind is a pirate, Blustering in from sea, With a rollocking song, he sweeps along, Swaggering boisterou...
  • 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...
  • For your weekend reading
    I don't want you to be bored this weekend, so I thought I'd pass along some articles you might find interesting. If not, hopefully y...
  • Are some algorithms simply too hard to implement correctly?
    I recently got around to reading a rather old paper: McKusick and Ganger: Soft Updates: A Technique for Eliminating Most Synchronous Writes ...
  • Don't see me!
    When she was young, and she had done something she was embarrassed by or felt guilty about, my daughter would sometimes hold up her hand to ...

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)
      • Serious infrastructure issues
      • Drone pilots in the NYT
      • Nice Olympics sailing video
      • Inside the Coursera contract
      • Networking: theory and practice
      • The other Eagle
      • Precious Reynolds and the Milwaukee Protocol
      • Trying to understand the evolution of finance
      • Who invented the Internet, part 94
      • Annie Hall, now and then
      • Simple hardware lessons for a software guy, part 3
      • Simple hardware lessons for a software guy, part 2
      • Simple hardware lessons for a simple software guy
      • The bubble is back!
      • It's not just a game ...
      • Random stuff I'm reading currently
      • Solomon's Oak: a very short review
      • Postcards from the high end...
      • Some Dallas phone numbers are not Dallas phone num...
      • Perforce 2012.2 has entered beta testing
      • Good enough for GitHub
      • The Coursera Tsunami
      • A collection of AWS post-mortems
      • Java code coverage and thrown exceptions
      • Google Summer of Code and the University of Moratuwa
      • Construction Everywhere
      • MMDS 2012
      • Tips for security conference week
      • GSoC 2012: halfway there!
      • Various database topics
      • A troubling article on scientific careers
      • ubuntu tracker and locate
      • So that's what it takes to find a Higgs Boson!
      • And now we will know for sure
      • Silicon Valley craziness
      • Matthew Yglesias on patent "reform"
      • Post-vacation link dump
      • A week in Kauai
      • I'm back online
    • ►  June (27)
    • ►  May (48)
    • ►  April (32)
    • ►  March (30)
    • ►  February (10)
Powered by Blogger.

About Me

Unknown
View my complete profile