I've just upgraded some old Java source which has been running on a Sun Java 1.4.2 VM to Sun Java (JRE) 6 VM. More or less the only thing I had to change was to add explicit datatypes for some abstract objects (Hashmap's, Vector's and so on). The code itself it quite memory intensive, using up to 1G of heap memory (using -Xmx1024m as a p...
Hi folks,
the other day a colleague of mine stated that using static classes can cause performance issues on multi-core systems, because the static instance cannot be shared between the processor caches. Is that right? Are there some benchmarks around proofing this statement? This statement was made in the context of .Net development (w...
The basic requirement is pass to some command type and execution time (possibly other data as well, but that's the basic data we're concerned with at the moment) from C# code (either managed code or something that can take data periodically from the command line. and perform some statistical analysis on it: avg time for each command type...
We are considering switching from Adobe Flex to Silverlight because Flex is just too slow.
I'm interested not in graphical performance, but computational performance and the speed at which it executes code.
Does anyone have any anecdotes to share about their experience of Silverlight performance?
Thanks
...
I'd thinking about using an external web site performance tool to monitor the load time of our site through time.
I found webmetrics.com. Seems pretty ok with email reports etc.
Any other suggestions? I'm looking for biggest value / $ :)
...
In c#/VB.NET/.NET which loop runs faster for or foreach?
Ever since I read that for loop works faster than foreach a long time ago I assumed it stood true for all collections, generic collection all arrays etc.
I scoured google and found few articles but most of them are inconclusive (read comments on the articles) and open ended.
Wha...
I'm writing a financial application in C# where performance (i.e. speed) is critical. Because it's a financial app I have to use the Decimal datatype intensively.
I've optimized the code as much as I could with the help of a profiler. Before using Decimal, everything was done with the Double datatype and the speed was several times fas...
When you have code like the following:
static T GenericConstruct<T>() where T : new()
{
return new T();
}
The C# compiler insists on emitting a call to Activator.CreateInstance, which is considerably slower than a native constructor.
I have the following workaround:
public static class ParameterlessConstructor<T>
where T :...
In Java, what are the performance and resource implications of using
System.currentTimeMillis()
vs.
new Date()
vs.
Calendar.getInstance().getTime()
As I understand it, System.currentTimeMillis() is the most efficient. However, in most applications, that long value would need to be converted to a Date or some similar object to ...
I have a long running function in MATLAB that I tried to speed up by adding caching and wound up slowing down my performance significantly. My code is basically searching for continuous "horizontal" lines in an edge detected image and the original code looks something like this:
function lineLength = getLineLength(img, startRow, startC...
I have to work on some code that's using generic lists to store a collection of custom objects.
Then it does something like the following to check if a given object's in the collection and do something if so:
List<CustomObject> customObjects;
//fill up the list
List<CustomObject> anotherListofCustomObjects;
//fill it up
//...
foreach...
Hi all,
We have a number of web servers, each running one version of Coldfusion. The cluster has a load balancer on front of it.
Obviously each of these servers has it's own CF application running and this implements query caching at the CF application level. However, since all of these servers service the one web application, many o...
I've got about 100 unit tests and with a coverage of %20, which I'm trying to increase the coverage and also this is a project in development so keep adding new tests.
Currently running my tests after every build is not feasible they takes about 2 moments.
Test Includes:
File read from the test folders (data-driven style to simula...
I am writing a program that does a lot of writes to a Postgres database. In a typical scenario I would be writing say 100,000 rows to a table that's well normalized (three foreign integer keys, the combination of which is the primary key and the index of the table). I am using PreparedStatements and executeBatch(), yet I can only manag...
I have been trying to improve the performance of a web page that references several separate javascript files. I found the new CompositeScript feature in .Net 3.5 SP1 that allows you to combine scripts at runtime through the ScriptManager and it works great to reduce the number of hits on our server at page load.
But the problem is tha...
Please note the Edit below for a lot more information, and a possible solution
We recently modified a large Delphi application to use ADO connections and queries instead of BDE connections and queries. Since that change, performance has become terrible.
I've profiled the application and the bottleneck seems to be at the actual call to...
a question that a co-interviewer asked in interviews. I always thought it was a silly question.
Assume single processor and not dual core.
...
I've got shared hosting on a LAMP set up. Obviously the fewer calls to the Db per page the better. But how many is too many? Two? Ten? A hundred? Curious what people think.
...
In perfmon in Windows Server 2003, there are counter objects to get per-process processor time and memory working set statistics. The only problem is that in an environment with multiple application pools, there is no way to reliably identify the correct worker process. In perfmon, they are all called "w3wp", and if there is more than on...
I am using http remoting in C# to talk between two applications.
Earlier when I was running both applications on a single machine/two machines, it was very slow.
We have a proxy server to connect to the internet. We set "Bypass proxy server for local addresses" in IE and now when I run both applications on one machine the communication ...