Questions related to improving application performance, this can be range from selection software architecture to selection of algorithms.

learn more… | top users | synonyms

5
votes
2answers
317 views

Structuring Access Control In Hierarchical Object Graph

I have a Folder entity that can be Moderated by users. Folders can contain other folders. So I may have a structure like this: Folder 1 Folder 2 Folder 3 Folder 4 I have to ...
8
votes
3answers
493 views

When is it a good time to reason about performance in Haskell?

Simon Peyton Jones himself recognizes that reasoning about performance in Haskell is hard due to the non strict semantics. I have yet to write a significant project in haskell so I wonder: can I ...
8
votes
2answers
369 views

Is there a comparative study of the memory consumption of programming languages runtimes, correlated with expressiveness and production bug ratios? [closed]

There are many comparative studies and available online when it comes to the runtime performance of applications built using one language or another. Some driven by corporations, some academic, some ...
4
votes
4answers
2k views

Server-side vs Client-side web application Performance [closed]

I am an entry level programmer with only a few months of experience. Yesterday I was discussing with a colleague how we can improve the performance of a project we are working on together. The ...
0
votes
0answers
72 views

Efficient Copy While Sorting

I have an algorithms library called NDex. I am in the process of upgrading it to a new version. Part of this upgrade involves providing two versions of many algorithms: an in-place version and a ...
6
votes
4answers
540 views

Is it a performance hit to create threads that loop a lot to check for things?

This is a generic question that I've always wondered. In general, is it intensive for a CPU to create threads that perform "while not true ..." loops or similar? For example, suppose I do: // ...
0
votes
2answers
196 views

The best way of coding web system in term of performance [closed]

So far I've been using IPB and my custom scripts all coded in PHP but I am really disappointed of the long term performance of it. I would like to move to native coding, the learning time to put into ...
-1
votes
5answers
460 views

The emperor's new code, or: how to communicate code efficiencies [closed]

So you've made some code changes that should hopefully speed up some part of an application. But there is just one problem - you don't know how it will perform in live. Different networks, different ...
5
votes
1answer
284 views

How can I benchmark concurrent key-value stores?

I have some concurrent key-value store implementations that are implemented with hash tables and search trees that I would like to compare. I would like to benchmark them with a real world application ...
3
votes
2answers
479 views

How is it possible to build the whole codebase from source at Google scale?

The first answer to an old, recently active question linked to a video which talks about how Google repository is done. One interesting thing which was mentioned is the fact that everything is build ...
1
vote
1answer
193 views

parallel computing list of objects

I have a list of objects that all require the exact same filtering, basically a set of conditionals in a function which outputs if the object is "good" or "bad". I want to keep all of my "good" ...
6
votes
4answers
300 views

Issues to be considered while loading jQuery?

I have seen many answers in SO regarding using Google's CDN to load jQuery instead of loading it from the local server. In essence I understand this is the issue related with decreased latency, ...
0
votes
1answer
88 views

How to find the running time of an algorithm that involves heuristics

I am working with A* algorithm, in which I have a 2D grid and given two points, find the shortest distance between them, while not running into any obstruction. Now, for each cell, I find the ...
4
votes
2answers
408 views

caching on multiple servers

Because we need to keep response times low, we get tons of requests, and we need to basically process ALMOST the same data (which I'll refer to as X) each request (the inputs are different though, so ...
5
votes
3answers
428 views

Performance considerations when using Go for my project

I'm looking at using Go (aka golang) for a project (a SQL database, but that mostly doesn't matter here) where performance is critical, but under low load the primary bottleneck will be I/O to disk. ...
0
votes
2answers
955 views

How to find local maxima in matrices?

I need to develop an algorithm for finding all the local maxima in a two-dimensional array: how to search for local maxima in the the most efficient way? Are there algorithms about it? Moreover, the ...
-1
votes
1answer
165 views

Banking Applications need Auto save? [closed]

