Click here to Skip to main content
15,903,203 members
Home / Discussions / Design and Architecture
   

Design and Architecture

 
GeneralRe: DTO to UI, or not? Pin
Single Step Debugger3-Feb-23 8:57
Single Step Debugger3-Feb-23 8:57 
AnswerRe: DTO to UI, or not? Pin
Dave Kreskowiak3-Feb-23 11:39
mveDave Kreskowiak3-Feb-23 11:39 
GeneralRe: DTO to UI, or not? Pin
Single Step Debugger6-Feb-23 5:38
Single Step Debugger6-Feb-23 5:38 
AnswerRe: DTO to UI, or not? Pin
jschell6-Feb-23 6:20
jschell6-Feb-23 6:20 
QuestionMultiple classes calling another same classs Pin
Member 1402131327-Jan-23 9:15
Member 1402131327-Jan-23 9:15 
AnswerRe: Multiple classes calling another same classs Pin
Gerry Schmitz27-Jan-23 11:31
mveGerry Schmitz27-Jan-23 11:31 
AnswerRe: Multiple classes calling another same classs Pin
jschell29-Jan-23 11:05
jschell29-Jan-23 11:05 
QuestionDebate reactive programming with me! Pin
Mike Nakis18-Jan-23 3:08
Mike Nakis18-Jan-23 3:08 
AnswerRe: Debate reactive programming with me! Pin
Mircea Neacsu18-Jan-23 3:58
Mircea Neacsu18-Jan-23 3:58 
AnswerRe: Debate reactive programming with me! Pin
Richard MacCutchan18-Jan-23 4:41
mveRichard MacCutchan18-Jan-23 4:41 
AnswerRe: Debate reactive programming with me! Pin
Gerry Schmitz18-Jan-23 5:16
mveGerry Schmitz18-Jan-23 5:16 
AnswerRe: Debate reactive programming with me! Pin
jschell22-Jan-23 8:50
jschell22-Jan-23 8:50 
AnswerRe: Debate reactive programming with me! Pin
jochance7-Mar-23 9:38
jochance7-Mar-23 9:38 
QuestionHeap stack allocation Pin
trønderen15-Jan-23 13:10
trønderen15-Jan-23 13:10 
AnswerRe: Heap stack allocation Pin
jschell22-Jan-23 9:08
jschell22-Jan-23 9:08 
GeneralRe: Heap stack allocation Pin
trønderen23-Jan-23 4:26
trønderen23-Jan-23 4:26 
GeneralRe: Heap stack allocation Pin
jschell24-Jan-23 10:09
jschell24-Jan-23 10:09 
GeneralRe: Heap stack allocation Pin
jsc4225-Jan-23 1:15
professionaljsc4225-Jan-23 1:15 
trønderen wrote:
In languages with a static link (I haven't been working with any more recent one than Pascal; most newer languages don't have a static link), code of an inner function may address locations in frames lower on the stack. However, they do not do this by negative offsets (or positive, if the stack is growing downwards) from their own frame pointer. Rather, they use the static link to find the stack frame of the outer function, and do relative addressing from that frame base address - as if it was a pointer to a struct. The addressing never goes outside that frame.

In the late 1970s, I had a project to optimise expression evaluation in Pascal (based on the Pascal PCode compiler). As you surmised, in the PCode compiler, accessing higher nested values from lower nested functions did skip down the stack frame back pointers (one skip per depth of nesting); but that is an implementation technique, it is not part of the language definition. I guessed that it could be improved by maintaining a vector of nested stack frame start locations to access stack specific offsets directly using this vector. This proved to be a useful optimisation for evaluating expressions. However, when I ran comparisons on a large Pascal program (my test large program was the original version of the PCode compiler) I discovered that whilst the overheads for evaluating expressions were reduced, the number of times that the test program actually accessed variables in higher scopes was so low that the overhead of maintaining the vector outweighed the advantages of having the vector.
GeneralRe: Heap stack allocation Pin
harold aptroot23-Jan-23 1:03
harold aptroot23-Jan-23 1:03 
GeneralRe: Heap stack allocation Pin
trønderen23-Jan-23 4:46
trønderen23-Jan-23 4:46 
GeneralRe: Heap stack allocation Pin
jschell24-Jan-23 10:12
jschell24-Jan-23 10:12 
QuestionSetting Up Client Test Environments Pin
Kevin Marois28-Dec-22 9:48
professionalKevin Marois28-Dec-22 9:48 
AnswerRe: Setting Up Client Test Environments Pin
jschell17-Jan-23 4:34
jschell17-Jan-23 4:34 
AnswerRe: Setting Up Client Test Environments Pin
jochance7-Mar-23 19:23
jochance7-Mar-23 19:23 
QuestionHas x:bind in WinUI 3 effectively killed commanding and converters? Pin
greatoceansoftware23-Dec-22 5:53
greatoceansoftware23-Dec-22 5:53 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.