Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [runtime]

The tag has no usage guidance.

3
votes
6answers
601 views

Is it better to write an efficient algorithm or code that is easier to understand?

So I was recently given a coding assignment from a large financial firm, and I thought of two ways to solve the problem. One of the ways involved 1 outer for loop and 1 inner for loop. In this case, ...
0
votes
0answers
44 views

Are there any implementations of a AOP framework that can weave aspects into a running program

Using Aspect Oriented Programming (AoP) for logging and debugging seems to be a rather established technique. That got me thinking, are there any software packages that enables us to weave aspects ...
5
votes
0answers
124 views

Reason for sudden rise in popularity of compile-time annotation processing in Java [closed]

So compile-time annotation processing is as old as the annotations themselves in Java. Yet most of the useful libraries were developed with the runtime approach in mind – at least at first. Now, ...
1
vote
3answers
211 views

How do I compare parameter- and returntypes at runtime?

I have a Java application that needs to process some data. The data starts off in format A. The application consists of a number of modules which are each capable of processing data. But not every ...
0
votes
1answer
132 views

Why are the Android runtime and native libraries in the same layer?

Regarding the diagram in Android's website: https://developer.android.com/guide/platform Why did they put the Android Runtime category in the same layer as the native C/C++ libraries category. ...
2
votes
4answers
495 views

Why use Java as a server-side language over an interpreted language?

Web pages are usually tested by refreshing the page, clicking some UI component, then either writing to a debug log or adding some breakpoints in the IDE... in larger applications, unit tests are ...
-3
votes
2answers
340 views

What does it mean, “Php doesn't have its own runtime”?

Speaking of php. It doesn't really have its own runtime in compare to python, ruby or go. Php is jsut a text preprocessor. What exactly does it mean by, Php doesn't have runtime?
3
votes
2answers
299 views

How to avoid generating verbose code when compiling from a higher level language to a lower one?

I apologize in advance for the vague title. I didn't want to make it overly verbose, so allow me to explain more in-depth below: I've currently been developing a strong, statically typed language ...
1
vote
2answers
140 views

How is a compiler related to the runtime system?

A quick search on the role of compiler brings up the following: A compiler is a special program that processes statements written in a particular programming language and turns them into machine ...
8
votes
2answers
1k views

How to design a C++ program to allow for runtime import of functions?

today, I like to ask you a question towards the capabilities of C++ to realize a specific software architecture. Of course, I have used the search but have not found any directly linked answer. ...
104
votes
5answers
10k views

How does shifting to microservices create a run-time problem?

The following commentator writes: Microservices shift your organizational dysfunction from a compile time problem to a run time problem. This commentator expands on the issue saying: Feature ...
4
votes
2answers
577 views

What is run-time support required by a language?

I read somewhere that C is preferred for drivers and firmware on embedded systems because it requires less run-time support. I could not understand the part 'run-time support'. My understanding is C ...
1
vote
4answers
1k views

Best algorithm to multi-thread this application?

I define an algorithm to be best if it minimizes the total run time over commodity hardware (e.g. normal desktop and server PCs). I have sets A and B. I also have function f that works like f(a, b, n)...
4
votes
4answers
263 views

Is Program Running Time Affected by File Size?

Say I wrote a program containing 3 methods. Each method was 100 lines. Method 1 was main(), and Method 2 was called by main(). I then duplicated the program into an identical second program. After ...
7
votes
3answers
13k views

Is it a good practice to use suppress warnings in your code?

I use @SuppressWarnings("unchecked") and @SuppressWarnings("null") mostly above methods to let the code compile without any warnings but I have my doubts. Found this Stackoverflow question. Jon Skeet ...
-1
votes
2answers
523 views

How to validate Exception messages? [closed]

My superior asked me to validate each and every input field in the project that includes the Exception messages. So, am I correct in using Exceptional Handler for validating Exception message. ...
0
votes
1answer
260 views

