Re: NVDA running on a budget laptop


Gene
 

What sort of cases are there where noticeable improvements in NVDA might be made by making some of the changes discussed?  As I use it, delays are so slight that I haven’t even given them more than very passing thought.  And those are very slight delays on an eleven year old machine.  I don’t know if they are even noticeable now on today’s faster machines, I mean typical consumer machines.
 
Gene

-----Original Message-----
From: Joseph Lee
Sent: Sunday, May 16, 2021 8:25 PM
Subject: Re: [nvda] NVDA running on a budget laptop
 

Hi,

Cython might help to make NVDA code compile under a C++ compiler such as Microsoft Visual C++ compiler, but then it will raise questions such as dealing with C extensions and how to make NVDA’s own (Python) code more efficient. Transforming NVDA into a pure 64-bit program will require that we use 64-bit Python interpreter, but then we run into the same problem that 32-bit NVDA is facing, although in the opposite direction.

As for using CPU instructions such as Advanced Vector Extensions (AVX), it comes down to the workload to be run by Python interpreter. I imagine C++ components could benefit from that if Visual C++ compiler can be told to use AVX instructions, but then it depends on how NVDA performs its tasks internally (AVX is mostly used for calculation intensive tasks such as scientific computing, which is not really the use case for a screen reader unless the screen reader algorithms do require working with many things that require up to 512 bits to store many components). Ultimately, since NVDA is a Python-based screen reader, it will come down to if Python interpreter can even take advantage of newer instructions for executing bytecode on the spot.

More importantly, consider that not all CPU’s support AVX and newer instructions. It took Microsoft until 2012 to require that processors support SSE2 (ten years after its appearance). Although most processors support SIMD (single instruction, multiple data) commands, only some high-end processors support AVX, AVX2, and parts of AVX-512, and tech press articles (and according to some sources, Linus Torvalds) argue that AVX instructions are power-hungry (understandable as millions of transistors are dedicated to vector instructions).

Therefore, the standpoint of NV Access (as communicated by Quentin and others) and lead contributors (including soon to be former ones like myself) is that we should target the vast majority of configurations that are in use at a given time (that’s one of the reasons for delaying end of support for Windows 7; due to a critical issue with Python 3.8 and later, that decision is uncertain at this time); at this time, this means supporting a processor with at least SSE2.

Cheers,

Joseph

 

From: nvda@nvda.groups.io <nvda@nvda.groups.io> On Behalf Of enes saribas
Sent: Sunday, May 16, 2021 6:07 PM
To: nvda@nvda.groups.io
Subject: Re: [nvda] NVDA running on a budget laptop

 

Hi Joseph,

Would cythonizing NVDA improve this situatuation though? Or making a native 64 bit version to talk to 64 bit apps?  Also, isn't one reason for the CPU usage NVDA not utilizing the newer processor  instruction sets being developed by Intel/AMD?  Are there any new processor extention sets that would make NVDA more responsive if used?

On 5/16/2021 7:21 PM, Joseph Lee wrote:

Hi,

Enes’s claim is understandable, considering that:

  1. Speech synthesizers do require resources such as CPU to translate text into speech using whatever rules manufacturers and users define.
  2. Most NVDA components run on top of a Python interpreter. This means in order to perform screen reading operations, Python interpreter must be willing to process screen reader instructions on top of housekeeping tasks such as garbage collection. Some NVDA components are written in C++ for faster performance and communication with apps, but still Python is invoked for housekeeping operations.
  3. NVDA must talk to many “people” i.e. API’s and apps at once. Although folks spent years optimizing accessibility API’s and communication between apps (in computer science, this whole thing is termed “inter-process communication”), communication with API’s and apps is still an expensive step that involves processors switching between running app and system codes. If it takes some time to send and receive messages between two 32-bit programs, imagine how long it will take for a 32-bit app such as NVDA to get useful info out of 64-bit apps (this involves formatting bits in a way that allows these two programs to eventually communicate through an intermediary called WoW64).

 

One important clarification: let us not equate screen readers to text-to-speech engines (don’t confuse between the two). Although TTS does contribute to screen reading performance (namely rules used to translate text into waveforms or hardware signals), what’s more important in this overall context (screen readers running on a class of hardware) is how efficient screen reading instructions can get, keeping in mind that NVDA is running on top of an interpreter. There are limits as to how power efficient an algorithm can become, as the overall limit is optimizations from the host (in NVDA’s case, not only optimizations from Windows, but also ongoing optimization work done by Python core developers and third-party library/C extension authors). Also, although not addressed here, you can’t just state that making screen readers multi-core aware will bring improvements – it depends on years of effort spent on parallelization and optimizing the screen reader to not only take advantage of at least two cores at once, but also to make itself more efficient when running as a multi-core aware application (power draw from a single core versus multiple cores does play a part here); I have learned the hard way that you will face more unexpected bugs when you make a program run with multiple threads and hardware cores.

Cheers,

Joseph

 

From: nvda@nvda.groups.io mailto:nvda@nvda.groups.io On Behalf Of enes saribas
Sent: Sunday, May 16, 2021 4:58 PM
To: nvda@nvda.groups.io
Subject: Re: [nvda] NVDA running on a budget laptop

 

I'm sorry. 6-10% CPU power is alot of system resources.

On 5/16/2021 11:50 AM, Gene wrote:

Nothing I’ve seen convinces me that NVDA itself uses a lot of computing power.  nor have I seen this with screen-readers in general to the small extent I’ve checked.  Its using the newer synthesizers that uses a lot of computing ;power.  If you want to use the newer voices, I can’t comment on the minimum specifications to get good performance but in the old days, I had machines that today would be laughably underpowered, running Windows 95 and Windows 3.1 and Via Voice, very similar to Eloquence, ran well.  This was in a 166MHZ, not GHZ, Pentium machine and in an even older and less powerful machine running Windows 3.1. 

 

As for NVDA using a lot of computing power, if I monitor use when I’m typing text with carachter echo on in the Windows Task manager, I get low numbers.  I just checked and while moving up and down the list in task manager, then pressing f5 to refresh the screen, I get a 6 percent CPU reading.  When typing in this e-mail message, alt tabbing immediately to the task manager and refreshing the screen, I get a 10 percent usage reading.

 

I’m not saying there won’t be variations, but those figures are close to what I generally get when I test doing these things.

 

And I haven’t seen complaints about the performance of NVDA from people using tablets. 

 

Gene

-----Original Message-----

Sent: Sunday, May 16, 2021 7:20 AM

Subject: Re: [nvda] NVDA running on a budget laptop

 

I would do a minimum of 8gb of ram, and a current gen i5/r5. That is as low as you should go. Even with those specs, NVDA is heavy on CPU usage.

On 5/15/2021 7:36 PM, Brian Vogel wrote:

Personally, I would not even consider running Windows 10 with less than 8 GB of RAM.  Nor would I consider a Celeron processor, for anything, these days.

I'd invest a bit more for additional memory and a better processor.  You might also consider a refurbished business-class laptop, which can be had at very reasonable prices (or at least could prior to the pandemic - everything's getting more expensive as supply is constrained).
--

Brian - Windows 10 Pro, 64-Bit, Version 20H2, Build 19042  

Always remember others may hate you but those who hate you don't win unless you hate them.  And then you destroy yourself.

       ~ Richard M. Nixon

 

Join nvda@nvda.groups.io to automatically receive all group messages.