Weird question about OpenCL/SwiftShader (Magical Loop)

Questions about Wine on macOS.
Locked
ZProphete
Newbie
Newbie
Posts: 4
Joined: Sat Feb 04, 2012 3:07 am

Weird question about OpenCL/SwiftShader (Magical Loop)

Post by ZProphete »

Hi guys, I got a really weird questions in my mind...

You probably know, Transgaming Swiftshader is converting on the fly DirectX9 GPU accesses to CPU (aka 100% software rendering).

(With this, wrapped inside Wine, I can start some games that never worked before).

But, software rendering is too slow to play games seriously.

Maybe it's a fool idea, but could Wine share back computation to GPU using OpenCl compiled binaries ?

So it would stand for CPU and GPU helping each others for graphic computing, instead of (in my case) saturate low-end graphic card and waste cpu horsepower.

My specs :
Macpro 3,1 2x Quad 2,8ghz Xeon
6gigs of ram
OSX lion 10.7.3
ZProphete
Newbie
Newbie
Posts: 4
Joined: Sat Feb 04, 2012 3:07 am

Re: Weird question about OpenCL/SwiftShader (Magical Loop)

Post by ZProphete »

ZProphete wrote: Maybe it's a fool idea, but could Wine share back computation to GPU using OpenCl compiled binaries ?
What I meant here, is Wine able to share computation ANY programs ?
BenchPress
Newbie
Newbie
Posts: 1
Joined: Sun Feb 05, 2012 2:21 am

Re: Weird question about OpenCL/SwiftShader (Magical Loop)

Post by BenchPress »

ZProphete wrote:But, software rendering is too slow to play games seriously.
Software rendering with run-time code generation (like SwiftShader) is not "slow". It uses the CPU's capabilities as efficiently as possible. So the software isn't the problem, it's the hardware that makes it slow...

Fortunately next year Intel will release CPUs with the AVX2 instruction set, which adds long-missing features borrowed from GPUs. In particular the 'gather' support makes memory accesses for vectorized code much faster.

Unfortunately this means you need new hardware either way. If your GPU can't run DirectX 9 properly then it also can't run OpenCL. And you'll have to wait for CPUs that are efficient enough for software rendering.
ZProphete
Newbie
Newbie
Posts: 4
Joined: Sat Feb 04, 2012 3:07 am

Re: Weird question about OpenCL/SwiftShader (Magical Loop)

Post by ZProphete »

hi BenchPress,

My idea was pure theory. Not specially using Swiftshader.
My question was

"Can Wine force OpenCL ?"
doh123
Level 8
Level 8
Posts: 1227
Joined: Tue Jul 14, 2009 1:21 pm

Post by doh123 »

sounds a bit weird... forcing graphics to the CPU, and offloading CPU work to the GPU... I don't think that would be nearly as good as directly going to the GPU in the first place.

but... you were able to get OpenCL working ok on Mac OS X with Wine in the first place?
lahmbi5678
Level 7
Level 7
Posts: 823
Joined: Thu Aug 27, 2009 6:23 am

Post by lahmbi5678 »

Speaking about CPU/GPU, I have a computer with i945 graphics, which I really like, because it's stable and doesn't consume much power, but as with other older intel integrated graphics, it wouldn't support games that really require DX 9.0c compatible hardware, as i945 chipsets don't support every DX9 feature in hardware, with i915 it's even worse. The intel drivers for windows implement the missing features in software, so that many games still run with acceptable performance. Certainly it should be intels task to implement the same features in their linux driver, but they probably will never do that.

So the question: Would it be reasonable to expect the wine project to enhance their DX in a such a way, that it called mesa functions, if the linux driver wouldn't support certain functionality? So that in theory every DX9 game would run in wine on intel chipsets?
ZProphete
Newbie
Newbie
Posts: 4
Joined: Sat Feb 04, 2012 3:07 am

Post by ZProphete »

doh123 wrote:sounds a bit weird... forcing graphics to the CPU, and offloading CPU work to the GPU... I don't think that would be nearly as good as directly going to the GPU in the first place.

but... you were able to get OpenCL working ok on Mac OS X with Wine in the first place?
as I said, take the swiftshader part away.

(I was thinking about Swiftshader because of this damn Lineage 2, which never work well on OSX, as I tested the tricked dll, it dosen't show me any error and run (agp texture acceleration error) :!:
I was thinking about redirecting ressources back to gpu to get more framerate.
)

The good question is, can Wine make an OpenCl wrapper around any program to make it GPU friendly or trick it to make it work like co-processor ? It still sound weird but I hope you get the idea.
Locked