Previous | Next --- Slide 45 of 60
Back to Lecture Thumbnails
kevtan

I just wanted to note that with hardware implementations of transactional memory, the system doesn't actually track memory addresses. Instead, it operates on the granularity of $-lines. That is, it tracks which $-lines have been read from and written to by every transaction. If it detects conflicts between the $-lines of two transactions, then it'll abort one of them. This can result in artifactual false sharing that actually causes the system to incorrectly detect a conflict and restart abort a transaction! This is because transactions can potentially share a $-line but not actually have interacted with the same memory address. Rip.

trip

@kevtan are you using '$' to represent 'cache'? That's a power move.

kevtan

@trip Yee. I saw it on the slides a lecture or two back and thought it was a really concise and cool way to talk about caches (or should I say $'s).

l-henken

I would think that the consequences of false sharing in transactional memory could be more drastic than the consequences of false sharing in regards to $$$$ coherence. The performance hit from cache coherence false sharing can be seen as an additive constant whereas the performance hit from transactional memory can be seen as on the order of the atomic sections' sizes.

cbfariasc

I'm having trouble understanding how this would work, specifically, does a transaction check for conflicts at any point of all other transactions? Wouldn't that mean that it has to iterate through its entire body to see what memory accesses it has before doing the same for all other transactions? That seems like a lot of overhead.

kevtan

@cbfariasc Depending on what kind of conflict detection policy your transactional memory system employs, transactions check for conflicts at two different times:

  1. If you're using pessimistic conflict detection, then you check on every read and write.
  2. If you're using optimistic conflict detection, then you check when you want to commit.

You don't necessarily have to iterate through the entire body of transactions to check their loads and stores. There are a variety of different data structures you could use to accelerate conflict detection. For instance, with pessimistic conflict detection, you're checking if another transaction has manipulated a particular memory address x. The transactional memory system probably has some sort of O(1) mapping to do this. Does that help?

Please log in to leave a comment.