My algorithm is too slow

Reposted from Stack Overflow - I think this is a more appropriate place to ask the question. I have an algorithm that for an integer x and a starting integer i such that 1 < i < x the next ...
16
votes
2answers
19k views

How does the Python Runtime actually work?

I have some problems understanding the concept of a runtime library, especially the Python one. So I have written some a hello world python program and intend to execute it, so I write python ./...
6
votes
2answers
569 views

Returning Unmodifiable Collections only tees you up for runtime exceptions?

Seeing as how there are no distinct Unmodifiable Collections interfaces, aren't you just setting yourself up for runtime exceptions by returning Unmodifiable Collections from method invocations? ...
9
votes
3answers
3k views

What is an “application model”?

Currently I'm studying .NET Core and in the early docs which first introduced .NET Core we see that talk about the many different verticals. This can be seem in this picture: In all the verticals we ...
3
votes
2answers
91 views

App db creation at first run

I am working on Qt/QML/MySQL app and I want to achieve maximum customization of software; therefore I've packed app's settings into SQLite3 database file. I have several SQLite3 scripts hardcoded into ...
1
vote
1answer
129 views

Does exception handling belong at the lowest level of the runtime?

I'm designing a fairly simplistic stack-based programming language, and implementing it in Python. (no link, because it's not fully implemented yet.) The language itself is essentially intended to be ...
1
vote
3answers
2k views

What really is the “runtime environment”?

This is a very basic question but is something I've never completely understood and recently, when studying .NET Core and ASP.NET 5 I felt the need of a more complete understanding of the topic. ...
0
votes
1answer
60 views

Does testing the characteristics of a runtime have a generally accepted name? [closed]

I am working with PowerShell which doesn't seem to have an up-to-date language spec. This leaves me wondering about some edge cases. I've taken to testing my assumptions about how PowerShell's ...
3
votes
1answer
2k views

C++ Runtime and runtime-linking

I was installing boost and I came across an option named "runtime-link". After searching a bit, I came across yet another complex topic: "runtime system" that according to Wikipedia: The runtime ...
5
votes
1answer
673 views

Strategy for OS X and downlevel version of C++11 library?

I think I've found myself in a situation where things are quickly spiraling out of control, and I'd like to get some feedback to select a way to proceed. BACKGROUND I'm working with a library based ...
1
vote
1answer
155 views

A little confused with virtual functions

Please see the following code: #include<iostream.h> #include<string.h> class father { char fname[20]; public: father() { strcpy(fname,"eshwarappa"); ...
1
vote
2answers
243 views

Do today's modern compilers perform run time checks?

This is regarding compilers. Do compilers perform run time dependency checks to decide to vectorize a loop ? In other words, do compilers trace through the logic as it would in run-time to ...
1
vote
2answers
442 views

Algorithm Space and Time Complexity with Consideration for I/O (eg cache)

Is there an expression of performance for an algorithm or data structure that attempts to consider cache and other hardware concerns? Context: in my class we're looking at binary trees and it seems ...
13
votes
3answers
1k views

What is the difference between ref and out in runtime?

C# provides the ref and the out keyword to make arguments to be passed by reference. The semantic of the two is very similar. The only difference is in the initialization of the flaged variable: ref ...
1
vote
4answers
180 views

What do polynomial algorithms entail?

From here, I know it is that an algorithm that... ...is said to be solvable in polynomial time if the number of steps required to complete the algorithm for a given input is O(n^k) for some ...
0
votes
1answer
199 views

What is the justification for the running time of this loop?

I don't understand why the running time of the following loop is n+2 ? Also why the running time of the statements inside the loop is n+1 ? Double test(int n){ int sum=0; -> 1 time ...
5
votes
3answers
2k views

Loop runtime question

I had an exam today and I feel that I did pretty well, except I could not for the life of me figure out what appears to be an unbelievably simple question. We were asked to give theta notation run ...
1
vote
2answers
570 views