We are developing a banking application. It's internal project of the bank. The application has to capture huge data to process. So auto save is recommended approach to capture? How to perform ...
1
vote
1answer
677 views

Performance overhead of standard containers and boost [closed]

Adap.TV has chosen C++ to develop their software. However, they've decided not to use the standard containers1 and boost for performance reasons, as they've blogged about it in the following article: ...
2
votes
3answers
988 views

Anonymous function performance - setTimeout

According to Gregory Baker & Erik Arvidsson (Google), creating a named function and then passing that to setTimeout is actually faster than creating an anonymous function (reference: Optimizing ...
4
votes
2answers
1k views

Performance and other issues with using floating point types in C++

Being interested in C++ performance programming there is one aspect I really have no clue about- and that is the implications of using floating point calculations vs doubles vs normal integer ...
4
votes
3answers
424 views

How Immutable Sets are Manipulated

When working with an immutable set or map, like the ones found in many functional programming languages, operations that would otherwise modify the container generate a new container instead. I know ...
0
votes
4answers
646 views

Read K&R before learning low latency C++?

I have never really done a large amount of C programming but am in the middle of teaching myself low latency C++. Would it do more harm than good to read the K&R C programming book? I am a bit ...
2
votes
1answer
449 views

Is there's a way to speed up my php code which parse XML files

I'm developing a web application and we are using XML as a database and I'm using Linux as a platform and centos 6.5 as a server. Changing some value would make a lot a lot of changes in about six XML ...
4
votes
1answer
734 views

How much usage of “likely” and “unlikely” macros is too much?

The often known as likely and unlikely macros help the compiler know whether an if is usually going to be entered or skipped. Using it results in some (rather minor) performance improvements. I ...
1
vote
2answers
677 views

C++ Typecasting VS performance

Let's say we're designing a video game. We have some sprites on the map and we want to call some method of the particular sprite at some particular position. We are using one broadly-known C++ ...
1
vote
1answer
274 views

Table scaling with partitions or with separate databases?

Let's say I have a table (let's call it BigTable) which could experience 5,000,000 INSERTS per day (with possibly just as many SELECTs). Each row inserted is about 50kb. These daily INSERTs are ...
6
votes
3answers
711 views

A question regarding linked list vs vector insert/remove results comparison

I was reading this blog post: http://kjellkod.wordpress.com/2012/02/25/why-you-should-never-ever-ever-use-linked-list-in-your-code-again/ and I found there a code to run: http://ideone.com/62Emz ...
2
votes
1answer
467 views

How best to merge/sort/page through tons of JSON arrays?

Here's the scenario: Say you have millions of JSON documents stored as text files. Each JSON document is an array of "activity" objects, each of which contain a "created_datetime" attribute. What is ...
2
votes
1answer
467 views

Internationalization through SQL Database and performance issues

I'm using .Net technologies and because ASP.Net "instant translation" is not really easy to do with ResX, since it has to be compiled after every change, there are a few hacks available ...
3
votes
2answers
1k views

Why is NoSQL better for this scenario?

Hypothetical scenario: Let's say we are downloading JSON from Facebook with details of a user's friend's checkins, posts, etc... These come in as one document per friend per activity, so with 8 ...
7
votes
4answers
7k views

What is the point of using lists over vectors, in C++?

I've run 3 different experiments involving C++ lists and vectors. Those with vectors proved more efficient, even when a lot of insertions in the middle were involved. Hence the question: in which ...
7
votes
3answers
479 views

Does javascript support numerically indexed arrays with a more optimized algorithm than an associative array?

I know that Python, Perl, Java, Lua and obviously C (as it's the only array that's in ANSI standard afaik) support faster looking of numerically indexed arrays than doing a hash lookup or anything ...
2
votes
1answer
226 views

How to communicate inefficiency before it's implemented?

This is a problem I come across pretty often. Basically we are using an application to make art content. Often times this requires writing custom tools for it. Sometimes you run into parts of the ...
4
votes
4answers
229 views

