Pin (computer program)

Pin
Developer(s)Intel
Stable release
3.31 / June 30, 2024 (2024-06-30)
Operating systemLinux, Windows, macOS
PlatformIA-32, x86-64, Intel Xeon Phi
TypeInstrumentation framework, Profiler
LicenseProprietary, Pin is given free of charge for any use under the Intel Simplified Software License.
Websitewww.intel.com/software/pintool

Pin is a platform for creating analysis tools. A pin tool comprises instrumentation, analysis and callback routines. Instrumentation routines are called when code that has not yet been recompiled is about to be run, and enable the insertion of analysis routines. Analysis routines are called when the code associated with them is run. Callback routines are only called when specific conditions are met, or when a certain event has occurred. Pin provides an extensive application programming interface (API) for instrumentation at different abstraction levels, from one instruction to an entire binary module. It also supports callbacks for many events such as library loads, system calls, signals/exceptions and thread creation events.

In 2020, it received the Programming Languages Software Award from ACM SIGPLAN.[1]

Pin performs instrumentation by taking control of the program just after it loads into the memory. Then just-in-time recompiles (JIT) small sections of the binary code using pin just before it is run. New instructions to perform analysis are added to the recompiled code. These new instructions come from the Pintool. A large array of optimization techniques are used to obtain the lowest possible running time and memory use overhead. As of June 2010, Pin's average base overhead is 30 percent (without running a pintool).[2]

Features

Instrumentation modes

Pin supports two modes of instrumentation called JIT mode and Probe mode. JIT mode supports all features of Pin, while Probe mode supports a limited feature set but is far faster, adding almost no overhead to program's running time. JIT mode uses a just-in-time compiler to recompile all program code and insert instrumentation, while Probe mode uses code trampolines for instrumentation.

Platform independence

Pin was designed for tool portability, and despite JIT compiling from one ISA to the same ISA (and not using a single intermediate representation for all code), most of its APIs are architecture and operating system independent. It was also designed to be portable itself, carefully isolating platform-specific code from generic code, allowing the fast adaptation of Pin to new platforms. Approximately half of the code is generic and the rest is either architecture or OS dependent.[3]

Optimizations

Pin uses many techniques to optimize instrumentation and analysis code, using techniques such as inlining, liveness analysis and smart register spilling. Pin performs these optimizations automatically whenever possible, without needing users to insert any extra code to allow inlining. Naturally, some optimizations still require user hints, and some code structures are easier to inline than others. Direct linking of jitted code sections, a technique called trace linking, and register binding reconciliation, which minimizes register spilling and remapping, are also used.

Ease of use

Pin’s API and implementation are focused on making pin tools easy to write. Pin takes full responsibility for assuring that the instrumentation code from the pin tool does not affect the application state. Also, the API enables instrumentation code to request many pieces of information from Pin. For example, the instrumentation code in the pin tool can use the Pin API to get the memory address being accessed by an instruction, without having to examine the instruction in detail.

Tools

There are many Pintools that are used for varying tasks.

  • Components of Intel Parallel Studio make heavy use of pintools for memory debugging, performance analysis, multithreading correctness analysis and parallelization preparation.
  • Intel Software Development Emulator is a pintool that enables the development of applications using instruction set extensions that are not currently implemented in hardware.
  • CMP$IM is a cache profiler built using pin.[4]
  • PinPlay enables the capture and deterministic replay of the running of multithreaded programs under pin. Capturing the running of a program helps developers overcome the non-determinism inherent in multithreading.[5]
  • Pin itself comes with many example tools that make use of its abilities. These tools are licensed under a BSD-like license.

Alternatives to Pin Tool

There are many other tools available to collect resource usage of running programs on the system such as Bell Lab’s strapon tool and Dyninst tool etc. Bell Lab’s tool uses the strap on technology which runs a tool to collect resources simultaneously with the program but this tool is only compatible with the programs which allow other programs to run simultaneously with them.[6] Furthermore, Dyninst tool uses binary rewriting of the program’s executable and implementable commands inside the program to check for resource usage and is very efficient. However, it is very unstable as it is a relatively new tool and crashes on large scale programs.[7] Lastly, Intel Pin tool uses static binary instrumentation and runs the program as a part of itself while keeping track of all its resources.[8] This approach is more suitable for an antivirus as it can easily run all the processes under itself and can kill programs if they reach a maximum allocated limit as defined by the antivirus.

