Questions related to improving application performance, this can be range from selection software architecture to selection of algorithms.
0
votes
0answers
22 views
Finite Element Shader
I am working on a geometric wrapper for a space jet exhaust impingement solver. A key part of the solution is determining what the jet can "see" and therefore hit. My model is grouped with nodes or ...
0
votes
1answer
35 views
Where should assets (such as audio) live in a SPA to API type application?
Developing an application with Ember.js (but could be Angular/Knockout/whatever) for the front end and using a node.js server for the back end. The back end is just an api that validates user info and ...
1
vote
2answers
133 views
Performance concern in object oriented languages [duplicate]
I recently moved into web development using ASP.NET MVC. The language I use is C#. Having considerable experience in C makes me look for optimized coding standards (memory, efficient data structures ...
3
votes
0answers
30 views
Strategies for investigating performance of an ASP.NET web application running under .NET 4
I'm trying to compare the performance of an application that has recently been converted from .NET2 to .NET4. From my perfomance tests it seems that although page response times are generally a bit ...
1
vote
3answers
89 views
Service oriented web architecture speed
Imagine a simple service architecture setup: single server where I have one service acting as a REST API (PHP), another service for rendering frontend (nodejs), and maybe a database service.
They all ...
0
votes
1answer
179 views
Improving performance with caching of files in C# [closed]
EDIT: You were right, the problem is not checking if a file with the same name exists but the connection. I made a mistake measuring the time with StopWatch and included a part which used the network ...
0
votes
0answers
29 views
Cost of cache coherency/sharing data across multiple cores?
If I have two CPU cores, one is writing a particular cache line and the other core wishes to
Read
Write
the same cache line, what are the costs (in cycles) for doing so?
I am a little unsure ...
4
votes
2answers
77 views
How can I have a variable timeout value based on machine performance?
I have a similar problem as Criteria for selecting timeout value?. But my question is slight different.
Process A dependes on process B and has a timeout value of 5 seconds, sometimes process B might ...
-4
votes
0answers
26 views
Is accessing an object significantly slower than accessing a variable? [duplicate]
I have three really simple Javascript queues (glorified Arrays). Purely for organization, I grouped them in an object
this.queue = {
a : new Queue(),
b : new Queue(),
c : new Queue()
}
...
5
votes
2answers
372 views
Foreach loop and variable initialization
Is there a difference between these two versions of code?
foreach (var thing in things)
{
int i = thing.number;
// code using 'i'
// pay no attention to the uselessness of 'i'
}
int ...
6
votes
3answers
1k views
Is it good to define a variable inside a loop? [closed]
My instructor once told me that I should not define a variable inside a loop, but I honestly still do not understand why.
What are the disadvantages of that?
Could any body explain that to me?
1
vote
1answer
66 views
Maintaing drop down lists for the application
What would be the best approach to maintain the dropdown lists for the whole application (like city, state etc) taking into account the SOLID principles and performance?
Right now am loading the list ...
3
votes
1answer
60 views
Does push via web sockets increases server load if I have too many write requests?
I have too many write requests to database. Currently my app implementation is such that it makes pull call to server every 5 seconds to update the changed data.
If I implement push through web ...
1
vote
2answers
92 views
Alternatives to cron jobs or other ways of improving scheduled task performance
I'm working on a social networking website where users gain ratings after specific actions taken and proper conditions are met on the tables. The ratings are calculated depending on 'total hours ...
1
vote
5answers
167 views
Class design, responsibility granulation, efficiency and performance
I am in a design dilemma. I have a set of data that can be interpreted in numerous ways, but I cannot really decide how finely grained should it be. To illustrate it with some simple code:
class Base ...
1
vote
2answers
62 views
Monitoring a web service
I don't know how to phrase this question properly so please feel free to suggest edits.
I've helped develop an in-house RESTful service for a company I'm working for, and it seems to have hit a wall ...
-5
votes
2answers
113 views
Does CPU need local cache if Intel and Micron 3D XPoint is used? [closed]
As Intel and Micron stated, the new 3D XPoint RRAM is 1,000 times faster than NAND. See link here.
From speed perspective, does CPU still need L1 cache if Intel & Micron 3D XPoint RRAM is used as ...
1
vote
1answer
100 views
Design periodic batch notification system
Problem:
I am trying to design a system which takes requests from customers in
real time and log them in a database. For example - request to
purchase an item.
The customer then gets a unique ...
0
votes
1answer
88 views
Performance of sharing single object with multiple threads in Java
In Java, if I create an object that has a method to do something, and I pass that object to multiple threads which call the method, is there a performance difference from creating an individual ...
4
votes
3answers
149 views
Can a pimpl variation be implemented without any performance penalty?
One of the issues of pimpl is the performance penalty of using it (additional memory allocation, non-contiguous data members, additional indirections, etc..). I would like to propose a variation on ...
-2
votes
1answer
64 views
What's an effective threading structure for NIO and server performance in C/C++? [closed]
I run into this issue where if I do a read to check for data too often, my CPU skyrockets, and if I don't check often enough, it's slow for client performance. What's an effective way to deal with ...
2
votes
1answer
162 views
sort multidimensional array recursively - is this reasonable
In a nutshell, I needed to traverse any number of dimensions of a multidimensional array (or not) and I wanted the process to be as predictable as possible (in order to proliferate the pattern ...
0
votes
1answer
62 views
PHP MVC concept large controller
I have custom MVC framework in PHP and my controller file has about 5000 lines.
The question is, is it a big concept flaw?
It is structured code with kiss method and quite maintainable.
Are there ...
3
votes
3answers
149 views
Do microservices scale down?
I've been reading up on microservices architecture, which gained a lot of recognition in recent years. As a big fan of UNIX philosophy, I find it very clean and sensible. However, exisiting ...
0
votes
1answer
187 views
Immutable class with behavior
I've just finished Effective Java and I loved it. I'm trying to refactor one of my programs to take advantage of what I've learned, and I have a lot of questions regarding immutability.
My program is ...
2
votes
1answer
75 views
How do I handle long running third party calls from backing up my message queue?
Here is my exact scenario.
I must make requests to a third party service
The service takes ~15 seconds to respond
It also has no webhooks or any call back mechanisms
These requests are not made ...
2
votes
1answer
108 views
In C#, is it good practice to use implicit numeric conversions from int to float?
For example:
if(5.0f > 1) { }
Does it have a significant performance penalty? Compared to just doing
if(5.0f > 1.0f) { }
0
votes
0answers
52 views
BCMath vs MySQL: performance
Scenario
I am working on a web application that handles financial transactions, and my code will need to be reusable for everything from consumer carts to manufacturer/distributor shipments. The ...
-3
votes
1answer
102 views
Java - Best way to set properties of an object [closed]
I don't know if there is any difference in performance, or its just a matter of choice, but I am a perfectionist like that, and I'd like to know.
Lets say you have the object HolySheet. You can set ...
0
votes
0answers
32 views
Where to generate View?
I plan to build a CRM for small companies. It is supposed to be a single-page application.
Now I am unsure where it is more efficient to convert the data to HTML. Should I rather do it on the server ...
6
votes
2answers
344 views
How does the Hip hop virtual machine (HHVM) theoretically improve PHP runtime performance?
From a high level, how does Facebook, et. al use to improve PHP performance with the Hip Hop Virtual Machine?
How does it differ from executing code using the traditional zend engine? Is it because ...
1
vote
1answer
78 views
How to handle rating? [closed]
I want to implement like/dislike system, but I don't know how to achieve best performance. I have to tables: blog posts and comments that need rating.
Should I store all data in one rating table? Or ...
1
vote
2answers
101 views
Caching query results vs Querying each time (finding a middle ground)
This is kind of an expansion on a previously asked question
Some background info:
Querying Over 5,000 items from SQL database that eventually get sorted
into a list depending on who the user ...
1
vote
1answer
101 views
When the result set doesn't matter should Left Join or Inner Join be used
When you have a query where you're joining from a non-null foreign key to the foreign table it doesn't matter if you use LEFT JOIN or INNER JOIN from a result standpoint (since there won't be any ...
3
votes
1answer
78 views
How do hybrid interpreter-JIT compilers work?
Chrome's V8 compiler, the Java HotSpot compiler, and many more have multiple tiers of interpretation and compilation.
A function starts off as interpreted in HotSpot and then, if it is run often ...
5
votes
1answer
291 views
Kth selection routine - Floyd Algorithm 489
I have recently come across a promising Kth selection routine that reportedly outperforms quickselect the Floyd, Rivest Select routine. This Wikipedia article provides a pseudocode version which I ...
3
votes
5answers
215 views
Should I use BLOB or Tables for storing large data?
Problem
Currently investigating a solution to improve the performance of a web application. The application works well for small projects, but faces performance issues in the UI when working with ...
2
votes
0answers
61 views
Truncating HTML content at specific content blocks
I have HTML content in my DB and I would like to present a list of these individual items but truncate each of them so they're not fully displayed. I would like to keep truncated items ...
3
votes
1answer
342 views
Why is iterating through List<T> more expensive than iterating through Array in .NET?
According to the answers in this post, List<T> is backed by an Array. According to this article, list iteration is considerably slower than array iteration.
If Lists are arrays 'under the ...
4
votes
1answer
514 views
Is Collection.stream().filter().forEach() inefficient compared to a standard for each loop?
IntelliJ IDEA recommended to me just now to replace the following for-each loop with a Java 8 "forEach" call:
for (Object o : objects) {
if (o instanceof SomeObject) {
...
2
votes
0answers
50 views
Argument over performance using Convert.ChangeType in Web Applications [duplicate]
A debate has been going on at work about using Convert.ChangeType.
A couple of fundamental assumptions to this discussion are delineated below:
1. The discussion is within the context of web ...
4
votes
1answer
337 views
How does modulus work?
I am not asking asking how the mathematical concept of modulus works, or how 20 % 3 == 2 I understand this fine. I'm more curious how the compiler/interpreter determines this. I can think of a very ...
5
votes
2answers
119 views
When designing a replacement application, how can I compare its performance to the original, if there are no existing statistics?
I don't believe there are any performance statistics kept for the application I'm being asked to replace, and don't want to ask the individuals doing the work to manually record things like how long ...
7
votes
3answers
592 views
Enterprise software: Where should the code go? [duplicate]
I recently went for an interview with a software company that claims to write enterprise level software. During the interview, the interviewer remarked that its better to use the database simply to ...
0
votes
3answers
371 views
Compile-time vs. run-time configuration
I'm starting new project and need to decide on how to handle configuration. I recently run into suckless project. While it has its own issues, I really liked its approach to configuration - just a ...
1
vote
4answers
281 views
List comparing techniques for faster performance
I need to cross names from two lists, and find all occurrences of one name in the other. The lists are too big, one have 50k elements and the other 400k.
For a small list I would use two foreach ...
2
votes
3answers
238 views
fast, say O(log2(N)), sliding median algorithm
So I know how to do a fast O(log2(N)) sliding max or sliding min algorithm.
Brookes: "Algorithms for Max and Min Filters with Improved Worst-Case Performance" IEEE TRANSACTIONS ON CIRCUITS AND ...
3
votes
1answer
254 views
Are there real world examples demonstrating reasonable performance improvement by using move semantics?
(I've asked a similar question on SO but unfortunately it might not be proper, so I also put here; please kindly point out if you think it's a duplicate.)
I've heard many words about the move ...
0
votes
3answers
117 views
What is the explication for the difference execution time for the same instruction?
As you know when we run instruction in our code
like long a = b;
we will not have the same ticks each to be executed.
first exeution it take 2ticks;
second exeution it take 3ticks;
third exeution it ...
1
vote
1answer
219 views
Excel worksheet population and fomatting is slow
I have written a VSTO plugin in C# which populates several worksheets.
During the population process cell values or formula are added one at a time according to user-definable criteria taken from a ...