-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
strange behaviour #47
Comments
Hey, thanks for the report!
|
Hm. thanks for your hints. Giving you a simple reprocase is not that easy as it's my toy engine were I test new (and creative) ideas with an esoteric buildsystem, shadercompilation and so on. Maybe I can strip it down. But I got some other ideas to experiment. Interestingly: in the project are more than one executable and with a very simple one (and my own integration of jetlive into that buildsystem) it works, so it seems it's not a general issue on the platform. will play a bit and try to strip it down if nothing helps. Also will try to include debugging-printfs to find out what is going on. |
that was fast and easy to reproduce. I found that I have a class with a const int variable and changing this variable produces this strange behaviour. when I modify not the value itself but the usage the change gets reloaded fine. the basic structure is this:
If you setup an small example with the code above and you change the variable "blub" it will not be printed instantely because no change is detected. but when I remove the "blub" in the if, in the printf and in the assignment and replace it by a value it will get reloaded fine. In the above example it will never be changed by using jet-live, why in my toy-engine it get reloaded with a delay of one reload-cycle I'm still unsure (but I can live with it when I know where it does come from). Honestly speaking I would have assumed, because it's a const int, the variable gets integrated directly into the code, but when I look with godbolt the variable will be put into a memory location and used from there: https://godbolt.org/z/b_B6Ch |
I've integrated your lib into my own toy-project and have a really strange behavior:
I compile and start my program in the original state and it runs.
Now I modify a small parameter (call if mod1)
jet runs and recognizes my filechange and recompiles the file
I reload the application and get 2 messages "[E]: WTF" coming from the elf loader
the program gets reloaded and some functions are relocated
now the program runs, but still in the original state (without mod1!)
now I again change something (mod2)
it gets recompiled
I reload and get again 2 times the WTF message
now the program runs in the mod1 state and not with my latest modifications, so it seems it is always one step behind?!
I understand if it works (of course) or if it does not work (not so nice), but beeing one step behind is strange. Anything I can dig into to find out what is going on?
my environment is linux 64bit, clang 7.1.0 x86_64-pc-linux-gnu
The text was updated successfully, but these errors were encountered: