Changing Memory& CPU usage in Windows 7 - windows

I want to test with a windows machine with low performance hard wares. Unfortunately I have a higher end machine. Is there a way to limit the performance of CPU and RAM memory usage? Can I do it through any other software or is there way through windows OS itself?

You can use VMWare to limit memory. You won't be able to limit processor speed in your virtual machine but you can assign only 1 core to it.

Try CPUKiller - software for limiting CPU performance.
You can use the truncatememory boot options to limit the amount of memory available usable by Windows. See BCDEdit /set (MSDN)

Related

Low hardware simulation for performance profiling

I need to optimize the app I'm working on and I can't get reliable profiling data on my development machine. The app should run on low end ARM hardware on QNX, but from logistic reasons I don't have access to the final hardware for profiling.
I've tried to do profiling on my development machine, but as you can imagine everything is so fast that I can't pin point the slow parts. I've created a Linux virtual machine with reduced memory and CPU cores count, but they are still too fast compared to the final hardware.
Is it possible to reduce the CPU clock speed/ram speed/disk speed in a virtual machine to simulate low performance hardware or is there any other way to get relevant profiling data on my development machine?
Considering the app is processing several gigabytes of data I assume disk access is a major bottleneck and limiting disk speed might help
I can use any (as in most open source and commercially available) tool/approach that runs on Windows/Linux/MacOS on real or virtual machine.
This URL describes how to limit disk bandwidth on VirtualBox images. You could run a Linux VM on Virtualbox and use this method to limit disk access speeds, turn off Disk Caching using suggestions from this answer and profile your application. Alternatively you can download QNX SDP, which comes with the option of a prebuilt x86_64 Virtual Machine image that can be run using VMWare/Virtualbox/qemu
My previous experiences with QNX on armv7 and x86_64 suggest that the devb-sdmmc driver is possibly a bottleneck when working with a lot of big files being read from flash storage. devb-sdmmc and io-blk often require fine tuning of the drivers with proper cache, block, read-ahead size and other parameters helps improve disk access performance.

Does JVM memory management work the same on Windows and Linux?

My original question is that, is this technically rational to check the required heap-size of my Java program on Windows 7, via VisualVM, and come to this conclusion that the program will require the same amount of heap on Linux(RedHat) as well?
I don't know how the system(OS or even CPU and RAM), affect memory management of JVM.
well, the windows is my development system with 4GB of RAM and a Core 2 Due CPU, however the
Linux is the production system with 32GB of RAM and multiple powerfull processors,
Actually, my concern is that the program on Linux might need more memory. less is ok.

CPU utilization of virtual machine

I have one physical machine which has 4 CPUs. I want to have some VM on it. The goal of my work is finding CPU utilization. But I am confused how the CPU usage of VMs and physical machine are related. Is there a relation between CPU utilization of VMs and physical machine? How should I measure the CPU utilization of each VM? What is the CPU utilization of the physical machine?
If you are using any xen enabled hypervisor, you can use xenmon or xentop in your Dom0(physical machine) to check the utilization or performance of your VMs.
You can do so by typing xentop(it is /usr/sbin/xentop in my case) on the command line which will give you all the info you are looking for. Alternatively you can use xenmon -l command (/usr/sbin/xenmon.py python script) in my case which shows all the live information about your VMs.

Decreasing performance of dev machine to match end-user's specs

I have a web application, and my users are complaining about performance. I have been able to narrow it down to JavaScript in IE6 issues, which I need to resolve. I have found the excellent dynaTrace AJAX tool, but my problem is that I don't have any issues on my dev machine.
The problem is that my users' computers are ancient, so timings which are barely noticable on my machine are perhaps 3-5 times longer on theirs, and suddenly the problem is a lot larger. Is it possible somehow to degrade the performance of my dev machine, or preferrably of a VM running on my dev machine, to the specs of my customers' computers?
I don't know of any virtualization solutions that can do this, but I do know that the computer/CPU emulator Bochs allows you to specify a limit on the number of emulated instructions per second, which you can use to simulate slower CPUs.
I am not sure if you can cpu bound it, but in VirutalBox or Parallel, you can bound the memory usage. I assume if you only give it about 128MB then it will be very slow. You can also limit the throughput on the network with a lot of tools. I guess the only thing I am not sure about is the CPU. That's tricky. Curious to know what you find. :)
You could get a copy of VMWare Workstation and choke the CPU of your VM.
With most virtual PC software you can limit the amount of RAM, but you are not able to set the CPU to a slower speed as it does not emulate a CPU, but uses the host CPU.
You could go with some emulation software like bochs that will let you setup an x89 processor environment.
You may try Fossil Toys
* PC Speed
PC CPU speed monitor / benchmark. With logging facility.
* Memory Load Test
Test application/operating system behaviour under low memory conditions.
* CPU Load Test
Test application/operating system behaviour under high CPU load conditions.
Although it doesn't simulate a specific CPU clock speed.

Visual studio on windows xp

i need to run a few visual studios on windows XP and it seems to take up a lot of memory. i am also running resharper which is a memory hog.
i am running 32 bit XP. How much memory can i put into my machine until i get to the point where the OS hits its limit.
Also, any other ways of running multiple visual studio without such slow performance.
32-bit Operating Systems are limited to 4 GB of RAM, which may or may not be enough for you. Also, I think Windows shows 3 GB of RAM if you install 4 GB.
I suggest you switch to 64-bit and upgrade to 8 GB if you can.
UPDATE: See Jeff's blog post on the subject: Dude, Where's My 4 Gigabytes of RAM?
The maximum amount of memory that can be seen by 32bit WinXP is somewhere between 3 and 4 gigabytes depending on your chipset.
I have also run into issues running multiple instances of VS when I had resharper installed. The only thing you can do is run 64bit XP with more memory, or not use resharper (which is a bummer).
32-bit Windows kernel divides the 4GB virtual addressing space in 2GB/2GB partitions. If you feed the /3GB switch to NTLDR it will offer 1GB kernel space / 3GB user mode space. Note that this NOT implies that you can't write software to take advantage of machines with 32-bit CPUs and address more than 4GB at once.
A workaround is the hardware-supported feature to access the remaining memory in banks or "windows" since the CPU still sees a maximum of 4GB addressable space at once. Some database and GIS software offer this possibility. This is called Physical Address Extensions and allows to use (not addressing at once) up to 64GB with 36-bit addresses. WinXP offers AWE, an API built on top of PAE.
That's the theory. For using Visual Studio you can get the full 4GB for your system or upgrade to a 64-bit OS with more RAM. This only if VS offers a 64-bit version.
"Also, any other ways of running multiple visual studio without such slow performance."
+1 trick: you should use a RAM disk (download) to accelerate I/O.
If you're using - and hopefully do - source-managament system (ie. Subversion), you must just checkout your projects there. VS.NET makes tons of I/O calls, and RAM disks are much faster than real disks.
CAUTION! If you turn off your computer, RAM Disk disappers.

Resources