I am working on a little card-swapping world-travel game that I sort of envision as a cross between Bejeweled and the 10 Days geography board games. So far the coding has been going okay, but the frame rate is pretty bad... currently I'm getting low 20's on my Core 2 Duo. This is a problem since I'm creating the game for Intel's March de...
I have a TabActivity with three tabs defined. The first tab is light-weight and renders in acceptable time. But the 2nd and 3rd tab, does need a couple of seconds to get visually rendered, after I click them. I would like to launch them, after I've loaded my first tab, in background for pre-cache. Once they are loaded, I can switch quick...
I am developing a WPF application that talks to a server via WCF services over the internet. After profiling the application I noticed a lot of time is being taking up by creating the appropriate WCF client proxy and making the call to the server.
The code on the server is optimised and doesn't take any time to run yet I am still seein...
I have a 'server' program that updates many linked lists in shared memory in response to external events. I want client programs to notice an update on any of the lists as quickly as possible (lowest latency). The server marks a linked list's node's state_ as FILLED once its data is filled in and its next pointer has been set to a valid ...
Update
As suggested by many people, it looks like this was because of the fact that clojure code was first compiled and then executed. AOT compilation should help offset that. Given I found the practical Clojure AOT compilation process a little tricky to solve (classpath issues, directory issues et al), I've written up a small step by s...
I think that the zipper is a beautiful idea; it elegantly provides a way to walk a list or tree and make what appear to be local updates in a functional way.
Asymptotically, the costs appear to be reasonable. But traversing the data structure requires memory allocation at each iteration, where a normal list or tree traversal is just po...
Greets-
We gots a few nutters in work who enjoy using
while(true) { //Code }
in their code. As you can imagine this maxes out the CPU. Does anyone know ways to reduce the CPU utilization so that other people can use the server as well.
The code itself is just constantly polling the internet for updates on sites. Therefore I'd im...
I'm considering introducing:
if ([myInstance isKindOfClass:[SomeClass class]]) { do something...}
into a piece of code that gets called pretty often. Will I introduce a significant performance penalty? In Objective C, is there a quicker way of assessing whether a given object instance is of certain class type? For example, is the f...
I am currently working on an image processing application. The application captures images from a webcam and then does some processing on it. The app needs to be real time responsive (ideally < 50ms to process each request). I have been doing some timing tests on the code I have and I found something very interesting (see below).
clearL...
Let's say I have this query:
select * from table1 r where r.x = 5
Does the speed of this query depend on the number of rows that are present in table1?
...
I am developing a simple ASP.Net application on a Windows 7 x64 machine using Visual Studio 2008 SP1. The computer itself is a very strong machine.
I am using the built in development server for debugging.
Starting the debug process takes a mindblowingly long time (~20 minutes until the first page is loaded). Sometimes the pages load im...
Hello
What is the cost of the atomic operation (any of compare-and-swap or atomic add/decrement)? How much cycles does it consume? Will it pause other processors on SMP or NUMA, or will it block memory accesses?
Will it flush reorder buffer in out-of-order CPU?
What effects will be on the cache?
I'm interested in modern, popular CPUs...
I need to send byte[] array using WCF services and I care about message size and performance. My question is: Does WCF convert my binary data to Base64 string internally? (I use netTcpBinding) If it does, how to prevent it?
My contract looks almost as simple as
IMyService
{
byte[] GetData()
}
...
Hi,
I've been using javamail to retrieve mails from IMAP server (currently GMail). Javamail retrieves list of messages (only ids) in a particular folder from server very fast, but when I actually fetch message (only envelop not even contents) it takes around 1 to 2 seconds for each message. What are the techniques should be used for fast...
I want to test the profile usage of an important library-class of my rails-project. It uses ActiveRecord so I need all rails dependencies to profile it.
As far as I know, I need a patched ruby (rubygc) so script/profile and script/benchmark can track memory usage. I tried to follow this official guide to patch the source code of ruby 1....
I have a loaded XDocument that I need to grab all the attributes that equal a certain value and is of a certain element efficiently. My current
IEnumerable<XElement> vm;
if (!cacher2.TryGetValue(name,out vm)) {
vm = project.Descendants(XName.Get(name));
cacher2.Add(name, vm);
}
XElement[] abdl = (vm.Where(a => a.Attribute(at...
According to Marcin Ciura's Optimal (best known) sequence of increments for shell sort algorithm,
the best sequence for shellsort is 1, 4, 10, 23, 57, 132, 301, 701...,
but how can I generate such a sequence?
In Marcin Ciura's paper, he said:
Both Knuth’s and Hibbard’s sequences
are relatively bad, because they are
defined by sim...
An inexperienced question:
I need to store about 10 unknown-length text fields per record into a MySQL table. I expect no more than 50K rows in total for this table but speed is important. The database actions will be solely SELECTs for all practical purposes (and searches will be done using an integer PK id only). I'm using InnoDB.
In...
I was thinking about the performance of calling List<T>.Indexof(item). I am not sure if it will be a O(n) performance for a sequential algorithm or O(log(n)) performance for a binary tree??
Thanks!
...
Hi everyone,
Im looking for the best solution (performance wise) to achieve this.
I have to insert records into a table, avoiding duplicates.
For example, take table A
Insert into A (
Select DISTINCT [FIELDS] from B,C,D..
WHERE (JOIN CONDITIONS ON B,C,D..)
AND
NOT EXISTS
(
SELECT * FROM A ATMP WHERE
ATMP.SOMEKEY = A.SOM...