I want to separate the digits of an integer, say 12345, into an array of bytes {1,2,3,4,5}, but I want the most performance effective way to do that, because my program does that millions of times.
Any suggestions? Thanks.
...
Can you give me some advice on how to best ensure that two applications (one in C#, the other in Java) will be compatible and efficient in exchanging data? Are there any gotchas that you have encountered?
The scenario is point to point, one host is a service provider and the other is a service consumer.
...
I'm trying to figure out what I might be doing wrong. This query doesn't seem to be using the index, as its taking way to long.
When executing:
Explain SELECT a, b, c, d FROM `table` WHERE d = 4013456
id select_type table type possible_keys key key_len ref rows Extra`
1 SIMPLE table ALL...
Core Animation uses a background thread to do it's job. Now the problem is this: I have a heavy calculation going on in the main thread. Core Animation immediately freezes until that calculation is done. And then it continues to finish it's animations. I remember reading in a document that CA has a low priority in processing time, meanin...
I have a JavaScript application which opens an ExtJS Window, containing an ExtJS TabPanel, which has a tab containing a Data Grid, showing approximately 900 - 1000 rows, each with 7 columns of text fields. The grid may also be filtered to show about 100 rows at a time. When the window opens, navigating to this tab can cause Firefox or Sa...
Experimenting with Ruby's Benchmark module...
>> Benchmark.bm(7) { |b| b.report('Report:') { s = '' ; 10000.times { s += 'a' } } }
user system total real
Report: 0.150000 0.010000 0.160000 ( 0.156361)
What are the meanings of "user", "system", and "real"?
...
I set it to iPhone/Network mode, but the device never appears anywhere. Connected and running an app through xcode. Do you know a useful tutorial for this?
...
I just setup a new Wordpress blog at home, and no other pages takes forever...I am trying to just add an image to the post, but it is just taking forever...none of the other pages takes so long to load...
And i have just optimized all my tables via mysq and a scheduled task, so i don't see why it's taking so long to load...
...
In this answer Brian explained how to connect Shark with the device. I do it exactly this way, but Shark never lists my device. Even if Xcode launches my app on it and the app runs. I get console Logs and everything. It communicates with the mac. But Shark doesn't see it. What could cause this? Snow Leopard, btw...
...
I have a quick question that is specific to the server setup we have available to us.
We are getting ready to migrate our help desk to a new server, as well as convert a small ACT DB to the full version of SQL 2005 Standard (from SQL Expr.)
Right now, we only have the following resources available to us as far as array configurations ...
Jeff Atwood wrote once he found quering database for primary keys, and then getting all relevant fields with an IN clause is double as quick as its single-sql counterpart.
I wonder if this applies to all situations, and if not, what are the cases when it still provides significant room for improvement in terms of performance?
Furthermo...
Hi everyone,
I'm using MySQL 5, and I need to do this sentence to get the results. It's the first attempt when I think about it. I know there are several ways to improve it, but I want to get your opinions first:
SELECT p.id, p.image, p.lat, p.lng,
p.category_id, p2.title, p2.description, c2.name
FROM place p
LEFT JOIN place_tr...
With this method declaration (no overloads):
void Method(double d)
{
// do something with d
}
Is there a (performance) difference at runtime between
void Main()
{
Method(1);
Method(1.0);
}
or does the compiler automatically convert the int literal to a double?
...
In the past, I've written Linq to SQL queries that haven't performed well. Using SQL Profiler (or similar) I can look at how my query is translated to SQL by intercepting it at the database.
Is there a way to do this with Linq queries that operate solely on objects?
As an example, consider the following Linq query on a list of edges i...
Could someone please point out a site where I can find an algorithm to efficiently calculate integer exponentiation to large powers using C#?
eg. I want to calculate 2^60000 or 3^12345
...
I want to conduct a stress and performance test on the front-end of my ASP.NET app. My goal is to:
Identify bottlenecks
Learn the number and the load of HTTP requests
Easily determine the components that are using an Expires header and/or being gzipped
Figure out where to increase download parllelization
Locate duplicate scripts and u...
Hello,
Firebug is awesome in reporting the relative time when an HTTP request was made with respect to the 'DomContentLoaded' and 'load' time. However, once the 'load' event occurs (seen by the red line on the timeline), the requests thereafter do not have any information about how later they occurred with respect to the two events.
To...
I have a table with a InTime and an OutTime column.
Normally when I insert data into this table I set the InTime to a DateTime and the OutTime to null. When the data is removed a OutTime value is set.
When I’m getting data out for a particular time I use something like:
where InTime < sometime and OutTime is > sometime or OutTime is n...
I have to cache an object hierarchy in-memory for performance reasons, which reflects a simple database table with columns (ObjectID, ParentObjectID, Timestamp) and view CurrentObjectHierarchy. I query the CurrentObjectHierarchy and use a hash table to cache the current parents of each object for quickly looking up the parent object ID,...
Everyday discussions like "C# vs Java performance", "F# vs C# performance", "C vs C++", "native C++ vs C#" always are interesting. Just like idiom.com/~zilla/Computer/javaCbenchmark.html , or mb manageability.org/blog/archive/20030520%23p_the_problem_with_cameron
Generally, professional of language A proves that language A is faster tha...