splat 명령
용도
SPLAT(Simple Performance Lock Analysis Tool). 커널 및 pthread 잠금 사용법 보고서를 제공합니다.
구문
splat -i 파일 [ -n 파일 ] [ -o 파일 ] [ -d [ bfta ] ] ] [ -l 주소 ] [ -c 클래스] [ -s [ acelmsS ] ] ] [ -C cpus ] [ -S count ] [ -t start] [ -T stop] [ -p ]를 입력합니다
splat -h[주제]
스플랫 -j
설명
splat (단순 성능 잠금 분석 도구)는 AIX® 추적 파일을 후처리하여 커널의 단순 및 복잡한 잠금 사용량 보고서를 생성하는 소프트웨어 도구입니다. pthread mutex 읽기/쓰기 잠금 및 조건 변수 사용법 보고서가 생성됩니다.
플래그
| 항목 | 설명 |
|---|---|
| -i 입력 파일 | AIX 추적 파일(REQUIRED). |
| -n 이름 파일 | gensyms 명령의 출력을 포함하는 파일입니다. |
| -o 출력 파일 | (DEFAULT: stdout)에 보고서를 작성하기 위한 파일입니다. |
| -d 세부 정보 | 세부사항은 다음 중 하나일 수 있습니다:[b]asic: 요약 및 잠금 세부사항(DEFAULT) [f]unction: 기본 + 기능 세부사항 [t]hread: 기본 + 스레드 세부사항 [a]ll: 기본 + 기능 + 스레드 세부사항 |
| -c 클래스 | 사용자가 10진수 잠금 클래스 색인을 제공하는 경우, splat는 해당 클래스에 있는 잠금에 대한 활동만 보고합니다. |
| -l 주소 | 사용자가 16진수 잠금 주소를 제공하는 경우, splat는 해당 주소에 있는 잠금에 대한 활동만 보고합니다. splat는 해당 잠금 주소를 포함하는 잠금 후크에 대한 추적 파일을 필터링하며, 해당 잠금에 대해서만 보고서를 작성합니다. |
| -s 기준 | 다음을 기준으로 잠금, 함수 및 스레드 보고서를 분류하십시오.
|
| -C CPU | 프로세서의 수가 이 추적을 위해 제공하는 것을 지정하십시오. |
| -S 카운트 | 각 보고서의 최대 항목 수 (DEFAULT: 10)입니다. |
| -t 시작 시간 | 추적 시작 이후의 초 단위 시간 오프셋입니다. |
| -T 정지 시간 | 추적 데이터 분석을 정지하기 위한 추적 시작 이후의 초 단위 시간 오프셋 (DEFAULT: 추적의 끝)입니다. |
| -h[주제] | 사용법 또는 특정 주제에 대한 도움말입니다. 유효한 주제는 다음과 같습니다.
|
| -j | splat에서 사용하는 추적 후크의 리스트를 인쇄하십시오. |
| -p | 프로세스 시간을 계산하기 위해 PURR 등록 사용을 지정합니다. |
도움말
다음은 사용 가능한 도움말 항목의 리스트 및 각각의 간략한 요약입니다.
| 항목 | 설명 |
|---|---|
| 개요 | 이 텍스트입니다. |
| 입력 | 스플랫에서 유용한 출력을 얻기 위해 필요한 AIX 추적 후크입니다. |
| NAMES | 이름 유틸리티가 splat이 주소를 사람이 읽을 수 있는 기호로 맵핑하도록 하는 데 사용될 수 있습니다. |
| REPORTS | splat가 생성할 수 있는 각 보고서에 대한 설명 및 보고된 값을 계산하는 데 사용되는 방식에 대해 설명합니다. |
| SORTING | 사용 가능한 모든 분류 옵션과 splat의 출력에 적용하는 방법에 대한 리스트입니다. |
Splat 추적
Splat는 AIX
추적 명령을 통해 수집된 AIX
추적 파일을 1차 입력으로 간주합니다. splat로 추적을 분석하기 전에
추적이 다음을 포함하여 적당한 후크 세트로 수집되는지
확인해야 합니다.
106 DISPATCH
10C DISPATCH IDLE PROCESS
10E RELOCK
112 LOCK
113 UNLOCK
134 HKWD_SYSC_EXECVE
139 HKWD_SYSC_FORK
419 CPU PREEMPT
465 HKWD_SYSC_CRTHREAD
46D WAIT LOCK
46E WAKEUP LOCK
606 HKWD_PTHREAD_COND
607 HKWD_PTHREAD_MUTEX
608 HKWD_PTHREAD_RWLOCK
609 HKWD_PTHREAD_GENERAL
이 잠금 및 잠금 해제 추적 이벤트를
캡처하면 멀티프로세서 환경에서 사용되는 잠금 빈도에 따라 심각한 성능 저하를
야기할 수 있습니다. 따라서, 잠금 추적 이벤트 보고는
주로 사용 안함으로 설정됩니다. 잠금 추적 이벤트 보고를 사용 가능하게 하려면
splat에 필요한 잠금 추적 이벤트를 포함하게 될 추적이 수집되기 전에 다음 단계를
수행해야 합니다(KornShell 구문). 1. bosboot -ad /dev/hdisk0 -L
2. shutdown -Fr
3. (reboot the machine)
4. locktrace -S
5. mkdir temp.lib; cd temp.lib
6. ln -s /usr/ccs/lib/perf/libpthreads.a
7. export LIBPATH=$PWD:$LIBPATH
단계 1 - 3은 선택사항입니다. 이 단계에서는 주소 대신에 커널 잠금 클래스 이름 표시가
사용 가능합니다. bosboot 및 해당 플래그에 대한 자세한 정보는 bosboot(1)의 내용을 참조하십시오. 5 - 7 단계는 사용자 pthread 잠금 계기를 활성화하기 위해 필요합니다. temp.lib 서브디렉토리는
어딘가에 놓여질 수 있습니다. 1 - 7 단계는
보고서 완료에 반드시 필요합니다.Splat 이름
Splat은 선택적 입력으로 gensyms의 출력을 사용하고 이를 사용하여 잠금 및 기능 주소를 사람이 읽을 수 있는 기호로 맵핑할 수 있습니다.
잠금 클래스 및 오프셋은 전체적인 잠금을 확인하는데 사용되지만, 실제 기호 만큼 구체적이지 않습니다.
Splat 보고서
splat에서 생성한 보고서는
보고서 요약, 잠금 요약 보고서 섹션 및 잠금 세부사항 보고서의 리스트로 구성되고
각각에는 연관된 기능 세부사항 및/또는 스레드 세부사항 보고서가
있을 수 있습니다.
Report Summary
^^^^^^^^^^^^^^
The report summary consists of the following elements:
- The trace command used to collect the trace.
- The host that the trace was taken on.
- The date that the trace was taken on.
- The duration of the trace in seconds.
- The estimated number of CPUs
- The combined elapsed duration of the trace in seconds;
( the duration of the trace multiplied by the number of
CPUs identified during the trace ).
- Start time, which is the offset in seconds from the beginning of the
trace that trace statistics begin to be gathered.
- Stop time, which is the offset in seconds from the beginning of the
trace that trace statistics stop being gathered.
- Total number of acquisitions during the trace.
- Acquisitions per second, which is computed by dividing
the total number of lock acquisitions by the real-time
duration of the trace.
- % of Total Spin Time, this is the summation of all lock spin hold
times, divided by the combined trace duration in seconds, divided by 100.
The current goal is to have this value be less than 10% of the total
trace duration.
Lock Summary
^^^^^^^^^^^^
The lock summary report has the following fields:
Lock The name, lockclass or address of the lock.
Type The type of the lock, identified by one of the following letters:
Q A RunQ lock
S A simple kernel lock
D A disabled simple kernel lock
C A complex kernel lock
M A PThread mutex
V A PThread condition-variable
L A PThread read/write lock
Acquisitions The number of successful lock attempts for this lock, minus
the number of times a thread was preempted while holding
this lock.
Spins The number of unsuccessful lock attempts for this lock,
minus the number of times a thread was undispatched while
spinning.
Wait The number of unsuccessful lock attempts that
or resulted in the attempting thread going to
Transform sleep to wait for the lock to become available,
or allocating a krlock.
%Miss Spins divided by Acquisitions plus Spins, multiplied by 100.
%Total Acquisitions divided by the total number of all
lock acquisitions, multiplied by 100.
Locks/CSec Acquisitions divided by the combined elapsed
duration in seconds.
Percent HoldTime
Real CPU The percent of combined elapsed trace time that
threads held the lock in question while dispatched.
DISPATCHED_HOLDTIME_IN_SECONDS divided by combined
trace duration, multiplied by 100.
Real Elaps(ed) The percent of combined elapsed trace time that
threads held the lock while dispatched or sleeping.
UNDISPATCHED_AND_DISPATCHED_HOLDTIME_IN_SECONDS divided
by combined trace duration, multiplied by 100.
Comb Spin The percent of combined elapsed trace time that
threads spun while waiting to acquire this lock.
SPIN_HOLDTIME_IN_SECONDS divided by combined trace
duration, multiplied by 100.
퍼센트 회전 보류 시간에 의해 내림차순으로 분류된 10개의 잠금
리스트에 대한 잠금 요약 보고서 디폴트 값(10번째 필드). 요약 보고서의 길이는 -S 전환을 사용하여 조정될 수 있습니다. 요약 보고서(및 다른 모든 보고서)의 정렬 순서는 옵션이 SORTING 도움말 섹션, splat -h 정렬에서 설명된
-s 전환으로 설정될 수 있습니다.Lock Detail
^^^^^^^^^^^
The lock detail report consists of the following fields:
LOCK The address (in hexadecimal) of the lock.
NAME The symbol mapping for that address (if available)
CLASS The lockclass name (if available) and hexadecimal offset,
used to allocate this lock ( lock_alloc() kernel service ).
Parent Thread Thread id of the parent thread. This field only exists for Mutex,
Read/Write lock and Conditional Variable report.
creation time Elapsed time in seconds after the first event recorded in trace,
if available. This field only exists for Mutex, Read/Write lock
and Conditional Variable report.
deletion time Elapsed time in seconds after the first event recorded in trace,
if available. Tthis field only exists for Mutex, Read/Write lock
and Conditional Variable report.
Pid Pid number associated to the lock (this field only exists for Mutex,
Read/Write lock and Conditional Variable report).
Process Name Process name associated to the lock (this field only exists for Mutex,
Read/Write lock and Conditional Variable report).
Call-Chain Stack of called methods (if possible to have them, this field only
exists for Mutex, Read/Write lock and Conditional Variable report).
Acquisitions The number of successful lock attempts for this lock.
This field is named Passes for the conditional variable lock report.
Miss Rate The number of unsuccessful lock attempts divided by
Acquisitions plus unsuccessful lock attempts, multiplied
by 100.
Spin Count The number of unsuccessful lock attempts.
Wait Count The number of unsuccessful lock attempts that resulted in
the attempting thread going to sleep to wait for the lock
to become available.
Transform Count The number of krlock allocated and deallocated by the simple lock.
Busy Count The number of simple_lock_try() calls that returned busy.
Seconds Held
CPU The total time in seconds that this lock was held by
dispatched threads.
Elapsed The total time in seconds that this lock was held by
both dispatched and undispatched threads.
NOTE: neither of these two values should exceed the
total real elapsed duration of the trace.
Percent Held
Real CPU The percent of combined elapsed trace time that
threads held the lock in question while dispatched.
DISPATCHED_HOLDTIME_IN_SECONDS divided by trace
duration, multiplied by 100.
Real Elaps(ed) The percent of combined elapsed trace time that
threads held the lock while dispatched or sleeping.
UNDISPATCHED_AND_DISPATCHED_HOLDTIME_IN_SECONDS divided
by trace duration, multiplied by 100.
Comb Spin The percent of combined elapsed trace time that
threads spun while waiting to acquire this lock.
SPIN_HOLDTIME_IN_SECONDS divided by trace duration,
multiplied by 100.
Wait The percentage of combined elapsed trace time that
threads unsuccessfully tried to acquire this lock.
SpinQ Splat keeps track of the minimum, maximum and average
depth of the spin queue (the threads spinning, waiting
for a lock to become available).
WaitQ As with the spin queue, splat also tracks the minimum,
maximum and average depth of the queue of threads waited
waiting for a lock to become available).
PROD The associated krlocks prod calls count.
CONFER SELF The confer to self calls count for the simple lock and the
associated krlocks.
CONFER TARGET The confer to target calls count for the simple lock and the
associated krlocks. w/ preemption reports the successfull calls
count, resulting in a preemption.
CONFER ALL The confer to all calls count for the simple lock and the
associated krlocks. w/ preemption reports the successfull calls
count, resulting in a preemption.
HANDOFF The associated krlocks handoff calls count.
Lock Activity w/Interrupts Enabled (mSecs)
잠금 세부사항 보고서의 이 섹션은 밀리초로 표시된 시간에
splat이 각 잠금에 대해 수집하는 원시 데이터의 덤프입니다. 다섯 개의 상태: LOCK, SPIN, WAIT, UNDISP(atched) 및 PREEMPT는
splat의 사용 가능한 simple_lock 유한 상태 머신의
다섯 가지 기본 상태입니다. 각 상태의 개수는 스레드의 조치가 해당 상태 안으로 결과적으로 전이가 된 횟수입니다. 지속 시간(밀리초)은 잠금 요청이 해당 상태에서 사용한 최소, 최대, 평균 및 총계 시간량을 표시합니다. LOCK: this state represents a thread successfully acquiring a lock.
SPIN: this state represents a thread unsuccessfully trying to acquire
a lock.
WAIT: this state represents a spinning thread (in SPIN) going to sleep
(voluntarily) after exceeding the thread's spin threshold.
UNDISP: this state represents a spinning thread (in SPIN) becoming
undispatched (involuntarily) before exceeding the thread's
spin threshold.
PREEMPT: this state represents when a thread holding a lock is
undispatched.
Lock Activity w/Interrupts Disabled (mSecs)
잠금 세부사항 보고서의 이 섹션은 밀리초로 표시된 시간에
splat이 각 잠금에 대해 수집하는 원시 데이터의 덤프입니다. 여섯 개의 상태: LOCK, SPIN, KRLOCK을 가지는 LOCK, KRLOCK LOCK, KRLOCK
SPIN 및 TRANSFORM은 splat의 사용 불가능한 simple_lock 유한
상태 머신의 여섯 개의 기본 상태입니다. 각 상태의 개수는 스레드의 조치가 해당 상태 안으로 결과적으로 전이가 된 횟수입니다. 지속 시간(밀리초)은 잠금 요청이 해당 상태에서 사용한 최소, 최대, 평균 및 총계 시간량을 표시합니다.LOCK: This state represents a thread successfully acquiring a lock.
SPIN: This state represents a thread unsuccessfully trying to acquire
a lock.
LOCK with The thread has successfully acquired the lock, while holding
KRLOCK: the associated krlock, and is currently executing.
KRLOCK LOCK: The thread has successfully acquired the associated krlock,
and is currently executing.
KRLOCK SPIN: The thread is executing and unsuccessfully attempting to acquire
the associated krlock.
TRANSFORM: The thread has successfully allocated a krlock it associates to,
and is executing.
Function Detail
^^^^^^^^^^^^^^^
The function detail report consists of the following fields:
Function Name The name or return address of the function which
used the lock.
Acquisitions The number of successful lock attempts for this lock.
For complex lock and read/write lock there is a
distinction between acquisition for writing
(Acquisition Write) and for reading
(Acquisition Read).
Miss Rate The number of unsuccessful lock attempts divided by
Acquisitions, multiplied by 100.
Spin Count The number of unsuccessful lock attempts.
For complex lock and read/write lock there is a
distinction between spin count for writing
(Spin Count Write) and for reading
(Spin Count Read).
Wait Count The number of unsuccessful lock attempts that resulted in
the attempting thread going to sleep to wait for the lock
to become available.
For complex lock and read/write lock there is a
distinction between wait count for writing
(Wait Count Write) and for reading
(Wait Count Read).
Transform Count The number of times that a simple lock has allocated a krlock,
while the thread was trying to acquire the simple lock.
Busy Count The number of simple_lock_try() calls that returned busy.
Percent Held of Total Time
CPU The percent of combined elapsed trace time that
threads held the lock in question while dispatched.
DISPATCHED_HOLDTIME_IN_SECONDS divided by trace
duration, multiplied by 100.
Elaps(ed) The percent of combined elapsed trace time that
threads held the lock while dispatched or sleeping.
UNDISPATCHED_AND_DISPATCHED_HOLDTIME_IN_SECONDS divided
by trace duration, multiplied by 100.
Spin The percent of combined elapsed trace time that
threads spun while waiting to acquire this lock.
SPIN_HOLDTIME_IN_SECONDS divided by combined trace
duration, multiplied by 100.
Wait The percentage of combined elapsed trace time that
threads unsuccessfully tried to acquire this lock.
Return Address The calling function's return address in hexadecimal.
Start Address The start address of the calling function in hexadecimal.
Offset The offset from the function start address in hexadecimal.
Thread Detail
^^^^^^^^^^^^^
The thread detail report consists of the following fields:
ThreadID Thread identifier.
Acquisitions The number of successful lock attempts for this lock.
Miss Rate The number of unsuccessful lock attempts divided by
Acquisitions, multiplied by 100.
Spin Count The number of unsuccessful lock attempts.
Wait Count The number of unsuccessful lock attempts that resulted in
the attempting thread going to sleep to wait for the lock
to become available.
Transform Count The number of times that a simple lock has allocated a krlock,
while the thread was trying to acquire the simple lock.
Busy Count The number of simple_lock_try() calls that returned busy.
Percent Held of Total Time
CPU The percent of combined elapsed trace time that
threads held the lock in question while dispatched.
DISPATCHED_HOLDTIME_IN_SECONDS divided by trace
duration, multiplied by 100.
Elaps(ed) The percent of combined elapsed trace time that
threads held the lock while dispatched or sleeping.
UNDISPATCHED_AND_DISPATCHED_HOLDTIME_IN_SECONDS divided
by trace duration, multiplied by 100.
Spin The percent of combined elapsed trace time that
threads spun while waiting to acquire this lock.
SPIN_HOLDTIME_IN_SECONDS divided by combined trace
duration, multiplied by 100.
Wait The percent of combined elapsed trace time that
threads unsuccessfully tried to acquire this lock.
ProcessID Process identifier (only for SIMPLE and COMPLEX Lock report).
Process Name Name of the process (only for SIMPLE and COMPLEX Lock report).Splat 정렬
splat을 사용하여 사용자는
-s 옵션을 사용하여 세부사항 보고서를 잠그고 요약을 정렬하는 데 사용되는 기준을 지정할 수 있습니다. 디폴트 분류 기준은
퍼센트 회전 보류 시간에 따라 분류되고, 이는 결합된 추적 지속 시간과
비교되는 잠금에 대한 회전에 스레드가 사용된 시간의 비율입니다. -s를 사용하여 분류 기준이 다음으로
변경될 수 있습니다.
| 항목 | 설명 |
|---|---|
| a | 획득: 스레드가 잠금 설정된 횟수입니다. |
| c | 퍼센트 프로세서 일시 중단 시간: 결합된 추적 지속 시간을 프로세서 일시 중단 시간의 비율입니다. |
| e | 퍼센트 경과 보류 시간: 결합된 추적 지속 시간이 포함된 경과 보류 시간의 비율입니다. |
| L | 위치: 잠금 또는 함수의 주소 또는 스레드의 ID입니다. |
| M | 상실 비율: 획득 수를 포함하여 잠금 시도가 실패한 비율입니다. |
| s | 회전 횟수: 스레드 회전이 잠금을 대기하게 되는 실패한 잠금 시도의 수입니다. |
| S | 퍼센트 프로세서 회전 일시 중단 시간(디폴트)입니다. |
| w | 퍼센트 경과 시간 대기 시간: 제로가 아닌 스레드 수가 잠금에서 대기한 총 시간의 백분율입니다. |
| 모든 | waitq 행수를 평균화시키십시오. 각 대기 중 스레드가 이 상태에서 소비하는 평균 시간과 동일한 잠금을 기다리는 평균 수의 스레드입니다. |
splat는 내림차순으로 잠금 보고서를 분류하기 위해 지정된 기준을 사용합니다.
제한사항
VMM, XMAP 및 특정 Java 지정 잠금과 같은 기타 유형의 잠금은 분석되지 않습니다.
파일
| 항목 | 설명 |
|---|---|
| /etc/bin/splat | Simple Performance Lock Analysis Tool(splat). 커널 및 pthread 잠금 사용법 보고서를 제공합니다. |