1 / 8

TreadMarks

TreadMarks. CS 498LVK Hassan Jafri. Agenda. The DSM Architecture The Parallel Programming Model. Programming Primitives. Shared Memory Allocation Tmk_malloc()/Tmk_free(…) Synchronization Tmk_barrier() Tmk_lock_acquire(…)/Tmk_lock_free(…) Others Tmk_startup(…), Tmk_exit(…)

coyne
Download Presentation

TreadMarks

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. TreadMarks CS 498LVK Hassan Jafri

  2. Agenda The DSM Architecture The Parallel Programming Model

  3. Programming Primitives • Shared Memory Allocation • Tmk_malloc()/Tmk_free(…) • Synchronization • Tmk_barrier() • Tmk_lock_acquire(…)/Tmk_lock_free(…) • Others • Tmk_startup(…), Tmk_exit(…) • Tmk_nprocs, Tmp_proc_id • Jacobi example

  4. DSM Architecture • Big Issues • Memory Model • Sequential Consistency (example IVY) • Total Order on all memory accesses • Read will return the last thing written • Read fault, Write faults • False sharing leading to “ping-pong” effect • HUGE OVERHEAD

  5. DSM Architecture • Big Issues • Memory Model • Release Consistency (TMK) • Latest possible time when shared memory updates mist be visible • Provide sufficient synchronization to avoid races that would make updates unnecessary until synchronization • Formally: • Acquire: Departure from barrier or lock acquire • Release: Arrival at barrier or lock release

  6. DSM Architecture • Big Issues • Memory Model • Release Consistency (TMK) • Lazy Release Consistency (TMK) • Eager Release Consistency

  7. DSM Architecture • Big Issues • Memory Model • Multiple Writer Protocol • P1 and P2 write to the same page • Page write-protected, first write access will generate fault and a twin of the page will be created • At barrier, P1 and P2 will invalidate that pages • Next time P1 and P2 access the page, diffs will be exchanged • What if P1 and P2 modify overlapping portions of the page? Learn how to program

  8. Performance Comparison • TMK vs. MPI for Jacobi • TMK vs. MPI for FFT

More Related