|
1. The lounge is for the CodeProject community to discuss things of interest to the community, and as a place for the whole community to participate. It is, first and foremost, a respectful meeting and discussion area for those wishing to discuss the life of a Software developer.
The #1 rule is: Be respectful of others, of the site, and of the community as a whole.
2. Technical discussions are welcome, but if you need specific programming question answered please use Quick Answers[^], or to discussion your programming problem in depth use the programming forums[^]. We encourage technical discussion, but this is a general discussion forum, not a programming Q&A forum. Posts will be moved or deleted if they fit better elsewhere.
3. No sys-admin, networking, "how do I setup XYZ" questions. For those use the SysAdmin[^] or Hardware and Devices[^] forums.
4. No politics (including enviro-politics[^]), no sex, no religion. This is a community for software development. There are plenty of other sites that are far more appropriate for these discussions.
5. Nothing Not Safe For Work, nothing you would not want your wife/husband, your girlfriend/boyfriend, your mother or your kid sister seeing on your screen.
6. Any personal attacks, any spam, any advertising, any trolling, or any abuse of the rules will result in your account being removed.
7. Not everyone's first language is English. Be understanding.
Please respect the community and respect each other. We are of many cultures so remember that. Don't assume others understand you are joking, don't belittle anyone for taking offense or being thin skinned.
We are a community for software developers. Leave the egos at the door.
cheers,
Chris Maunder
The Code Project | Co-founder
Microsoft C++ MVP
modified 16-Sep-19 9:31am.
|
|
|
|
|
sony bravia 4k blah blah, plugged it into my computer, decided to watch a movie, and ...
Forgot that Brazil is a Christmas movie!
Bonus: obligatory festive season movie: Done.
oh yeah, TV's OK - still not going to watch FTA though
<< Signature removed due to multiple copyright violations >>
modified 2hrs 20mins ago.
|
|
|
|
|
lopatir wrote: still not going to watch FTA though
The The Freight Transport Association[^]? Can't say I blame you ...
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
Ah, Brazil, best enjoyed with a cup of coffee 
|
|
|
|
|
I have no idea how to reliably examine post JIT'd asm in .NET - I haven't really tried yet, but I would be really interested to know how it handles forwarded virtual calls that don't change the stack frame and don't do anything other than forward.
Some methods can be resolved using a jump because all they do is forward calls to another method.
This can happen a lot in OOP when you have base classes calling derived classes through virtual functions.
In those cases, instead of doing two jumps to get to the final method, such that target->base->derived, it could know just to do target->derived directly?
I'm inclined to believe it won't, for reasons, but if it did it would be a fine excuse to go really deep with your derived classes.
I was wondering because I'm rewriting some tokenizer code and I was thinking of going two levels deep in my derived classes (again for reasons) but tokenizers shouldn't waste clock cycles they don't need to waste. (It's bad enough writing one in C#)
Edit: Never mind. I was out of my head. You can't describe what I'm trying to describe in such a way that the vtbl already has the forwarded calls in it anway. I wasn't thinking straight.
When I was growin' up, I was the smartest kid I knew. Maybe that was just because I didn't know that many kids. All I know is now I feel the opposite.
modified 2hrs 10mins ago.
|
|
|
|
|
Go into the debug settings, uncheck "suppress jit optimization on module load", debug a release build. Or you can throw an exception near the code you want to see (throw it conditionally in a way that you know is true but the compiler won't know, to stop it optimizing stuff out), let the program die and attach debugger when prompted.
honey the codewitch wrote: Some methods can be resolved using a jump because all they do is forward calls to another method.
This can happen a lot in OOP when you have base classes calling derived classes through virtual functions. I don't really get what you have in mind here, otherwise I would try it myself.
|
|
|
|
|
abstract class Foo {
public abstract Bark();
}
abstract class Bar : Foo {
}
class Dog : Bar {
}
I just realized something.
The only way to make what I happened happen is to do in such a way that it won't matter anyway.
Basically the vtbl slots will already be filled with the forwarded pointer. My bad.
So never mind. I'll leave my message up in shame
When I was growin' up, I was the smartest kid I knew. Maybe that was just because I didn't know that many kids. All I know is now I feel the opposite.
|
|
|
|
|
Sounds like you're mixing up inheritance with representation.
But I'm probably wrong though, from what you've posted so far, you're better than me.
|
|
|
|
|
I was having an off moment. Wasn't thinking about the vtbl holes being filled for some reason.
it's been too long since I've written COM classes in C++. That keeps my vtbl knowledge fresh (i never use ATL because it's clunky)
When I was growin' up, I was the smartest kid I knew. Maybe that was just because I didn't know that many kids. All I know is now I feel the opposite.
|
|
|
|
|
|
|
That was not a bright bird. You do not mess with the octopus.
When I was growin' up, I was the smartest kid I knew. Maybe that was just because I didn't know that many kids. All I know is now I feel the opposite.
|
|
|
|
|
you can't be bad and bright at the same time
|
|
|
|
|
just finished a binge watch of mr. mercedes season 3. Good, easy, plausible.
- yeah season 2 was a bit implausible, but s3 barely brings that up, all of 2 brief mentions
but best part is it ended, no loose strings, everything closed,and no new plot teasers...
It actually ended! Refreshing. No waiting for more.
so used to there being some new twist revealed [right at the end], unfinished / branch [sub] plot, or sometimes straight-up in-your-face hints pointing to [the producers milking] a new season
only to have the executives claim 'not enough audience' (reality not enough $).
otoh also fair to add a lot of the MM cast were pretty old of a more senior persuasion; nothing kills a series faster then a lead actor kicking the bucket mid stream - maybe a risk management call?
<< Signature removed due to multiple copyright violations >>
|
|
|
|
|
You would not say that if you knew Mr Mercedes. No doubt he will have another 1000 changes to everything I delivered him today. For the rest of the year he is out of luck. I still had a few free days left. See you in january.
I have lived with several Zen masters - all of them were cats.
His last invention was an evil Lasagna. It didn't kill anyone, and it actually tasted pretty good.
|
|
|
|
|
Now I'm a little scared. Because code that I knew was broken is working but when I "fixed" it the whole thing falls on its face.
The problem is, given a bit of code, find all variables declared within the scope of that code.
Prior, i was just getting all the variables in the routine. I knew it was wrong, but i hadn't worked out the problem yet.
Now I have, so I went back to update the code. As soon as I put it in Slang's patcher stops finding some of my variables!
So I test the variable tracer some more. It works as good as I could have hoped.
Which means somewhere, something else doesn't. And I barely know where to begin to look because of how this works.
Worse, currently my repro requires running a very particular bit of slang code as part of my lexer generator - "Rolex"'s operation, which means i had to pull that out and duplicate it in a scratch binary to debug, but it's still not very narrowed down. I can't quite find the bit where i need to test in the debugger.
The trouble is visitors are nasty when things go wrong. The visitor works right, it's the code that's firing on visit that's bad somewhere, and that happens inside a visit so the call stack is a nightmare.
And it's friday the 13th. Just my day. Maybe I should stay off the computer.
Building stuff like this is rough.
When I was growin' up, I was the smartest kid I knew. Maybe that was just because I didn't know that many kids. All I know is now I feel the opposite.
|
|
|
|
|
Are you using this forum as your rubber duck? 
|
|
|
|
|
One quack for yes, two quacks for no.
- I would love to change the world, but they won’t give me the source code.
|
|
|
|
|
|
Is Yogi's picnic basket loaded for bear?
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
With the ranger options available, I'd say you made a Boo Boo with that post.
Ravings en masse^ |
---|
"The difference between genius and stupidity is that genius has its limits." - Albert Einstein | "If you are searching for perfection in others, then you seek disappointment. If you seek perfection in yourself, then you will find failure." - Balboos HaGadol Mar 2010 |
|
|
|
|
|
think you made a boo boo: it's called a "pickinic basket."
<< Signature removed due to multiple copyright violations >>
|
|
|
|
|
Shouldn't that be 'loaded for Berra'? Though I'm not sure as I'm feeling just av er age today.
"the debugger doesn't tell me anything because this code compiles just fine" - random QA comment
"Facebook is where you tell lies to your friends. Twitter is where you tell the truth to strangers." - chriselst
"I don't drink any more... then again, I don't drink any less." - Mike Mullikins uncle
|
|
|
|
|
He's making a database.
He's sorting it twice.
SELECT * FROM contacts WHERE behavior = 'nice'
SQL Clause is coming to town!
Sorting twice, SELECT *, seems Santa is getting coal this year!
|
|
|
|
|
I have proof that Santa works for the NSA:
Quote: He sees you when you're sleeping
He knows when you're awake
He knows if you've been bad or good
So be good for goodness sake
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
AntiTwitter: @DalekDave is now a follower!
|
|
|
|