performance

Using Interlocked

Is this code thread-safe? or put it this way: Is there anyway to call GetIt() and that GetIt() will return the same number to 2 different threads Private Shared hitCount As Long = 1 Public Shared Function GetIt() As Long Threading.Interlocked.Increment(hitCount) DoSomethingQuick(hitCount) Return hitCount End Function ...

msxml XMLHTTP for large json object works very slow on IE8 and quite good on Firefox - why?

Hi, I am creating an XMLHTTP object in Firefox and IE8 and i transfer a very large amount of data (json). In Firefox it renders it in 5 seconds, in IE8 it takes 30 seconds. Is there any way to make IE8 XMLHTTP works faster? Here is my code for creating the XHR object: function createRequestObject2() { var http_request = false; if(win...

Why a larger table is faster than new smaller one?

We have a large table in SQL Server with almost 40.000.000 records. it took considerable time to running queries on it. so we decided to leave all old and out of date records there and move usable records in a new table an use the new one. while it supposed to be faster than old table which have almost double count of records, the proble...

How do I use async programming in Perl?

Is there a simple way to do async in Perl? I have the following logic for an Apache app: get request process request write to log return what I want to do is to have the "write to log" part to be async, so that I can do the "return" part asap. ...

GWT MouseOver performance

I'm writing an application in GWT. It went really well, until I ran it in IE. I made an application that uses a FlexTable, and each cell of the table was to be highlighted. I wrote the MouseOver handler, but in the Internet Explorer it works incredibly slow. Is there anything I can do about it? ...

Does F# really allow specifying which functions to be inlined in code?

When I am reading F# stuff, they are talking about inlining methods, but I thought .NET didn't expose this functionality to programmers. If it's exposed then it has to be in the IL? And so can C# make use of it as well? Just wondering if this thing is the same as C++ inline functionality. ...

How do I speed up Nant Builds?

Hello, We have a number of Nant scripts which compile .NET code. These builds are taking 5 - 10 minutes to run, and I would like to find a way to speed them up. Our Nant script looks something like <target name="compile.XYZ" description="Compiles the source code"> <msbuild project="${src.dir}\XYZ.sln" verbosity="${build.verbosi...

Do any real-world CPUs not use IEEE 754?

I'm optimizing a sorting function for a numerics/statistics library based on the assumption that, after filtering out any NaNs and doing a little bit twiddling, floats can be compared as 32-bit ints without changing the result and doubles can be compared as 64-bit ints. This seems to speed up sorting these arrays by somewhere on the ord...

Vectorizing for loops in Matlab

I'm not too sure if this is possible, but my understanding of Matlab could certainly be better. I have some code I wish to vectorize as it's causing quite a bottleneck in my program. It's part of an optimisation routine which has many possible configurations of Short Term Average (STA), Long Term Average (LTA) and Sensitivity (OnSense) ...

Application execution slow, on some client machines??

HI Guys, We are providing clickonce solutions to generate reports using Aspose.Slides. and the application works fine in all machines except , for our clients in UK, the application execution is very slow. we thought it might be because of distances to the datacenter, which slows down few downloads, but it even works on lower connectiv...

How to load test website with SWF Flash file?

I have a website that has a SWF embbeded on it with SWFObject. This SWF file has 1,5 MB. I would like to test if website (Lightppd) will be alive if 600 users per hour will try to open it. It will be approx. 900 MB / hour of transfer. So I have 2 questions in one: 1) Does ab (Apache Bench) test handle SWFObject and gets SWF file while...

Will Python use all processors in thread mode?

While developing a Django app deployed on Apache mod_wsgi I found that in case of multithreading (Python threads; mod_wsgi processes=1 threads=8) Python won't use all available processors. With the multiprocessing approach (mod_wsgi processes=8 threads=1) all is fine and I can load my machine at full. So the question: is this Python beh...

Any Performance overhead if the application has more 5000 COM objects?

We do industrial automation application and we need to use VC++ application. As part of that we need windows controls which shall be developed in Visual Basic 6.0. When we run the application with tabbed interfaces, we have approximately 5000 COM objects together. COM object count is expected to grow. Are are any performance overhe...

Efficient querying of multi-partition Postgres table

I've just restructured my database to use partitioning in Postgres 8.2. Now I have a problem with query performance: SELECT * FROM my_table WHERE time_stamp >= '2010-02-10' and time_stamp < '2010-02-11' ORDER BY id DESC LIMIT 100; There are 45 million rows in the table. Prior to partitioning, this would use a reverse index scan and s...

ASP.NET page contains dynamic elements, loading takes time

Hi I am dynamically creating a table of checkboxes on my test.aspx page. The dimensions (row and column count) of the table are determined by querying the database. In test.aspx page, I do the following: <script language="C#" runat="server"> protected void Page_Load ( object src, EventArgs e ) { //Query the database to get the dat...

Need a sufficiently long & complex Markdown document for performance testing

I'm looking for a long and complex Markdown document that I can use to test performance of different markdown implementations -- as an alternative to iterative benchmarking of a simple document. I thought I might be able to browse around Stack Overflow and find something, but by and large everything I find is pretty simply written; and ...

mysql performance degrades after increasing data stored. Need hints on systematic diagnostic procedure

We have an established web application, which is supported by a mysql database. We add data incrementally to various tables on a monthly basis. After recent updates, the database performance has degraded significantly and we had to back out the updates. So far I have identified the queries involved in the web service logic - there are no...

Performance of Reading from a file vs. an ArrayList

I have to use a thousands of data read off from a file, and use the data hundreds of times repetitively in order to train and test my AI algorthm. Right now, I have two possible solutions. One is to keep reading off directly from the file everytime I need to use the thousands of data. The other one is to read off from the file and store...

EventLogReader Remote Performance

I am using the EventLogReader to query remote 2008 servers for events. The performance of querying the events on a remote machine is horrible (6/sec). If I query the same machine via WMI using a forward-only ManagementObjectSearch the performance is great (1000/sec). I don't see any similar options on the EventLogReader (e.g. ReturnImmed...

C or C++ for OpenGL graphics

Hi, there is any drawback in choose C++ and an object oriented model (classes) to implement a simulation in OpenGL (or DirectX)? It's preferred to use C and a procedural programming paradigm ? ...