performance-tuning

Descending sort order indexes

The Database Engine Tuning Advisor has finally given up the ghost and can't help me any more, so I'm having to learn a little bit more about indexes (shouldn't it be indices?). I think I'm more or less there. I know when to use composite indexes, what to include with my indexes, the difference between clustered and non-clustered indexe...

What are some good code optimization methods?

I would like to understand good code optimization methods and methodology. How do I keep from doing premature optimization if I am thinking about performance already. How do I find the bottlenecks in my code? How do I make sure that over time my program does not become any slower? What are some common performance errors to avoid (e.g.;...

What are good tools to take IO measurements and discover bottlenecks on linux?

I'm trying to do some tuning for Oracle on Linux boxes living on SAN based infrastructure. I'm looking specifically for tools that would allow us to profile IO per process (or per process tree would be even better). My questions are? What are the tools that would be recommended for this kind of task? What other useful metrics should I ...

Can I do delayed execution in ASP? Or: please offer any help on improving performance of an old ASP site

I'm trying to improve the performance of a website written in classic ASP. It supports multiple languages the problem lies in how this was implemented. It has the following method: GetTranslation(id,language) Which is called all over the shop like this: <%= GetTranslation([someid],[thelanguage]) %> That method just looks up the ID...

Postgresql: deleting rows with column that references the same table takes bizzare amount of time

Sorry for a pretty specific question. I have a table (see bottom), and when I try to delete a lot of records from it, my PostgreSQL 8.2.5 spends 98% of the time doing the parent-child constraint. I'm trying to figure out what index should I add to make it go fast. I have to say that all columns on this table have either 0 or null as the...

Is there anyway to monitor one single (class) of object in terms of cache?

I am trying to determine which implementation of the data structure would be best for the web application. Basically, I will maintain one set of "State" class for each unique user, and the State will be cached for some time when the user login, and after the non-sliding period, the state is saved to the db. So in order to balance the db ...

MSSQL: Does last_user_update mean that the index hurt performance?

I've written a query to look for indexes that are not used in the production environment in order to drop them, however I'm curious whether the last_user_update column is an indication that the index was solely a maintenance overhead, in which case it would be good to drop it, or whether the index helped the performance of the insert/upd...

How would you write this algorithm for large combinations in the most compact way?

The number of combinations of k items which can be retrieved from N items is described by the following formula. N! c = ___________________ (k! * (N - k)!) An example would be how many combinations of 6 Balls can be drawn from a drum of 48 Balls in a lottery draw. Optimize this formula to run with the smallest ...

How to benchmark apache with delays?

What is a good way to benchmark apache with a delay between requests from a unix command line? The only benchmark tool I know from the command line is ab and it doesn't support delays. ...

using Mysql Query Profiler to know the execution time of the queries and the performance in php script

I would like to use mysql query profiler in the php script. So that after i execute any queries it need to display the execution time of the query. Suggest the best way to use this also share any other scripts like query profiler. ...

Speeding up jQuery empty() or replaceWith() Functions When Dealing with Large DOM Elements

Let me start off by apologizing for not giving a code snippet. The project I'm working on is proprietary and I'm afraid I can't show exactly what I'm working on. However, I'll do my best to be descriptive. Here's a breakdown of what goes on in my application: User clicks a button Server retrieves a list of images in the form of a data...

D3D10 (DirectX10) fullscreen performance issue

I have a bit of a problem setting up my DirectX10 (Win32/c++) application for fullscreen mode. The problem is that I want to have my app running in fullscreen right from the start. This can be done by taking the DXGISwapChain::SetFullScreenState function. This works, but i get a small notice in my Visualc++ 2008 debugger which states: ...

SQL Server SELECT statements causing blocking

We're using a SQL Server 2005 database (no row versioning) with a huge select statement, and we're seeing it block other statements from running (seen using sp_who2). I didn't realise SELECT statements could cause blocking - is there anything I can do to mitigate this? ...

Java app that uses a lot of memory. Use -Xmx?

I have a java app that uses about 15G on a machine with 16G. I don't know if I should set the max heap size. If I set will the jvm eat all the ram up to the limit and then start garbage collecting and stop everything while it churns through 15G or heap objects? If I don't will the jvm hurt performance by not using all of the availab...

Is there a mod_top version for windows? if not is there an equivalent tool?

Does anyone know which version of mod_top I can use for windows server 2003? I want a performance monitoring tool for PHP based web application. thanks ...

Tuning Tomcat memory and cpu consumption

Hello all. I have a Java web application that works a lot with file conventions. I am using Tomcat 6 as my servlet container. When many requests are submitted, Tomcat becomes very memory hungry. I wonder how I can fine-tune tomcat to reduce the memory consumption. I am also considering changing my servlet container. What do you suggest? ...

How can I improve WMI performance in .NET?

I've inherited code that makes numerous remote WMI calls. When I repeatedly pause execution and look at the call-stack it's almost always in a ManagementScope.Connect() call. A new connection seems to be made with each WQL query. Despite limited trial and error, I haven't found any big wins yet in improving the performance of the WMI ...

Are primitive data types in PHP passed by reference?

In PHP, I'm frequently doing lots of string manipulation. Is it alright to split my code into multiple functions, because if primitive types like strings are passed by value I would be significantly affecting performance. ...

Poor performance by overriding Java class?

I have the following class subclass of FilterInputStream with only one method overrided. However the performance of this class is so poor. It performs at 1/10 the speed of its superclass. I even took the same source code from InputStream of javasrc and used it in my subclass. Same performance hit. Is there something wrong with overriding...

What is the difference between a hash join and a merge join (Oracle RDMBS )?

What are the performance gains/losses between hash joins and merge joins, specifically in Oracle RDBMS? ...