See also

Notes

  1. ^ "Programming Languages Software Award". www.sigplan.org.
  2. ^ Analyzing Parallel Programs with Pin
  3. ^ Pin: Building Customized Program Analysis Tools with Dynamic Instrumentation
  4. ^ CMP$im: A Pin-Based On-The-Fly Multi-Core Cache Simulator
  5. ^ PinPlay: a framework for deterministic replay and reproducible analysis of parallel programs
  6. ^ Gupta, Chandrashekhar (2007). "Building secure products and solutions". Bell Labs Technical Journal. 12 (3): 21-38. doi:10.1002/bltj.20247. S2CID 30412754.
  7. ^ Lee, Schulz (2007). "Dynamic binary instrumentation and data aggregation on large scale systems". International Journal of Parallel Programming. 35 (3): 207–232. doi:10.1007/s10766-007-0036-3. S2CID 6653468.
  8. ^ Bach, M.; Charney, M.; Cohn, R.; Demikhovsky, E.; Devor, T.; Hazelwood, K.; Jaleel, A.; Luk, Chi-Keung; Lyons, G. (March 2010). "Analyzing Parallel Programs with PIN". Computer. 43 (3): 34–41. doi:10.1109/MC.2010.60. ISSN 0018-9162. S2CID 15155077.

References

Read other articles:

Artikel ini bukan mengenai Pompei. Gnaeus Pompeius MagnusPatung PompeiusLahir29 September 106 SMRoma, Republik RomawiMeninggal28 September 48 SM (berusia 57)Kerajaan PtolemaikPekerjaanPolitikus dan komandan militerSuami/istriAntistiaAemilia ScauraMucia TertiaJuliaCornelia Metella Gnaeus Pompeius Magnus (29 September 106 SM–28 September 48 SM), umumnya disebut Pompeius atau Pompeius yang Agung, adalah pemimpin militer dan politik Republik Romawi. Setelah kemenangan militer, ia menempatkan di...

Pinus Pour les articles homonymes, voir Pin. « Pins » redirige ici. Pour les épinglettes, voir Pin's. Pinus Pinus pinea, pin parasol.Classification Tropicos Règne Plantae Embranchement Pinophyta Classe Pinopsida Sous-classe Pinidae Ordre Pinales Famille Pinaceae Sous-famille Pinoideae GenrePinusL., 1753 Écouter cet article (info sur le fichier) Ce fichier audio a été réalisé à partir de la version du 17 mai 2021, et ne reflète pas les changements ayant eu lieu depuis.(Aid...

Orde AustraliaOrder of AustraliaInsignia bagi Knight/Dame Orde AustraliaDianugerahkan oleh Penguasa Monarki AustraliaTipeTanda kehormatan negaraKelayakanSeluruh warga negara Australia yang masih hidupDianugerahkan kepadaPencapaian dan prestasi dalam darmabakti kepada Australia atau kemanusiaanStatusKini dianugerahkanKepala PenguasaRaja Charles IIIKanselirDavid HurleyTingkatCompanion (AC)Officer (AO)Member (AM)Medal (OAM)Dianugerahkan dalam:  Divisi Umum  Divisi Militer  Penghar...

Đảo Moyenne trong Vườn quốc gia biển Ste Anne Seychelles bao gồm có 2 vườn quốc gia trên đất liền và 6 vườn quốc gia biển.[1] Các vườn quốc gia được quản lý bởi Ủy ban Môi trường Quốc gia Seychelles (SNEC) trực thuộc Bộ Môi trường Danh sách Vườn quốc gia Morne Seychellois Vườn quốc gia Praslin Vườn quốc gia Ramos Vườn quốc gia biển Baie Ternay Vườn quốc gia biển Curieuse Vườn quốc gia bi

American-bred Thoroughbred racehorse CliffordFrom The American turf (1898)SireBrambleGrandsireBonnie ScotlandDamDuchessDamsireKingfisherSexStallionFoaled1890CountryUnited StatesColourDark BayBreederBelle Meade StudOwner1) W. J. Cherry (1891)2) Clifford Porter (1891)3) H. Eugene Leigh & Robert L. Rose (12/1892)4) H. Eugene Leigh (9/1894)5) Hurricana Stud (John Sanford)Trainer1) Frank M. Kelly 2) H. Eugene Leigh 3) John W. Rogers (1894)Record62: 42-10-8EarningsUS$65,143Major winsLatonia Spr...

