In day to day programs I wouldn't even bother thinking about the possible performance hit for coding against interfaces rather than implementations. The advantages largely outweigh the cost. So please no generic advice on good OOP.
Nevertheless in this post, the designer of the XNA (game) platform gives as his main argument to not hav...
I've learned that to have a singleton lazy loading, this is the pattern to use:
private MyObject()
{
}
public static MyObject Instance
{
get { return SingletonCreator.CreatorInstance; }
}
private static class SingletonCreator
{
private static readonly MyObject _instance = new MyObject();
public static MyObject CreatorInst...
I can test for the presence of a key in an NSDictionary in two ways:
BOOL containsKey = [[dictionary allKeys] containsObject:foo];
BOOL containsKey = ([dictionary objectForKey:foo] != nil);
which method is faster? Please show your work.
...
I am trying to find information on glibc and to what extent it uses SSE functionality.
If it is optimized, can I use it out-of-the-box?
Say I am using one of the larger Linux distros, I assume that its glibc is compiled to be as generic as possible and to be as portable as possible, hence not optimized?
I am particular interested in ...
Lately I've been favoring using named pipes (option --enable-named-pipes) in MySQL running on windows, and connect via the .NET connector driver. It's often recommended for security purposes, but one thing it allows me to do is connect with "." as the connection string and develop on my PC and deploy to the server without having to chan...
I use Catalyst (MVC framework for Perl), but the question probably apply to all MVC framework.
Until now, I used the Apache log files to get statistics about the visitors: user agent, URL accessed, time, etc. But now that I moved to an MVC framework, I don't think this is adequate. If a request to /1/foo and /1/bar are the same for me, ...
Our service tends to fall asleep during the nights on our client's server, and then have a hard time waking up. What seems to happen is that the process heap, which is sometimes several hundreds of MB, is moved to the swap file. This happens at night, when our service is not used, and others are scheduled to run (DB backups, AV scans etc...
I did notice the statement on Subsonics page that it can handle 100000+ files, but we would need to handle information for up to 1 million songs. Do we know what the 100000 limitation is from -- is it based on database speed, hard drive capacity, or is that simply all that it has been tested with?
Could you share some proven examples ab...
Is they say that sun's java is opensource now - then can I compile all the patform from sources ?
I used gentoo and I found a great performance inmrovement wnen I compiled the system myself, so can it be done with java (both vm runtime and library classes ) ?
Is it possible to do under windows/linux ?
Did anyone do it ?
Does it make ...
I have a number data-driven web based applications that serve both internal and public users and would like to gauge how fast you would expect a page to be created (in milliseconds) in order to maintain user satisfaction and scalability.
So, how fast does a page have be created to maintain a fast site?
The sites are developed in ASP cl...
I have a very strange behavior with Request.Form.
Here are two IIS 7 servers running the same ASP.NET application. On the first instance it's all ok. But the second one have very slow performance.
Profiler showed that this line:
context.Request.Form["id"]
takes more than 130 ms each time!
Profiler log:
0,60% get_Form - 4536 ms - 6...
I am interested in learning how to write extremely efficient network server software and I don't mind getting my hands dirty with pointers, sockets and threading. I'm talking a server being able to handle thousands of concurrent connections. There is not much processing for each client, but a little.
Do you know of any code examples for...
I have a background thread that performs I/O operations (keeping an index up to date). But in addition to that several clients access the server's hard disk and I want these accesses as fast as possible. So I thought, it would be nice, if the indexing thread is only running when the I/O load is low.
Is there a way to figure this out?
I...
Hi, I have a library of a few "custom controls". Essentially we have our own buttons, rounder corner panels, and a few groupboxes with some custom paint. Despite the "math" in the OnPaint methods, the controls are pretty standard. Most of the time, all we do is draw the rounded corners and add gradient to the background. We use GDI+ for ...
What are some good tips and/or techniques for optimizing and improving the performance of calculation heavy programs. I'm talking about things like complication graphics calculations or mathematical and simulation types of programming where every second saved is useful, as opposed to IO heavy programs where only a certain amount of speed...
What's the fastest way to enumerate through an integer and return the exponent of each bit that is turned on? Have seen an example using << and another using Math.Pow. Wondering if there is anything else that's really fast.
Thanks.
...
Have other people here played with SQL Server 2008 Compression at either the page or the row level on their datasets much? What have your impressions been on performance both speed and disk-space wise?
Has anyone ever seen compression demonstrably hurt performance?
On some of our huge fact tables we've been playing around and noticing...
Hi
I have done some simple changes to the scheduler in the Linux Kernel. Now, I would
like to see how those changes affect the response time of the system; in other words,
I would like to know how long a context switch takes with my modifications compared to the original scheduler. A straightforward approach would be to use the time st...
I have a Database that contains data about articles,structures and manufacturers. Meaning an article is linked to 1 manufacturer and to N structure-nodes (think as article-classification-nodes).
Querying articles using T-SQL with a lot of conditions is currently too slow to be usable for an e-shop, even with good hardware and properly i...
Application:
WPF Application consisting of a textbox on top and a listbox below
Users type a string in the TextBox to find employees, and search results are displayed in the ListBox
ListBox uses DataTemplates to display elements (shows employee name, department, phone and a thumbnail picture.)
Implementation:
At application startu...