Decide the type of an object during runtime

I try to implement a PriorityQueue with C#: public class PriorityQueue<T> : Heap<T> where T : IComparable<T> { ... } The Heap is abstract. I have MinHeap and MaxHeap that are ...
1
vote
2answers
265 views

Runtime analysis of functions that call other functions

If you have a function being called in another function, do you figure out the runtime for the being called and then "add" that to function you wish to analyze the runtime for? Function to be ...
8
votes
2answers
2k views

single for-loop runtime explanation problem

I am analyzing some running times of different for-loops, and as I'm getting more knowledge, I'm curious to understand this problem which I have still yet to find out. I have this exercise called "How ...
2
votes
1answer
791 views

Asymptotic running time of for-loops

I have this question which I need answered: What is the asymptotic running time for the following piece of code? if (N < 1000) for (int i = 0; i < N; i++) for (int j = 0; j < N; j++)...
0
votes
2answers
31k views

Running time of simple for-loops

I'm reading algorithms and I understand most of it, one thing that I can still struggle with a lot is something as simple as running times on different for-loops. Everyone seems to have easy with that,...
0
votes
1answer
2k views

Modulo Operator Runtime

I am reading a review sheet for a class and the instructor said this of the modulo operator: Remember that modulus (%) has a runtime of O((logn)^2). He continued to display this piece of code: //...
5
votes
1answer
513 views

How do programming languages integrate with OS runtimes

For example, Objective-C, Swift and Ruby (i.e. RubyMotion) integrate with the Cocoa framework. Is this done via linked libraries? I assume they call functions in existing binaries instead of simply ...
1
vote
1answer
605 views

Algorithm to create permutations for a given alphabet based on a sequence number

I would like to have a function that will create a word (always the same word) for a given sequence number based on a given alphabet. word(0, [a,b,c]) = a word(1, [a,b,c]) = b word(2, [a,b,c]) = c ...
6
votes
3answers
3k views

Why is inheritance only defined at compile-time?

I found this statement from the gang of four's "Design Patterns" particularly odd; for some context, the authors are comparing inheritance versus composition as reuse mechanisms [p. 19]: "...you ...
1
vote
1answer
7k views

Why execution time is different each time in java?

I am trying to make a program in Java which measure the complexity of a specific program with respect to its run time. Let's take a problem and code that problem in all possible ways with respect to ...
9
votes
4answers
1k views

Why not free memory as soon as its reference counter hits zero [duplicate]

A lot of languages like Java and C# have garbage collectors that free memory when that memory no longer has any reference. Yet they don't immediately free it after the reference counter hits zero but ...
2
votes
1answer
519 views

What am I risking if I don't update my SDK/JDK and bundled runtime/JRE every time there's a security update?

It seems like there's a new major security hole patched in Java every other week, and I would assume the same goes for other development platforms. After years of frustration trying to get customers ...
-1
votes
1answer
880 views

Recompiling a java project while it is running

I have a Java program that takes about an hour to run. While it is running, if I change the source code and recompile it, will this affect the above run?
6
votes
1answer
506 views

Difference between language virtual machine and emulating vm?

I'm having a hard time understanding the difference between an emulation virtual machine and a language vm. I started with the research and implementation of an emulation virtual machine. Primarily ...
1
vote
1answer
6k views

What are Web runtime environments and programming languages

I've been looking into the details behind these two different categories: Web runtime environments Web application programming languages I believe I have the correct information and have phrased it ...
1
vote
1answer
442 views

Sencha Ext JS run time license

Do you need to buy a run time license from Sencha if your application code written is developed in Ext JS and deployed on a web server? http://www.sencha.com
3
votes
1answer
9k views

What is the difference between APIs, Libraries, Runtime systems, and frameworks? [duplicate]

Possible Duplicate: Library vs. framework vs API? I am having hard times understanding what these concepts really mean. This software stack thing is very confusing. Can you please help me with ...