Drag Race Holland (seizoen 2) Televisieprogramma Drag Race Holland Land van oorsprong  Nederland Zender(s) Videoland, WOW Presents Plus Start 6 augustus 2021 Einde 24 september 2021 Aantal afleveringen 8 Seizoenchronologie ← Vorige Volgende → Drag Race Holland (seizoen 1) Portaal    Televisie Het tweede seizoen van Drag Race Holland begon op 6 augustus 2021 via de streamingdienst Videoland.[1] Internationaal is de serie te zien via de streamingdienst WOW Presents Pl...

Orang dari berbagai etnis yang sedang tertawa, dari kiri atas ke kanan bawah atau dari atas ke bawah (seluler): Afghanistan, Tibet, Brasil, dan Malaysia Pasangan yang sedang bercanda di sawah padi. Humor (bahasa Inggris: humour, atau humor) adalah sikap yang cenderung dilakukan untuk membangkitkan rasa gembira dan memicu tawa gembira Istilah ini berasal dari istilah medis Latin kuno, yang mengajari bahwa keseimbangan cairan dalam tubuh manusia, yang dikenal sebagai humor (bahasa Latin:...

Train station in São Paulo, Brazil For the São Paulo Metro station, see Ipiranga (São Paulo Metro). IpirangaPlatforms of CPTM Ipiranga stations during rain in São Paulo.General informationLocationAv. Presidente Wilson, 3473IpirangaBrazilCoordinates23°34′57″S 46°35′48″W / 23.5825036°S 46.5965849°W / -23.5825036; -46.5965849Owned by Government of the State of São PauloOperated by CPTMPlatformsSide platformsConnections (Planned)[1]ConstructionStru...

Miss Esmeralda is a Victorian burlesque, in two acts, with music by Meyer Lutz and Robert Martin and a libretto by Fred Leslie, under his pseudonym A. C. Torr, and Horace Mills. It is based on Victor Hugo's novel Notre Dame de Paris. The piece premiered in 1887 at the Gaiety Theatre in London, starring Marion Hood in the title role, with Frank Thornton as Quasimodo and featuring E. J. Lonnen and Letty Lind. Background and production John Hollingshead had managed the Gaiety Theatre from 1868 t...

Cet article est une ébauche concernant les Jeux olympiques et la Lettonie. Vous pouvez partager vos connaissances en l’améliorant (comment ?) selon les recommandations des projets correspondants. Lettonie aux Jeux olympiques d'été de 2020 Code CIO LAT Lieu Tokyo Participation 12e Athlètes 33 dans 14 sports Porte-drapeau Jeļena OstapenkoAgnis Čavars MédaillesRang : 59e Or1 Arg.0 Bron.1 Total2 Lettonie aux Jeux olympiques d'été Lettonie aux Jeux olympiques d'été de 2016 ...

Legislative Assembly constituency in Himachal Pradesh State, India MandiConstituency for the Himachal Pradesh Legislative AssemblyConstituency detailsCountryIndiaRegionNorth IndiaStateHimachal PradeshDistrictMandiLS constituencyMandiTotal electors78,113[1]ReservationNoneMember of Legislative Assembly14th Himachal Pradesh Legislative AssemblyIncumbent Anil Sharma PartyBharatiya Janata PartyElected year2022 Mandi Assembly constituency is one of the 68 constituencies of the Himachal Prad...

Shopping mall in Maryland, United StatesFrederick Towne CenterLocationFrederick, Maryland, United StatesCoordinates39°25′12″N 77°27′19″W / 39.42000°N 77.45528°W / 39.42000; -77.45528Opening date1972Closing dateApril 2013DeveloperShopco Advisory Group[1]No. of stores and services0 (20 vacant)No. of anchor tenants3 (1 vacant)No. of floors1 (2 in Boscov's)Public transit access TransIT bus: 10, 40, 50, 51, 80 Frederick Towne Mall was a mall located in F...

Caramuru BuildingEdifício CaramuruCaramuru Building (Edifício Caramuru), Salvador, BahiaCaramuru Building in BrazilGeneral informationArchitectural styleModernistAddressAvenida Ipiranga, 1284, CentroTown or cityBahiaCountryBrazilCoordinates12°58′17″S 38°30′50″W / 12.971351°S 38.513946°W / -12.971351; -38.513946Groundbreaking1946HeightArchitecturalModernTechnical detailsFloor count8Lifts/elevators2Design and constructionArchitect(s)Paulo Antunes Ribeiro Ex...

2016 single by Usher featuring FutureRivalsSingle by Usher featuring Futurefrom the album Hard II Love ReleasedAugust 30, 2016 (2016-08-30)Length3:49LabelRCASongwriter(s)Usher Raymond IVKendricke BrownCameron MurphyParis JonesCarlos St JohnNayvadius WilburnProducer(s)K-MajorMurphy KidUsher singles chronology Missin U (2016) Rivals (2016) Party (2016) Future singles chronology Too Much Sauce(2016) Rivals(2016) Used to This(2016) Music videoRivals on YouTube Rivals is a s...

Australian rules footballer Australian rules footballer Bradd Dalziell Dalziell in 2014Personal informationFull name Bradd DalziellNickname(s) Razzle DazzleDate of birth (1987-03-15) 15 March 1987 (age 36)Place of birth Western AustraliaOriginal team(s) Lynwood Ferndale JFCDraft 52nd, 2007 National Draft (Brisbane Lions)Height 184 cm (6 ft 0 in)Weight 82 kg (181 lb)Position(s) MidfielderClub informationCurrent club East Fremantle Football ClubPlaying ca...

Russian royal palace near St. Petersburg For the town adjacent to Oranienbaum that formerly shared this name, see Lomonosov, Russia. Historical Centre of the Town of Lomonosov (Oranienbaum), including the Palace and Park Ensemble of the Upper Park and Lower GardenUNESCO World Heritage SiteLocationLomonosov, Saint Petersburg, RussiaPart ofHistoric Centre of Saint Petersburg and Related Groups of MonumentsCriteriaCultural: (i), (ii), (iv), (vi)Reference540bis-020aInscription1990 (14th Sess...

Tunnel construction technique This article needs additional citations for verification. Please help improve this article by adding citations to reliable sources. Unsourced material may be challenged and removed.Find sources: Microtunneling – news · newspapers · books · scholar · JSTOR (August 2020) (Learn how and when to remove this template message) Microtunneling or microtunnelling is a tunnel construction technique used to construct utility tunnels ...

Not to be confused with Harqin Banner. Banner in Inner Mongolia, ChinaAr'horqin Banner 阿鲁科尔沁旗 • ᠠᠷᠤ ᠬᠣᠷᠴᠢᠨ ᠬᠣᠰᠢᠭᠤBannerAr KhorchinShow map of Inner MongoliaAr KhorchinShow map of ChinaCoordinates: 43°52′N 120°04′E / 43.867°N 120.067°E / 43.867; 120.067CountryChinaAutonomous regionInner MongoliaPrefecture-level cityChifengBanner seatTianshan TownArea • Total13,240 km2 (5,110 sq mi)Elevation37...

Der er for få eller ingen kildehenvisninger i denne artikel, hvilket er et problem. Du kan hjælpe ved at angive troværdige kilder til de påstande, som fremføres i artiklen. Junior Eurovision Song Contest 2018 Slogan: Light Up Finale 25. november 2018 Værter Eugene PerlinZinaida KupriyanovichHelena Meraai Sendevært BTRC (Belarusian Television and Radio Company) Producer Jon Ola Sand By Minsk, Minsk-Arena Sted  Hviderusland Vindersang  Polen Anyone i want to be Stemmesystem Hv...

Peta Piauí menunjukkan lokasi Teresina Teresina merupakan nama kota di Brasil. Letaknya di bagian tengah. Tepatnya di negara bagian Piauí, Brasil. Pada tahun 2006, kota ini memiliki jumlah penduduk sebanyak 813.992 jiwa dengan memiliki luas wilayah 1.755,698 km². Dengan memiliki kepadatan penduduk sebesar 456,8 jiwa/km². Kota ini adalah ibu kota negara bagian Piauí. Pranala luar Situs resmi Diarsipkan 2011-02-22 di Wayback Machine. lbsIbu kota negara bagian di Brasil Aracaju ·...