Click here to Skip to main content
16,004,653 members

Welcome to the Lounge

   

For discussing anything related to a software developer's life but is not for programming questions. Got a programming question?

The Lounge is rated Safe For Work. If you're about to post something inappropriate for a shared office environment, then don't post it. No ads, no abuse, and no programming questions. Trolling, (political, climate, religious or whatever) will result in your account being removed.

 
GeneralRe: This, this right here... is why people hate macros... Pin
BernardIE531721-Aug-24 20:43
BernardIE531721-Aug-24 20:43 
GeneralRe: This, this right here... is why people hate macros... Pin
charlieg22-Aug-24 0:48
charlieg22-Aug-24 0:48 
GeneralRe: This, this right here... is why people hate macros... Pin
charlieg28-Aug-24 2:20
charlieg28-Aug-24 2:20 
GeneralRe: This, this right here... is why people hate macros... Pin
Rick York21-Aug-24 5:08
mveRick York21-Aug-24 5:08 
GeneralRe: This, this right here... is why people hate macros... Pin
Jeremy Falcon21-Aug-24 6:08
professionalJeremy Falcon21-Aug-24 6:08 
GeneralRe: This, this right here... is why people hate macros... Pin
Stacy Dudovitz25-Aug-24 1:59
professionalStacy Dudovitz25-Aug-24 1:59 
GeneralRe: This, this right here... is why people hate macros... Pin
Jeremy Falcon25-Aug-24 3:03
professionalJeremy Falcon25-Aug-24 3:03 
GeneralOkay. I'm done today Pin
honey the codewitch20-Aug-24 2:13
mvahoney the codewitch20-Aug-24 2:13 
I got a stack overflow in my SVG code. It never used to do that before, and I barely changed anything. I just removed a few divisions in some relatively innocuous routines. Furthermore, reverting the changes didn't fix it.

There's something else going on. Well, on little embedded devices there's not a whole lot of memory protection. When you stack overflow it clobbers the stack so you can't get even a partial stack trace.

Okay. My code is cross platform. I'll fire it up on my PC under MSVC++

Compile errors. Turns out what I thought was a harmless feature add makes MSVC++'s compiler just scream. 100 errors for less than 10 lines of code. I removed the feature. It's a shame too, as it was a real convenience.

Got it building.

Put together my test code - basically just de-arduino-ing it and then making it spit the graphics as ascii art to the console. No big deal.

Run it. No crash. No stack overflow.

Which tells me the problem is the one I didn't want to try and solve. Now I need to figure out what's taking all the stack, rather than what is recursing indefinitely.

I did move 2KB off the stack but it's still dying on me.

This code is non-trivial. It's the SVG parsing code, and took me forever to create it. I tried to keep it light on the stack but apparently it's not light enough.

Pruning for stack space in a veritable labyrinth of function calls is not my idea of fun.

I have a dentist appointment later today which seems appealing by comparison. Roll eyes | :rolleyes:
Check out my IoT graphics library here:
https://honeythecodewitch.com/gfx
And my IoT UI/User Experience library here:
https://honeythecodewitch.com/uix

GeneralRe: Okay. I'm done today Pin
Maximilien20-Aug-24 2:16
Maximilien20-Aug-24 2:16 
GeneralRe: Okay. I'm done today Pin
honey the codewitch20-Aug-24 2:17
mvahoney the codewitch20-Aug-24 2:17 
GeneralRe: Okay. I'm done today Pin
Alister Morton20-Aug-24 3:27
Alister Morton20-Aug-24 3:27 
GeneralRe: Okay. I'm done today Pin
jochance20-Aug-24 11:44
jochance20-Aug-24 11:44 
GeneralRe: Okay. I'm done today Pin
Rage20-Aug-24 22:26
professionalRage20-Aug-24 22:26 
GeneralRe: Okay. I'm done today Pin
charlieg21-Aug-24 1:27
charlieg21-Aug-24 1:27 
GeneralBrainless Ad People PinPopular
David O'Neil19-Aug-24 20:36
professionalDavid O'Neil19-Aug-24 20:36 
GeneralRe: Brainless Ad People Pin
Pete O'Hanlon19-Aug-24 21:19
mvePete O'Hanlon19-Aug-24 21:19 
GeneralRe: Brainless Ad People Pin
David O'Neil19-Aug-24 21:30
professionalDavid O'Neil19-Aug-24 21:30 
GeneralRe: Brainless Ad People Pin
obermd20-Aug-24 3:38
obermd20-Aug-24 3:38 
GeneralRe: Brainless Ad People Pin
David O'Neil20-Aug-24 16:41
professionalDavid O'Neil20-Aug-24 16:41 
GeneralRe: Brainless Ad People Pin
Choroid20-Aug-24 5:23
Choroid20-Aug-24 5:23 
GeneralRe: Brainless Ad People Pin
Peter_in_278019-Aug-24 21:29
professionalPeter_in_278019-Aug-24 21:29 
GeneralRe: Brainless Ad People Pin
David O'Neil19-Aug-24 21:33
professionalDavid O'Neil19-Aug-24 21:33 
GeneralInternationalization Pin
trønderen20-Aug-24 6:42
trønderen20-Aug-24 6:42 
GeneralRe: Brainless Ad People Pin
den2k8820-Aug-24 0:04
professionalden2k8820-Aug-24 0:04 
GeneralRe: Brainless Ad People Pin
Dan Boris21-Aug-24 9:13
Dan Boris21-Aug-24 9:13 

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.