Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
neo
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
2
Merge Requests
2
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
Kirill Smelkov
neo
Commits
ea1e0835
Commit
ea1e0835
authored
Sep 29, 2017
by
Kirill Smelkov
1
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
X found that cpuidle can be affecting latency a lot!
parent
3605b9a4
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
0 deletions
+24
-0
go/neo/t/neotest
go/neo/t/neotest
+24
-0
No files found.
go/neo/t/neotest
View file @
ea1e0835
...
...
@@ -384,6 +384,13 @@ pyver() {
printf
"# %-16s: %s
\n
"
"
$showas
"
"
$ver
"
}
# fkghz file - extract value from file (in KHz) and render it as GHz
fkghz
()
{
v
=
$(
echo
"scale=2;
`
cat
$1
`
/ 1000000"
|bc
-l
)
echo
"
${
v
}
GHz"
}
# lspci1 <pcidev> <field> - show <field> from lspci information about <pcidev>
lspci1
()
{
lspci
-vmm
-s
$1
|grep
"^
$2
:
\\
s*"
|sed
-e
"s/^
$2
:
\\
s*//"
...
...
@@ -393,7 +400,24 @@ lspci1() {
header
()
{
echo
-n
"# "
;
date
--rfc-2822
echo
"#
`
whoami
`
@
`
hostname
--fqdn
`
(
$myaddr
)"
;
# cpu
# XXX review and read about CPU idle states more
echo
-n
"# cpu: "
;
grep
"^model name"
/proc/cpuinfo |head
-1
|sed
-e
's/model name\s*: //'
find /sys/devices/system/cpu
-name
"cpu[0-9]*"
|
sort
-n
|
\
while
read
cpu
;
do
cpuname
=
`
basename
$cpu
`
f
=
"
$cpu
/cpufreq"
echo
"#
$cpuname
:"
echo
-e
"#
\t
Fscale:
`
cat
$f
/scaling_governor
`
[
`
fkghz
$f
/scaling_min_freq
`
-
`
fkghz
$f
/scaling_max_freq
`
]"
echo
-e
"#
\t
energy:
`
cat
$f
/energy_performance_preference
`
"
echo
-en
"#
\t
idle/latency:"
find
$cpu
/cpuidle
-name
"state[0-9]*"
|
sort
-n
|
\
while
read
state
;
do
echo
-n
"
`
cat
$state
/name
`
(
`
cat
$state
/latency
`
μs)"
done
echo
done
# disk under .
mntpt
=
`
stat
-c
'%m'
.
`
# mountpoint of current filesystem
...
...
Kirill Smelkov
@kirr
mentioned in commit
a60c472c
·
Jul 12, 2018
mentioned in commit
a60c472c
mentioned in commit a60c472c76da315f918afeb06f994c8610cf7c84
Toggle commit list
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment