Experience ¡of ¡so-ware ¡engineers ¡ using ¡TLA+, ¡PlusCal ¡and ¡TLC ¡
Chris ¡Newcombe ¡
Principal ¡Engineer, ¡ ¡Amazon ¡Web ¡Services ¡
1 ¡
Experience of so-ware engineers using TLA+, PlusCal and TLC - - PowerPoint PPT Presentation
Experience of so-ware engineers using TLA+, PlusCal and TLC Chris Newcombe Principal Engineer, Amazon Web Services 1 Amazon Web Services 30+
1 ¡
2 ¡
3 ¡
¡“The ¡weight ¡of ¡evidence ¡for ¡an ¡extraordinary ¡claim ¡must ¡be ¡ propor(oned ¡to ¡its ¡strangeness.” ¡-‑ ¡Laplace ¡
4 ¡
¡ ¡ ¡ ¡ ¡“Correctness ¡means ¡a ¡class ¡conforms ¡to ¡its ¡specifica(on. ¡A ¡good ¡ specificaVon ¡defines ¡invariants ¡constraining ¡an ¡objects ¡state, ¡and ¡ postcondi(ons ¡describing ¡the ¡effects ¡of ¡its ¡operaVons. ¡ ¡ ¡ ¡ ¡ ¡ ¡Since ¡we ¡o-en ¡don’t ¡write ¡adequate ¡specificaVons ¡for ¡our ¡classes, ¡how ¡can ¡ we ¡possibly ¡know ¡they ¡are ¡correct? ¡We ¡can’t, ¡but ¡that ¡doesn’t ¡stop ¡us ¡from ¡ using ¡them ¡anyway, ¡once ¡we’ve ¡convinced ¡ourselves ¡that ¡“the ¡code ¡works”. ¡ ¡ ¡ ¡ ¡ ¡ ¡This ¡“code ¡confidence” ¡is ¡about ¡as ¡close ¡as ¡many ¡of ¡us ¡get ¡to ¡correctness, ¡ so ¡let’s ¡just ¡assume ¡that ¡single-‑threaded ¡correctness ¡is ¡
5 ¡
6 ¡
7 ¡
8 ¡
“Three ¡features ¡that ¡dis(nguish ¡Chord ¡from ¡many ¡other ¡peer-‑to-‑peer ¡ lookup ¡protocols ¡are ¡its ¡simplicity, ¡provable ¡correctness, ¡and ¡ provable ¡performance.” ¡
9 ¡
10 ¡
11 ¡
12 ¡
13 ¡
14 ¡
15 ¡
16 ¡
17 ¡
18 ¡
– 93 ¡lines ¡were ¡UNCHANGED ¡statements, ¡very ¡tedious ¡to ¡maintain ¡ ¡
19 ¡
20 ¡
21 ¡
22 ¡
23 ¡
24 ¡
25 ¡
26 ¡
27 ¡
28 ¡
Amazon ¡ConfidenVal ¡ 29 ¡
Download ¡link: ¡hwp://hpts.ws/sessions/amazonbundle.tar.gz ¡ ¡
The ¡example ¡from ¡the ¡paper: ¡ ¡ ¡R2(X0,0) ¡ ¡R2(Y0,0) ¡ ¡R1(Y0,0) ¡ ¡W1(Y1,20) ¡ ¡C1 ¡ ¡R3(X0,0) ¡ ¡R3(Y1,20) ¡ ¡C3 ¡W2(X2,-‑11) ¡ ¡C2 ¡ ¡ The ¡simplest ¡example ¡found ¡by ¡TLC ¡ ¡ ¡ ¡ ¡(note: ¡‘begin’ ¡can ¡be ¡a ¡separate ¡operaVon) ¡ ¡ ¡R1(X0) ¡W1(Y1) ¡W2(X2) ¡C2 ¡B3 ¡C1 ¡R3(X2) ¡R3(Y0) ¡C3 ¡
Amazon ¡ConfidenVal ¡ 30 ¡