the numerical reproducibility fair trade facing the
play

The Numerical Reproducibility Fair Trade: Facing the - PowerPoint PPT Presentation

The Numerical Reproducibility Fair Trade: Facing the Concurrency Challenges at the Extreme Scale Michela Taufer University of Delaware Michela Becchi


  1. The ¡Numerical ¡Reproducibility ¡Fair ¡Trade: ¡ ¡ Facing ¡the ¡Concurrency ¡Challenges ¡ ¡ at ¡the ¡Extreme ¡Scale ¡ Michela ¡Taufer ¡ University ¡of ¡Delaware ¡ ¡ Michela ¡Becchi ¡ University ¡of ¡Missouri ¡ ¡

  2. From ¡MulD-­‑core ¡to ¡Many ¡Cores ¡ Intel’s Xeon Phi – 50 x86 core NVIDIA K20 - 2,496 CUDA cores From: ¡hGp://www.altera.com/technology/system-­‑design/ From ¡hGp://wccIech.com/nvidia-­‑tesla-­‑ arDcles/2012/mulDcore-­‑many-­‑core.html ¡ k20-­‑gk110-­‑specificaDons-­‑unveiled/ ¡ 1 ¡

  3. SoIware ¡ExecuDon ¡on ¡Many ¡Cores ¡ 2 ¡ From http://www.pgroup.com/lit/articles/insider/v2n4a1.htm

  4. Plea ¡for ¡Joint ¡Effort ¡ • Homogenous ¡architectures ¡with ¡large ¡number ¡of ¡cores ¡ § Intel ¡Xeon ¡Phi ¡with ¡50 ¡x86 ¡cores ¡ § NVIDIA ¡K20/K40 ¡with ¡2,496 ¡CUDA ¡cores ¡ • Dynamic ¡mapping ¡of ¡tasks ¡to ¡cores ¡make ¡the ¡predicDon ¡of ¡ which ¡thread ¡is ¡assigned ¡to ¡which ¡core ¡not ¡feasible ¡ • While ¡computer ¡architects ¡focus ¡on ¡power, ¡bandwidth, ¡ energy ¡impacts, ¡…. ¡ The ¡computer ¡science ¡and ¡mathemaDcal ¡communiDes ¡must ¡join ¡ effort ¡to ¡study ¡and ¡miDgate ¡the ¡impact ¡of ¡rounding ¡errors ¡on ¡ result ¡reproducibility ¡when ¡concurrent ¡execuDons ¡burst ¡and ¡ workflow ¡determinism ¡vanishes ¡in ¡massively ¡parallel ¡systems ¡ ¡ 3 ¡

  5. A ¡Case ¡Study: ¡Molecular ¡Dynamics ¡SimulaDons ¡ • MD ¡simulaDons ¡are ¡iteraDve ¡execuDons ¡of ¡M D ¡steps ¡ § Given ¡iniDal ¡atomic ¡posiDons ¡and ¡velociDes, ¡obtain ¡those ¡at ¡ later ¡Dmes ¡by ¡ integra(ng ¡ordinary ¡differen(al ¡equa(ons ¡ • IteraDve ¡steps ¡compute ¡forces ¡on ¡each ¡parDcle ¡due ¡to: ¡ § Bonded ¡interacDons ¡ ¡ § Non-­‑bonded ¡interacDons ¡ ¡ • Different ¡flavors ¡of ¡MD ¡simulaDons: ¡ § Constant ¡energy ¡(NVE) ¡dynamics ¡is ¡the ¡original ¡method ¡of ¡ molecular ¡dynamics ¡and ¡is ¡performed ¡in ¡a ¡closed ¡environment ¡ with ¡a ¡constant ¡number ¡of ¡atoms, ¡volume, ¡and ¡energy ¡ § Constant ¡temperature ¡(NVT) ¡dynamics ¡ ¡use ¡velocity ¡ reassignment ¡to ¡changes ¡system ¡energy ¡states ¡at ¡specified ¡ intervals ¡and ¡is ¡performed ¡ ¡with ¡a ¡constant ¡number ¡of ¡atoms, ¡ volume, ¡and ¡temperature ¡ 4 ¡

  6. MD ¡on ¡Many ¡Core ¡Plaforms ¡ MD ¡simulaDon ¡step: ¡ • Each ¡GPU-­‑thread ¡computes ¡forces ¡ on ¡single ¡atoms ¡ § E.g., ¡bond, ¡angle, ¡dihedrals ¡ and, ¡nonbond ¡forces ¡ • Forces ¡are ¡added ¡to ¡compute ¡ acceleraDon ¡ • AcceleraDon ¡is ¡used ¡to ¡update ¡ Force ¡-­‑> ¡AcceleraDon ¡-­‑> ¡Velocity ¡ velociDes ¡ ¡ • VelociDes ¡are ¡used ¡to ¡update ¡the ¡ ¡ ¡-­‑> ¡ ¡PosiDon ¡ posiDons ¡ 5 ¡

  7. Moving ¡MD ¡onto ¡Accelerators ¡ • Enhancing ¡performance ¡of ¡MD ¡simulaDons ¡allows ¡simulaDons ¡ of ¡larger ¡Dme ¡scales ¡and ¡length ¡scales ¡ • GPU ¡compuDng ¡enables ¡large-­‑scale ¡MD ¡simulaDon ¡ § SimulaDons ¡exhibit ¡speed-­‑up ¡factors ¡of ¡X10-­‑X30 ¡ ¡ MD ¡simulaDon ¡of ¡NaI ¡soluDon ¡system ¡ • Constant ¡energy ¡MD ¡simula(on ¡ ¡ containing ¡988 ¡waters, ¡18 ¡Na+, ¡and ¡ 18 ¡I−: ¡GPU ¡is ¡X15 ¡faster ¡than ¡CPU ¡ -­‑-­‑-­‑-­‑-­‑ ¡Single ¡precision ¡ 6 ¡

  8. Moving ¡MD ¡onto ¡Accelerators ¡ • Enhancing ¡performance ¡of ¡MD ¡simulaDons ¡allows ¡simulaDons ¡ of ¡larger ¡Dme ¡scales ¡and ¡length ¡scales ¡ • GPU ¡compuDng ¡enables ¡large-­‑scale ¡MD ¡simulaDon ¡ § SimulaDons ¡exhibit ¡speed-­‑up ¡factors ¡of ¡X10-­‑X30 ¡ ¡ MD ¡simulaDon ¡of ¡NaI ¡soluDon ¡system ¡ • Constant ¡energy ¡MD ¡simula(on ¡ ¡ containing ¡988 ¡waters, ¡18 ¡Na+, ¡and ¡ 18 ¡I−: ¡GPU ¡is ¡X15 ¡faster ¡than ¡CPU ¡ -­‑-­‑-­‑-­‑-­‑ ¡Single ¡precision ¡ 7 ¡

  9. Moving ¡MD ¡onto ¡Accelerators ¡ • Enhancing ¡performance ¡of ¡MD ¡simulaDons ¡allows ¡simulaDons ¡ of ¡larger ¡Dme ¡scales ¡and ¡length ¡scales ¡ • GPU ¡compuDng ¡enables ¡large-­‑scale ¡MD ¡simulaDon ¡ § SimulaDons ¡exhibit ¡speed-­‑up ¡factors ¡of ¡X10-­‑X30 ¡ ¡ MD ¡simulaDon ¡of ¡NaI ¡soluDon ¡system ¡ • GPU single precision GPU single precision containing ¡988 ¡waters, ¡18 ¡Na+, ¡and ¡ GPU double precision 18 ¡I−: ¡GPU ¡is ¡X15 ¡faster ¡than ¡CPU ¡ -­‑-­‑-­‑-­‑-­‑ ¡Single ¡precision ¡ 8 ¡

  10. Moving ¡MD ¡onto ¡Accelerators ¡ • Enhancing ¡performance ¡of ¡MD ¡simulaDons ¡allows ¡simulaDons ¡ of ¡larger ¡Dme ¡scales ¡and ¡length ¡scales ¡ • GPU ¡compuDng ¡enables ¡large-­‑scale ¡MD ¡simulaDon ¡ § SimulaDons ¡exhibit ¡speed-­‑up ¡factors ¡of ¡X10-­‑X30 ¡ ¡ MD ¡simulaDon ¡of ¡NaI ¡soluDon ¡system ¡ • GPU double precision containing ¡988 ¡waters, ¡18 ¡Na+, ¡and ¡ 18 ¡I−: ¡GPU ¡is ¡X15 ¡faster ¡than ¡CPU ¡ 9 ¡

  11. Code ¡Accuracy: ¡ ¡ Energy ¡FluctuaDons ¡ • A ¡plot ¡of ¡the ¡ energy ¡ fluctua(ons ¡versus ¡(me ¡step ¡ size ¡should ¡follow ¡an ¡ approximately ¡logarithmic ¡ trend ¡1 ¡ • Energy ¡fluctuaDons ¡are ¡ proporDonal ¡to ¡Dme ¡step ¡size ¡ for ¡large ¡Dme ¡step ¡size ¡ § Larger ¡than ¡0.5 ¡fs ¡ • A ¡different ¡behavior ¡for ¡step ¡ size ¡less ¡than ¡0.5 ¡fs ¡is ¡consistent ¡ with ¡results ¡previously ¡ presented ¡and ¡discussed ¡in ¡ other ¡work ¡2 ¡ 1 Allen and Tildesley, Oxford: Clarendon Press, (1987) 2 Bauer et al., J. Comput. Chem. 32(3): 375 – 385, 2011

  12. Composite ¡Precision ¡ArithmeDc ¡ • Numerical ¡reproducibility ¡CANNOT ¡be ¡guaranteed ¡in ¡large-­‑ scale ¡simulaDons ¡on ¡ANY ¡massively ¡parallel ¡plaform ¡ 1, ¡2 ¡ • High ¡precision ¡calculaDons ¡can ¡be ¡achieved ¡using ¡arbitrary ¡ precision ¡libraries ¡ 1 ¡ § One ¡criDcal ¡aspect ¡of ¡many ¡libraries ¡is ¡their ¡complexity ¡ • Composite ¡precision ¡arithmeDc ¡provides ¡a ¡simpler ¡soluDon ¡ § Composite ¡precision ¡represents ¡values ¡(results) ¡as ¡the ¡sum ¡of ¡floaDng-­‑ point ¡numbers ¡of ¡arbitrarily ¡varying ¡orders ¡of ¡magnitude ¡ 3, ¡4 ¡ • Our ¡goal: ¡use ¡composite ¡precision ¡to ¡improve ¡numerical ¡ reproducibility ¡of ¡simulaDons ¡on ¡many ¡core ¡systems ¡ ¡ 1 Bailey (2005) ¡ 2 He and Ding (2000) 11 ¡ 3 Thall (2006) 4 Taufer et al. (2010)

  13. Composite ¡Precision: ¡Data ¡Structure ¡ • In ¡2010, ¡double ¡operaDons ¡>> ¡float ¡operaDons ¡on ¡GPUs ¡ • Our ¡iniDal ¡representaDon ¡of ¡composite ¡precision ¡used ¡two ¡ float ¡numbers ¡(float2) ¡to ¡represent ¡a ¡floaDng ¡point ¡value ¡ struct float2{ float val; // Value float err; // Error ¡ } x 2 ; float2 x2 = x 2 .val + x 2 .err • Each ¡arithmeDc ¡operaDon ¡takes ¡float2s ¡as ¡parameters ¡and ¡ returns ¡float2s ¡ § Error ¡carried ¡through ¡each ¡operaDon ¡ ¡ § OperaDons ¡rely ¡on ¡self-­‑compensaDon ¡of ¡rounding ¡errors ¡ 12 ¡

  14. Composite ¡Precision: ¡AddiDon ¡ Implementa(on ¡ Pseudo-­‑code ¡ float2 x 2, y 2, z 2 � float2 x 2, y 2, z 2 � float t � � Z 2 .val = x 2 .val + y 2 .val � z 2 = x 2 + y 2 � t = z 2 .val - x 2 .val � Z 2 .err = x 2 .val - (z 2 .val – t) + � (y 2 .val – t) + x 2 .err + y 2 .err � • MathemaDcally ¡z 2 .err ¡should ¡be ¡0 ¡ § But ¡errors ¡introduced ¡by ¡floaDng-­‑point ¡operaDons ¡usually ¡result ¡in ¡ z 2 .err ¡being ¡non-­‑zero ¡ • SubtracDon ¡is ¡the ¡same ¡as ¡addiDon, ¡but ¡y 2 .val ¡= ¡–y 2 .val ¡ ¡and ¡ y 2 .err ¡ ¡ ¡= ¡ ¡-­‑y 2 .err ¡ ¡ 13 ¡

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend