__FORCETOC__
Instruments (formerly Xray) is an application performance analyzer and visualizer by
Apple Inc.
Apple Inc. is an American multinational corporation and technology company headquartered in Cupertino, California, in Silicon Valley. It is best known for its consumer electronics, software, and services. Founded in 1976 as Apple Comput ...
, integrated in
Xcode 3.0 and later versions of Xcode. It is built on top of the
DTrace
DTrace is a comprehensive dynamic tracing framework originally created by Sun Microsystems for troubleshooting kernel and application problems on production systems in real time.
Originally developed for Solaris, it has since been released un ...
tracing framework from
OpenSolaris
OpenSolaris () is a discontinued open-source computer operating system for SPARC and x86 based systems, created by Sun Microsystems and based on Solaris. Its development began in the mid 2000s and ended in 2010.
OpenSolaris was developed as ...
, which was
ported to
Mac OS X v10.5 and which is available in all following versions of
macOS
macOS, previously OS X and originally Mac OS X, is a Unix, Unix-based operating system developed and marketed by Apple Inc., Apple since 2001. It is the current operating system for Apple's Mac (computer), Mac computers. With ...
.
Instruments shows a time line displaying any event occurring in the application, such as CPU activity variation, memory allocation, and network and file activity, together with graphs and statistics. Group of events are monitored via customizable "instruments", which have the ability to record user generated events and replay (emulate) them exactly as many times as needed, so a developer can see the effect of code changes without actually doing the repetitive work. The ''Instrument Builder'' feature allows the creation of custom analysis instruments.
Features
Built-in instruments can track
*
CPU activity of
processes and
threads.
* Memory allocation and release,
garbage collection and
memory leaks.
*
File reads, writes, locks.
* Network activity and traffic.
This instrument works like
Activity Monitor but also stores the data for future reference.
* Graphics and inner workings of
OpenGL
OpenGL (Open Graphics Library) is a Language-independent specification, cross-language, cross-platform application programming interface (API) for rendering 2D computer graphics, 2D and 3D computer graphics, 3D vector graphics. The API is typic ...
and
Metal
A metal () is a material that, when polished or fractured, shows a lustrous appearance, and conducts electrical resistivity and conductivity, electricity and thermal conductivity, heat relatively well. These properties are all associated wit ...
.
* Energy diagnostics and "dead" objects.
* UI automation and Core animation.
* User events, such as
keyboard keys pressed and mouse moves and clicks with exact time.
See also
*
List of performance analysis tools
*
Dashcode
*
Shark (application)
References
MacOS programming tools
Debuggers
Profilers
Software optimization
{{Mac-software-stub