Project

General

Profile

Actions

Bug #14089

closed

gfx_private: do not read from WC memory

Added by Toomas Soome 3 months ago. Updated 2 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
kernel
Start date:
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:
Gerrit CR:

Description

gfx_private does read+update on framebuffer memory to draw glyphs and cursor. This does hurt the performance. Instead, update the shadow buffer first and write prepared data from shadow buffer to framebuffer, eliminating reads from WC memory.

Testing results (limited tests in sense that I only have one physical host) with screen scroll - all the output was done on last line and causing screen scroll by one line:
Before patch:

root@beastie:/code/illumos-gate# time cat /etc/passwd >/dev/console

real    0m0,458s
user    0m0,001s
sys     0m0,458s
root@beastie:/code/illumos-gate# time cat /etc/passwd >/dev/console

real    0m0,459s
user    0m0,001s
sys     0m0,458s
root@beastie:/code/illumos-gate# time cat /etc/passwd >/dev/console

real    0m0,459s
user    0m0,001s
sys     0m0,458s
root@beastie:/code/illumos-gate# time cat /etc/passwd >/dev/console

real    0m0,459s
user    0m0,001s
sys     0m0,458s
root@beastie:/code/illumos-gate# 

After patch:

root@beastie:/home/tsoome# time cat /etc/passwd >/dev/console

real    0m0,021s
user    0m0,001s
sys     0m0,021s
root@beastie:/home/tsoome# 
root@beastie:/home/tsoome# time cat /etc/passwd >/dev/console

real    0m0,022s
user    0m0,001s
sys     0m0,022s
root@beastie:/home/tsoome# time cat /etc/passwd >/dev/console

real    0m0,023s
user    0m0,001s
sys     0m0,022s
root@beastie:/home/tsoome#

Same test without scroll before patch:

root@beastie:/home/tsoome# time cat /etc/passwd >/dev/console

real    0m0,081s
user    0m0,001s
sys     0m0,080s
root@beastie:/home/tsoome# time cat /etc/passwd >/dev/console

real    0m0,081s
user    0m0,001s
sys     0m0,080s
root@beastie:/home/tsoome#

And after patch:

root@beastie:/home/tsoome# time cat /etc/passwd >/dev/console

real    0m0,005s
user    0m0,001s
sys     0m0,004s
root@beastie:/home/tsoome# time cat /etc/passwd >/dev/console

real    0m0,004s
user    0m0,001s
sys     0m0,004s
root@beastie:/home/tsoome#

Tests were performed on 1600x1200x32 framebuffer.

As reported by Garrett D'Amore:

Before:

root@habsr02:~# time cat /etc/issue > /dev/console

real    0m12.934s
user    0m0.001s
sys     0m12.933s

After:

root@habsr02:~# time cat /etc/issue >/dev/console

real    0m0.080s
user    0m0.001s
sys     0m0.079s


Related issues

Related to illumos gate - Bug #14280: loader: use shadow framebufferIn ProgressToomas Soome

Actions
Actions

Also available in: Atom PDF