amd-gfx.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
From: Javad Karabi <karabijavad@gmail.com>
To: "Michel Dänzer" <michel@daenzer.net>
Cc: Alex Deucher <alexdeucher@gmail.com>,
	amd-gfx list <amd-gfx@lists.freedesktop.org>
Subject: Re: slow rx 5600 xt fps
Date: Sun, 24 May 2020 20:03:03 -0500	[thread overview]
Message-ID: <CAEOHGOnPZgMbD_Rr75x6wnCS2TbeNWvZdTWpv0o57Tbo=2eYzQ@mail.gmail.com> (raw)
In-Reply-To: <dc6af43c-07bb-e334-79f7-80b4cb5135a8@daenzer.net>

Michel, ah my bad! thank you. sorry, thought it was mutter

also, one other thing. so i have been messing around with all types of
xorg configuration blah blah blah, but i just had an epiphany, and it
works!

so, all i ever needed to do was add Option "PrimaryGpu" "true" to
/usr/share/X11/xorg.conf.d/10-amdgpu.conf
with that _one_ change, i dont need any other xorg configs, and when i
boot without the amdgpu, it should work just fine, and when the amdgpu
is present it will automatically become the primary due to the
outputclass matching it!

that PrimaryGpu being added was exactly the thing. im so glad it works now

So, these are my thoughts:
theres no telling what other graphics cards might be installed, so
xorg defaults to using whatever linux was booted with as the primary,
in my case the intel graphics i guess.

now, on a regular desktop, thats totally fine because the graphics
card has direct access to ram much easier, and with fancy things like
dma and whatnot, its no problem at all for a graphics card to act as a
render offload since the card  can simply dma the results into main
memory or something

but when you got the graphics card in an eGPU, across a thunderbolt
connection, it essentially because NUMA, since that memory access has
way more latency

so the fact that the debian package isnt saying "PrimaryGpu" "true" i
guess makes sense, becuase who knows what you want the primary to be.

but yea, just thought yall might be interested to know that the
solution for running an egpu in linux is simply to add "PrimaryGpu" to
the output class that matches your gpu.
and when you boot without the gpu, the outputclass wont match, so it
will default to normal behavior

also, lets say you have N number of gpus, each of which may or may not
be present. from what i understand, you can still enforce a level of
precedence about picking which one to be primary like this:

"If multiple output devices match an OutputClass section with the
PrimaryGPU option set, the first one enumerated becomes the primary
GPU."

so one can simply define a file in which you define N number of
outputclasses, in order from highest to lowest precedence for being
the primary gpu, then simply put Option "PrimaryGpu" "true"

i realize this isnt an xorg list, and doesnt have much to do with
amdgpu, but would love to hear yalls thoughts. theres alot of
discussion online in forums and whatnot, and people coming up with all
kinds of "automatic xorg configuration startup scripts" and stuff to
manage egpus, but if my hypothesis is correct, this is the cleanest,
simplest and most elegant solution


On Sat, May 23, 2020 at 5:17 AM Michel Dänzer <michel@daenzer.net> wrote:
>
> On 2020-05-23 12:48 a.m., Javad Karabi wrote:
> >
> > also, the whole thing about "monitor updating once every 3 seconds"
> > when i close the lid is because mutter will go down to 1fps when it
> > detects that the lid is closed.
>
> Xorg's Present extension code ends up doing that (because it has no
> support for secondary GPUs), not mutter.
>
>
> --
> Earthling Michel Dänzer               |               https://redhat.com
> Libre software enthusiast             |             Mesa and X developer
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

  reply	other threads:[~2020-05-25  1:03 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-19 18:59 slow rx 5600 xt fps Javad Karabi
2020-05-19 19:13 ` Alex Deucher
2020-05-19 19:20   ` Javad Karabi
2020-05-19 19:44     ` Javad Karabi
2020-05-19 20:01       ` Javad Karabi
2020-05-19 21:34         ` Alex Deucher
2020-05-19 21:13       ` Alex Deucher
2020-05-19 21:22         ` Javad Karabi
2020-05-19 21:42           ` Alex Deucher
2020-05-20  1:16             ` Javad Karabi
2020-05-20  1:19               ` Javad Karabi
2020-05-20  1:20               ` Bridgman, John
2020-05-20  1:35                 ` Javad Karabi
2020-05-20  2:29               ` Alex Deucher
2020-05-20 22:04                 ` Javad Karabi
2020-05-21  3:11                   ` Alex Deucher
2020-05-21 19:03                     ` Javad Karabi
2020-05-21 19:15                       ` Alex Deucher
2020-05-21 21:21                         ` Javad Karabi
2020-05-22 22:48                           ` Javad Karabi
2020-05-23 10:17                             ` Michel Dänzer
2020-05-25  1:03                               ` Javad Karabi [this message]
2020-05-25  1:29                                 ` Javad Karabi
2020-05-19 21:32     ` Alex Deucher

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAEOHGOnPZgMbD_Rr75x6wnCS2TbeNWvZdTWpv0o57Tbo=2eYzQ@mail.gmail.com' \
    --to=karabijavad@gmail.com \
    --cc=alexdeucher@gmail.com \
    --cc=amd-gfx@lists.freedesktop.org \
    --cc=michel@daenzer.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).