We have a web service which provides search over hotels. There is a problem with performance: a single request to the service takes around 5000 ms. Almost all of the time is spent in database by executing storing procedures. During the request our server (mssql2008) consumes ~90% of the processor time. When 2 requests are made in paral...
Hello everyone:
I'm now trapped by a performance optimization lab in the book "Computer System from a Programmer's Perspective" described as following:
In a N*N matrix M, where N is multiple of 32, the rotate operation can be represented as:
Transpose: interchange elements M(i,j) and M(j,i)
Exchange rows: Row i is exchanged w...
I have three questions about three nested loops:
for (int x=0; x<400; x++)
{
for (int y=0; y<300; y++)
{
for (int z=0; z<400; z++)
{
// compute and store value
}
}
}
And I need to store all computed values. My standard approach would be to use a 3D-array:
values[x][y][z] = 1; // test v...
In Rails 'helper :all' makes all your helpers 'available' to all your controllers.
This is concise and convenient, but does it have any memory and/or performance implications compared to explicitly calling the helpers that each controller actually needs?
It's unclear form the docs whether using it involves 'require'ing all those files,...
I'm creating an application that will tell a user how far away a large number of points are from their current position.
Each point has a longitude and latitude.
I've read over this article
http://www.movable-type.co.uk/scripts/latlong.html
and seen this post
http://stackoverflow.com/questions/837872/calculate-distance-in-meters-when-...
I would like to know what the best way (performance wise) to access a large data structure is.
There are about hundred ways to do it but what is the most accessible for the compiler to optimize?
One can access a value by
foo[someindex].bar[indexlist[i].subelement[j]].baz[0]
or create some pointer aliases like
sometype_t* tmpfoo = &f...
I;m using Lucene.net (2.9.2.2) on a (currently) 70Gig index.. I can do a fairly complicated search and get all the document IDs back in 1 ~ 2 seconds.. But to actually load up all the hits (about 700 thousand in my test queries) takes 5+ minutes.
We aren't using lucene for UI, this is a datastore between processes where we have hundreds...
WPF
Windows-XP SP3
I'm having a problem with a simple WPF animation.
I use the following Xaml code (in XamlPad and also in a WPF project):
<Page xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:sys="clr-namespace:System;assembly=mscorlib" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" >
<Border Nam...
Hi,
I have a xml as below that I'd like to copy n times while incrementing one of its element and one of its attribute.
XML input:
<?xml version="1.0"?>
<header xmlns="http://test.com" >
<Batch>
<test document="dump" >
<Person position=1>
<properties>
<name>John</name>
<number>1</number>
</properties>
</Person>...
Hi
I am looking for an alternative to Test Professional/Team Server that hopefully is free.
They can be multiple tools/ hosted tools(hosted might be better).
What I am looking to do is
Load Testing.
Performance Test( So I need something that can simulate like users on the site so I can see how my site handles with 50 users, then 50...
I'm using the DownloadFileAsync method of WebClient to download some files from a server, and I can't help but notice that in my informal testing of my code within VS2010, it blocks for about 3 seconds while it starts, which, in my opinion kind of defeats the purpose in the first place.
Here is the relevant snippet of code:
WebClient ...
I saw and done myself a lot of small products where a same piece of software is separated into one executable and several DLLs, and those DLLs are not just shared libraries done by somebody else, but libraries which are done exclusively for this software, by the same developer team. (I'm not talking here about big scale products which ju...
Hi,
I'm currently measuring the time spent to load a web page from a C# program.
The Visual Studio solution has a console program and an ASP.NET website with just one page. The website is hosted on ASP.NET Development Server. The console application queries the web page like this:
bool isSuccess;
Stopwatch timeSpentToDownloadPage = S...
I am using SQL Server 2008 and we are using the DMV's to find missing indexes. However, before I create the new index I am trying to figure out what proc/query is wanting that index. I want the most information I can get so I can make informed decision on my indexes. Sometimes the indexes SQL Server wants does not make sense to me. ...
Linux uses COW to keep memory usage low after a fork, but the way Perl 5 variables work in perl seems to defeat this optimization. For instance, for the variable:
my $s = "1";
perl is really storing:
SV = PV(0x100801068) at 0x1008272e8
REFCNT = 1
FLAGS = (POK,pPOK)
PV = 0x100201d50 "1"\0
CUR = 1
LEN = 16
When you use tha...
I was wondering which type would have better performance and which you think should be used.
For example I have a List of strings not knowing how many items I will need so having the .Add(String) function is really convenient. I can Add new strings to the list at any time easily.
What are the advantages/disadvantages of using each?
A...
I've Googled and poked around the Go website, but I can't seem to find an explanation for Go's extraordinary build times. Are they products of the language features (or lack thereof), a highly optimized compiler, or something else? I'm not trying to promote Go; I'm just curious.
...
I was trying to test the performance difference between inserting into a table directly versus inserting into a view in a different database which points to the table. I was shocked to see that a WHILE loop with 10,000 inserts into a simple table took 3 seconds but against the view it took 30 seconds.
As I investigated, I found that if ...
Hi,
We currently have a system with 20 SOA services and having a single master mysql database and 2 slave nodes. We currently have 10 GB of data in the database. We have a requirement in which the data in a table is going to be significantly increased. We want to stress test the system before proceeding with the implementation. What kin...
Hello Experts,
what is the performance characteristic for Unique Indexes in Mysql and Indexes in general in MySQl (like the Primary Key Index):
Given i will insert or update a record in my databse: Will the speed of updating the record (=building/updating the indexes) be different if the table has 10 Thousand records compared to 100 Mi...