Wine cause more cpu usage and freeze program for a couple of seconds

Hi, i am facing a strange issue with wine. I am using ubuntu 14, 17 and 18 and in all version same thing, app which works perfeclty suddenly slow down, and i see that use too much CPU. First, i was thinking that memory is the problem, but now i am thinking that cpu is main problem.
I have a various hardware configuration, all have 4GB ddr3 or ddr4 RAM, and all have intel cpu dual core. GPU mainly intel integrated, but have AMD RADEON and NVIDIAs
I tried with ryzen3 also, but same there. Dont seem that hw is problem. I tried and reinstall whole system.
Things I tried:

export __GL_THREADED_OPTIMIZATIONS=1

export GPU_MAX_HEAP_SIZE="100"

export GPU_MAX_ALLOC_PERCENT="100

cpulimit -l 20 wine MyProgram.exe

%sudo   ALL = (ALL) NOPASSWD: /usr/bin/cpulimit
echo 3 > /proc/sys/vm/drop_caches && swapoff -a && swapon -a

Also tried things from:
Link
Link1

Don't have idea what to try.
maybe someone had similar issue?

echo 3 > /proc/sys/vm/drop_caches && swapoff -a && swapon -a

This advice, wherever you got it, is especially harmful. Cache is a good thing! You want to have cache around.

Whatever your application is doing, is bound to be related to what your application is; what is it?

program is like lottery, quiz with numbers, and problem within app the same not seems to be. No update was in that period when slowing start.
Must be somewhere in linux. Don't have a clue where to start. Can I maybe somehow force app to use more gpu, not cpu, or something ike that...Not have much ideas.

It could be a threading problem. You could try limiting the program to a single CPU.

taskset --cpu-list 1 cpulimit -l 20 wine MyProgram.exe

Hi tomislav9...

I think Corona688 is asking for the app name that you are using under Wine.

(As English is not your native language...)

What is the application that you are using?
What is the Wine version that you are using?

app is our interly.

--- Post updated at 04:45 PM ---

I will try, and let you know results, but as far as i know wine is using only one core, am i right?

I found

in Link

WINE is nothing but a library and has nothing to do with how many cores the EXE uses. I've experienced programs that had to be run in one core under WINE because it was multithreading when it shouldn't have been.

ok, thanks for info.
I will try it and let you know. Any other idea is good :slight_smile:
maybe some logs orsomething. I get netdata on workstation and monitor specs, maybe to catch a problem.

--- Post updated at 04:59 PM ---

wine is 2.4, in some i updated to 4.3, but no lucky also.

it didnt help, now is even slower as far as customers told me.
one cpu is AMD Ryzen 3 2200G
another is Intel(R) Pentium(R) CPU G4400

Is support for i386 architecture properly configured?

What says:

$ sudo dpkg --print-foreign-architectures

Should reply i386

Ref: Install wine on Ubuntu - The proper way - PCsuggest

 sudo dpkg --print-foreign-architectures
i386

this is a way i installed wine

 #  wine
        sudo dpkg --add-architecture i386
        sudo add-apt-repository ppa:wine/wine-builds
        sudo apt-get update
        sudo apt-get install --install-recommends winehq-devel
        winecfg