What performance topics should I be aware of? [closed]

When coding performance-critical portions of code (not necessarily large, but code that gets executed a lot), what topics should I be aware of/take into account. I'm already fairly familiar with ...
1
vote
2answers
556 views

Parsing a Log File - Java

Im reading a log file in Java on a Linux box on a continual schedule of 2 minutes looking for certain messages. I store the last offset (RandomAccessFile getFilePointer) and read from it onwards when ...
3
votes
1answer
389 views

Java Logfile Parsing Assistance

I'm writing a log parser that continuously looks for specific patterns and then fires off events to another system when it finds these matches. The firing of the event is time critical to catch errors ...
4
votes
2answers
4k views

Low Latency Unix/Linux

Most low latency/high frequency programming jobs (based on job specs) appear to be implemented on unix platforms. In a lot of the specs they make particular request for people with "low latency linux" ...
2
votes
1answer
1k views

Cost of setInterval in Javascript

I've got some code that I want to run when certain HTML elements are added to the page. To do this, I have a "runOnRender" function: runOnRender: function (func, args, interval) { var ...
7
votes
2answers
382 views

Shared Cache - Invalidation Best Practice

I'd like to know what would be a better approach to invalidate/update cache objects. Prerequisites Having remote memcached server (serving as cache for multiple applications) All servers are hosted ...
3
votes
1answer
315 views

Aggregate Root and Lots of Data Efficiency

It's more of a scenario, but it isn't far fetched at all. Let's say I have an Aggregate Root (AR) Warehouse which it's used to manage product stock. The Product itself is an AR in a different bounded ...
1
vote
1answer
271 views

Effective implementation of “array” of type Int X String -> String in .NET or in general

The question in general is: is there a more effective way of implementation of table with structure like Dictionary<int, Dictionary<string, string>>? The reason I am asking this is ...
6
votes
2answers
385 views

Versioned Resources to Improve Cacheability

Here's an API concept which could be useful for performance optimisation. It's an example of key-based cache expiry applied to a broader internet-wide context instead of the internal Memcached-style ...
8
votes
3answers
387 views

Would it be better to have extra checks, or would it be a waste of time?

In your opinion, do you think it is a waste of time to make checks that you know there is no possible way of it being there/not being there, or would you just put it there just in case there is a bug ...
3
votes
2answers
693 views

Memory management for fast message passing between threads in C++

Suppose there are two threads, which communicate by asynchronously sending data messages to each other. Each thread has some kind of message queue. My question is very low level: What can be expected ...
4
votes
4answers
501 views

Having error codes option in C++ library for performance

I have written an open source and cross-platform C++ File Library which have exception and error codes. Exceptions can be disabled when the program is running. In that case, the user have to check the ...
22
votes
5answers
894 views

Multiple database accesses or one massive access?

What is a better approach when it comes to performance and optimal resource utilization: accessing a database multiple times through AJAX to only get the exact information needed when it is needed, or ...
11
votes
8answers
1k views

Does low latency code sometimes have to be “ugly”?

(This is mainly aimed at those who have specific knowledge of low latency systems, to avoid people just answering with unsubstantiated opinions). Do you feel there is a trade-off between writing ...
0
votes
2answers
688 views

Idea to develop a caching server between IIS and SQL Server

I work on a few high traffic websites that all share the same database and that are all heavily database driven. Our SQL server is max-ed out and, although we have already implemented many changes ...
3
votes
3answers
314 views

Is it ok to ignore poor performance for a resource that will be cached?

Let's say I have a web service that is poorly written and inefficient, but it's output is cached so there's no bottleneck. Do you just leave it? Would you go as far as to take deliberate shortcuts ...
2
votes
2answers
161 views

Browser support for internal corporate tools

We are on the verge of a conversion. For years, our company supported only IE for its internal (intranet) home-built tools. Since a few of our users are still on XP, which means IE only goes up to ...