<html><head><style>body{font-family:Helvetica,Arial;font-size:13px}</style></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;"><div id="bloop_customfont" style="font-family:Helvetica,Arial;font-size:13px; color: rgba(0,0,0,1.0); margin: 0px; line-height: auto;">On November 5, 2015 at 03:15:47, Janusz (<a href="mailto:januszmk6@gmail.com">januszmk6@gmail.com</a>) wrote:</div> <div><blockquote type="cite" class="clean_bq" style="font-family: Helvetica, Arial; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;"><span><div><div></div><div>Hi,<span class="Apple-converted-space"> </span><br>I have two questions,<span class="Apple-converted-space"> </span><br>Sometimes I have some short freezes and fps drops in GTA 5, so I wanted<span class="Apple-converted-space"> </span><br>to try hugepages if it would give me better perfornance, but in fact it<span class="Apple-converted-space"> </span><br>gave me -10 fps and drops to 20-30 fps (while without it I have 60 with<span class="Apple-converted-space"> </span><br>drops to 40). Did anyone experiecned worst performance with hugepages?<span class="Apple-converted-space"> </span><br>maybe I am doing something wrong?<span class="Apple-converted-space"> </span><br>my script: https://bpaste.net/show/9089719cbef8<span class="Apple-converted-space"> </span></div></div></span></blockquote></div><p>Hi Janusz,</p><p>Have you tried allocating and mounting the hugepages early at boot? As far as I know, hugepages would be more beneficial if it has contiguous space and we can guarantee it if it is allocated as early as possible. I think there’re 2 ways to do that:</p><p>1. Passing <font face="Courier">hugepages=N</font> parameter to kernel command (defaults to 2 MB page size)</p><p>2. Passing <font face="Courier">options vm.nr_hugepages = N</font> to <font face="Courier">sysctl</font> config</p><p>Currently I use the first option. I don’t know how to correctly verify the performance boost after enabling hugepages other than feels a bit responsive  overall. </p><p>I also tried to use transparent hugepages (<font face="Courier">transparent_hugepages=always</font>) since sometimes I need to launch a VirtualBox image for my work so I need as much free memory as possible. The Windows 10 VM was quite stable using it. Though Alex explicitely did not recommend using transparent hugepages for GPU passthrough VM, so I revert back to using traditional hugepages. http://vfio.blogspot.com/2015/05/vfio-gpu-how-to-series-part-4-our-first.html</p><p>I also tried using 1 GB page size for hugepage (<font face="Courier">default_hugepagesz=1G hugepagesz=1G hugepages=16</font>) but I noticed a very annoying flickering on the display. Reverting back to use 2 MB page size solved the issue.</p><div><div><blockquote type="cite" class="clean_bq" style="font-family: Helvetica, Arial; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;"><span><div><div><br><br>Second question, I know this is vfio group but I don't know where else<span class="Apple-converted-space"> </span><br>would be better to ask, becauseeverywhere where I asked, no one know how<span class="Apple-converted-space"> </span><br>to fix it. I am using pulseaudio and I have some audio glitches, some<span class="Apple-converted-space"> </span><br>crackles, don't know exactly how to describe it... It looks like VM is<span class="Apple-converted-space"> </span><br>affecting my audio even before OVMF loads (starting VM) and it happens<span class="Apple-converted-space"> </span><br>the whole time when I get some sound from VM. anyone know what can cause<span class="Apple-converted-space"> </span><br>this? I tried different soundhw, sometimes I didn't get any disortion in<span class="Apple-converted-space"> </span><br>the sound, but then the sound was behind something like 1 second. I have<span class="Apple-converted-space"> </span><br>the same frequency in pulsaudio set like in windows settings. I even<span class="Apple-converted-space"> </span><br>bought usb sound card, to passthrough it and redirect this sound from VM<span class="Apple-converted-space"> </span><br>into my main sound card - poor quality. also tried streaming from<span class="Apple-converted-space"> </span><br>windows by linco, ssh and pacat - got some delays, port of pulseaudio<span class="Apple-converted-space"> </span><br>for windows - didn't managed to make it work... I know there is one more<span class="Apple-converted-space"> </span><br>alternative - Jackd, but maybe someone have idea how to fix it before I<span class="Apple-converted-space"> </span><br>start looking in jackd configuration...<span class="Apple-converted-space"> </span><br>I also tried without pulseaudio on host, just alsa, and didn't helped<span class="Apple-converted-space"> </span><br><br>My hw:<span class="Apple-converted-space"> </span><br>msi z170a m7, i7 6700k, r9 290<span class="Apple-converted-space"> </span><br><br><br>Thanks<span class="Apple-converted-space"> </span></div></div></span></blockquote></div><p>I experienced a noticable but random lagging on the audio when I use PulseAudio as the audio backend for the VM. At that time I used the HDA device with additional PulseAudio sample environment variables on the QEMU script. Now I’m using Alsa as the audio backend and using AC97 sound on the QEMU. It didn’t autodetected on my Windows 10 VM, but I googled for it and I found the driver and it is working very stable. The audio is crystal clear and no lag whatsover. I think this is the driver that I use: <a href="http://www.driverscape.com/download/intel%28r%29-82801db-dbm-ac--97-audio-controller">http://www.driverscape.com/download/intel%28r%29-82801db-dbm-ac--97-audio-controller</a> Although some people said that there’s no driver for AC97 in 64-bit, mine works flawlessly and my Windows 10 is a 64-bit VM. </p><p>I did not search for Realtek AC97 at first, since I noticed that from <a href="http://www.linux-kvm.org/page/Sound">http://www.linux-kvm.org/page/Sound</a> AC97 is an Intel 82801AA AC97, so I googled for “Intel 82801AA AC97 windows” and since the first link (from Intel) didn’t work for me, I used the second one (<a href="http://driverspace.com">driverspace.com</a>).</p><p><br></p><p>Best regards,</p><p>Okky Hendriansyah</p></div></body></html>