-
-
Notifications
You must be signed in to change notification settings - Fork 21.4k
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
Compile gdscript to gdnative when exporting a game and store/run game scripts as gdnative #11068
Comments
That would require either a C/C++ compiler being supplied with Godot, or having one available being necessary to use it. |
Oh I didn't realize that . I was thinking gdnative is like java opcode but I guess it needs a C compiler . You would not need to compile binary interface to C++ objects tho because gdscript does not make calls to c++ objects so all you would need is simply compile gdscript to C binary gdnative. Perhaps a limited C compiler can be used and incorporated in the export templates along with platform specific linking assembly objects ? Edit: something like SPCC Small Portable C Compiler or PCC portable C compiler or Tiny C compiler |
I think the "best" solution would be to optionally link to LLVM, GDScript could be compiled to LLVM-IR and then even be JIT'ed while developing/prototyping. LLVM can build libraries for maaaaany different platforms, so that might be the simplest way to go without shipping an entire C compiler. Thaaaaaat said: LLVM is a pretty huge dependency. It's about 200 Mo on my Linux distro. Like I said, it could be made an optional dependency, but that would require some work from the loading side. I think in itself it's a nice idea, the real problem is not compiling to C or something but to actually generate the code for all the platforms you want to export to, C + a C compiler is one option, LLVM would be another and manually generating machine code (cough would be useful for a JIT anyway cough) yet another. It's not trivial but should be quite do-able. The main problem is that it most likely would require us to add a huge dependency. |
That's why I was thinking a more portable C compiler like Tiny C which could be used which is way smaller in size and supports multiple platforms. A retargettable compiler like LCC would be the best tho but I think it has licensing issues. Ah man I'm starting to think is more of a headache than is worth. |
Unity3D ships (or used to ship?) with a thing nicknamed |
Ideally there would be a lot of type inference going on or we wait for static typing in GDScript. |
I think the easiest solution is a C transpiler. @Zylann Yes, everything would be Variant unless you can infer the types. Static typing would improve this. |
Generating C code should be pretty easy, it would be interesting to apply some global type inference on the GDScript code in question. Because it would all be done at export time there could be a lot more effort involved in figuring out types. Unresolvable method signatures could be made type generic and instantiated accordingly. That would be quite the undertaking, but I'm pretty certain that it would yield in a huge performance increase overall. I think the bigger question is how cross-platform exports can be made as painless as possible. The picked toolchain (LLVM, tiny C, portable C) would be pretty important. There are still some problems with better windows compatibility, but I think we can rule this out later on (cc @touilleMan ). |
I have been also checking this for a while. |
There are alternatives to LLVM. LLVM is a huge dependency and is actually larger than Godot. It'd be better if we used something else instead. Including Clang as well is just suicide. C code is very easy to compile, so there are a ton of small C compilers available. A faster approach would be compiling GDScript bytecode to machine code directly. Godot is portable, so an IR like LLVM which generates machine code for us would be used, though that'd still be pretty hard to do, so translating to C sounds better. |
TBH I would just translate GDScript to C (with NativeScript), and let the user responsible for compiling the result. I doubt we can seamlessly compile to every target platform from every host without requiring many dependencies (or being downright impossible, like compiling to iOS from a Windows host). I'm also not convinced it would be useful for most cases. I also wonder if it's feasible to replace every node that has a GDScript to point to a NativeScript instead. Would that work fine? What about the peculiarities of GDScript, like named singletons, |
That sounds kinda pointless. An option would be having a (platform-specific) shell script written by the user, which compiles the code without waiting for the user. Another approach would be replace the GDScript itself with a native script. So it would compile all GDScript scripts into a .so/.dylib/.dll and a .gdnlib (preferably a single one), and when loading a .gd, it would load a .gdns instead, if available (if not, either interpret it or compile it, depending on how this would be implemented). I don't know how feasible that is, though. |
Personally I would lean away from JIT in favor of transpilation only because some platforms ahem, iOS do not support JIT. And transpilation would be much simpler to implement, aside the obvious caveats which break the typical C call stack like yield. But those issues CAN be worked around. |
And even C++20 is getting single-scoped continuations, so could transpile to that (embedded clang or so) for a more direct conversion, or just use llvm/libclang directly and skip the intermediary step. Also, this might be a duplicate of #5049 now? |
Seems like the major concern witj llvm is the size of the dependancy. Why is that a problem again? I seem to be missing that point. |
@jonbonazza Godot is supposed to be a single non-bloated binary. The solution would be to create a new flavour of Godot release (just like we already have for the .net release) but this add to the burden of the release managers (even worst if we take into account combination issue, like people who want .net AND GDscript compiler...) The solution I see to this trouble is obviously provide this feature as a GDnative extension (so it could be installed when needed through the asset library). |
What's the actual reasoning behind keeping the file size small though? Disk
space is cheap, so I fail to see the problem here. I would think that
creating fragmented releases is a much worse offense.
Also, if you do a fragmented release here, you may run into code portability issues. If there is a bug in one version but not the other, things like tool scripts and even game scripts in a lesser case, may become harder to maintain.
|
Soon we end up with an 8 GB executable like Unity but it doesn't matter because disk space is cheap, right? The time spent downloading the editor/a game is not a problem at all! Bloat is never justified. LLVM is more than double the size of Godot (I'm not sure how big it is, the guy above said 76 MB but I was pretty sure it's more around 100-200 MB, while Godot is way tinier than that). Like this, it's simply bloat. Aren't there any alternatives? |
If things like that ever get integrated to Godot, it should just be a separate download, so people don't have to install things they don't need (that doesn't prevent from providing an easy-to-use installer similar to what Unity ships with by default, if ever needed). |
Oh that certainly wouldn't be in the distributions, it would only be in the editor, and it would end up making the release distributions smaller by being able to get rid of the interpreter and with LTO (if ever added as a post-process with the engine) would shrink it far further, thus reducing download times. |
The interpreter is tiny. And how come LTO isn't used? |
Tiny yes, but it also links in to everything, thus forcing everything to be included even if it is not in use. LTO cannot be used between GDNative and the engine right now because they are currently dynamically linked, you'd need another pass upon release compilation to so to compile/link them together, of which if you give the linker enough information you'd be able to prune a lot of unused code. That is far down work, however lots of little steps, of which this would be one. |
I don't understand why not just use Mono JIT and AoT compilers. Mono is used for C# version so it's already integrated. We just need GDScript to CIL bytecode compiler. |
Not allowed on some platforms like iOS and webasm.
This is what I'm a proponant for! The OCaml compiler would be nice for that (GDScript could even compile 'to' it, with some caveats that vanish with typed gdscript), interpreter for runtime testing and debugging, compilation to C-speed machine code otherwise. |
Yes, I know but it can be JIT-ed on other platforms and AOT compiled on iOS and webasm. Or it can be JIT compiled in development mode and AoT compiled for production. Mono has experimental version for WebAsembly already. |
GDNative is already integrated too. Mono is integrated in C# version only. |
The problem is that it wasn't a dependency. They were talking about using LLVM or libclang in Godot. Those are libraries, not programs, and they would directly increase the executable size of Godot. Like you said, simply running a compiler is a more lightweight solution. I support that. But you don't need to enter the path, just run |
Can this LLVM dependency compile to all target platforms from the same host? If not, then it breaks expectation in the cross-platform export system. Though it is somewhat a concern, the size is not much of the problem, what gets it is that Godot is supposed to be cross-platform, and usually compilers have a single target. So we have to ship compilers to all platforms, which is not really feasible. I don't have any problem if it's an optional external dependency. As I said before: it's easier to just convert it to source code and let the user provide the toolchain on their own. This way it can be used with different compilers and linkers. |
Isn't clang, by itself, 40MB-60MB? Yes, that basically doubles Godot's size, but when Unity is over 10GB in size and UE4 is 20GB for the same level of platform support that Godot has, it's still absolutely tiny.
Yes, LLVM supports cross-compiling. It's what UE4 uses for cross compiling. |
I had the same idea and I thought my idea was original... what a delusion :( We could still have this feature provided as optional ofc. If you don't transpile to C++ you would still use the the interpreted version. I also think it would be easy to add a feature to selectively transplile files from the editor. It may be useful to speed up GDScript during development, not only during exporting. The pro of this is technique is that you may transpile to readable C++ and if you realize you need more control over the code, keep working on the C++ module and drop the GDScript one |
I am working on an experimental version of this that will compile gdscript bytecode to GDNative class files. Hopefully in the next month or so I will have an alpha version available. The challenge will be ensuring that the GDNative scripts inter-operate with GDScripts that are not compiled (ensuring all public interface remains compatible). Translating the bytecode to C++ is a problem that has been solved for other VMs many times over, so I don't expect any show-stoppers there. The problem I haven't solved yet is yield and resume. This will require support from the engine itself and cannot be entirely solved by transforming the input GDScript into a state machine. The common way to translate a coroutine to C/C++ would be to transform the method into a structure. All locals get promoted to members of the struct and the statements themselves are separated by the yield: Some psuedo-ish code to illustrate what I mean:
|
@pchasco IMO it would be much easier to emit C++ from the GDScript AST! Have you considered that? |
Correct me if I’m wrong, but the gdscript module doesn’t product an AST
that I could use, which means I would need to modify gdscript_compiler.cpp
and others to produce an AST. Otherwise I would need to implement my own
parser, which is hard, and it would be more difficult to ensure code
translated from my AST would be equivalent to the script that produced it.
The GDScript compiler does a lot of work for me by indicating the correct
types, base types, whether the target of function calls are members or
built-ins, etc.
In my opinion, the easiest and most accurate translation is to do a
dumb-as-rocks translation of the bytecode instructions to hard-to-read C...
goto’s and all. Then let the C++ compiler optimize to its heart’s content
producing the best binary version of the gdscript possible.
…On Tue, Nov 13, 2018 at 2:48 PM m4nu3lf ***@***.***> wrote:
@pchasco <https://github.com/pchasco> IMO it would be much easier to emit
C++ from the GDScript AST! Have you considered that?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#11068 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AChUALrksClpoYThJw_kg2qab8B0K52Qks5uuzA5gaJpZM4PROqy>
.
|
@pchasco I had a look at the implementation right now. It is generating an internal AST it just isn't exposed with any API. No writing another parser is not the way to go. What I was suggesting was to have another implementation of the GDScript compiler which takes the AST and produces the C++ code, so yes, implement something like gdscript_compiler_cpp as part of the GDScript module. Not sure which approach works best now |
I suppose if the AST were available it would be possible to generate code
from that, but I don’t know if it would be the best idea. I think the most
accurate way to replicate the original behavior is to translate the
bytecode instructions directly to C++.
…On Tue, Nov 13, 2018 at 3:39 PM m4nu3lf ***@***.***> wrote:
@pchasco <https://github.com/pchasco> I had a look at the implementation
right now. It is generating an internal AST it just isn't exposed with any
API. No writing another parser is not the way to go. What I was suggesting
was to have another implementation of the GDScript compiler which takes the
AST and produces the C++ code, so yes, implement something like
gdscript_compiler_cpp as part of the GDScript module. Not sure which
approach works best now
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#11068 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AChUAJtraRuSAiUA_6-NxRt5J9mn-bu2ks5uuzwUgaJpZM4PROqy>
.
|
You can use this public API: godot/modules/gdscript/gdscript_parser.h Lines 43 to 516 in 37c5aa1
|
This comment has been minimized.
This comment has been minimized.
Alright. I see the issue. What makes Godot Engine stand out from all other engines is that Godot isn't some old or proprietary or GPL/ShareAlike or non-commercial piece of software, but that it's an actual actually true truly open-source and free (free=NO STRINGS ATTACHED!) game engine that can do many things that aren't just a simple game engine such as a text editor, media player, etc.. One might as well make a simple BSD-powered permissive-licensed MIPS SoC devboard running Godot Engine as a desktop environment! I'm actually thinking about that. Imagine if we called it GodotOS or GodOS. LOL. So, to get serious, here's my point. Both the gamers/users and the developers want to have something that will work out of the box on howevermuch old or new machine they might have. Meaning that it's not the disk space that's such a big issue, but the real issue is the execution speed, stability, consistency and RAM usage. One can have 16GB of disk space for a superpowered Godot with all sorts of JIT compilers for every single CPU and chipset and platform and OS, but they cannot all have 64GB of RAM! Yes, 16GB is surely a huge issue, but the thing is that if these 16GB mean that it's not something that will break when you install a different Visual C++ Redistributable or some dependency or get a Windows update, then it's worth it. At the same time, there are users who want to have it very simple as how the Godot engine is (cca 50MB iirc). So that way, I guess it would be the best if every user could choose which version of Godot they'd like to download. Now, recoding the whole Godot infrastructure is a big problem for developers because it would create so much delay while everyone gets synchronized into where to commit which changes and where to do what and that would slow down bugfixes, security patches, new feature releases, it would spawn a ton of new bugs and security patches and people might lose interest in Godot in an instant! This is why the layers of "bloat"/abstraction should go like this: This way every one of these layers will not have to be submerged and choked and quenched by another. Instead, everyone will be doing their job and making sure that their part is done well. If the JIT compiler is perhaps made from scratch, or imagine if some of professors and college students and doctors and senior developers who are reading this or some of you who have access to talk to such people could spread the news about this and possibly get involved into making a Godot-dedicated JIT compiler that might even be a much greater alternative to all LLVMs and things that we can see on the internet. I mean, if Terry Davison could make a 2MB OS with his own programming language and everything all by himself and if it took him 10 years, then imagine how much it would take those who truly love the true open-source no-strings-attached free software development software to make this Godot dream became a reality. I hope that I've inspired people a huge lot and that the Godot Engine causes a total disruption in the gamedev software and software development software market in such a way that even the copyright laws start legalizing and indemnifying and extending Fair Use and memes and fan works (fan art, fan fiction, fan characters, video game music remixes, etc.) and other transformative works in which case the avalanche of copyright/patent liberalization might even kill some of our biggest enemy licenses; causing them to be forced to release their MIT-license-incompatible software under the MIT license. This would be the disruption of the century! And we've been waiting for this for so long! Waiting for Godot! And we shall await him! |
JIT is a waste of time because it’s not supported on some important
platforms. It is easier to compile GDScript ahead of time than to build a
JIT. Precompiled code is also more efficient and performs better in nearly
all cases.
…On Sat, May 11, 2019 at 9:19 PM RetroZvoc ***@***.***> wrote:
Alright. I see the issue. What makes Godot Engine stand out from all other
engines is that Godot isn't some old or proprietary or GPL/ShareAlike or
non-commercial piece of software, but that it's an actual actually true
truly open-source and free (free=NO STRINGS ATTACHED!) game engine that can
do many things that aren't just a simple game engine such as a text editor,
media player, etc.. One might as well make a simple BSD-powered
permissive-licensed MIPS SoC devboard running Godot Engine as a desktop
environment! I'm actually thinking about that. Imagine if we called it
GodotOS or GodOS. LOL.
So, to get serious, here's my point. Both the gamers/users and the
developers want to have something that will work out of the box on
howevermuch old or new machine they might have. Meaning that it's not the
disk space that's such a big issue, but the real issue is the execution
speed, stability, consistency and RAM usage. One can have 16GB of disk
space for a superpowered Godot with all sorts of JIT compilers for every
single CPU and chipset and platform and OS, but they cannot all have 64GB
of RAM!
Yes, 16GB is surely a huge issue, but the thing is that if these 16GB mean
that it's not something that will break when you install a different Visual
C++ Redistributable or some dependency or get a Windows update, then it's
worth it. At the same time, there are users who want to have it very simple
as how the Godot engine is (cca 50MB iirc). So that way, I guess it would
be the best if every user could choose which version of Godot they'd like
to download.
Now, recoding the whole Godot infrastructure is a big problem for
developers because it would create so much delay while everyone gets
synchronized into where to commit which changes and where to do what and
that would slow down bugfixes, security patches, new feature releases, it
would spawn a ton of new bugs and security patches and people might lose
interest in Godot in an instant!
This is why the layers of "bloat"/abstraction should go like this:
Dynamically loaded scripts (like missions; GDscript), your game code
(GDscript, C++, C#) > Godot code (GDscript, C++, C#) > JIT-ter (C++) > Any
platform you want the code to run or to compile to.
This way every one of these layers will not have to be submerged and
choked and quenched by another. Instead, everyone will be doing their job
and making sure that their part is done well. If the JIT compiler is
perhaps made from scratch, or imagine if some of professors and college
students and doctors and senior developers who are reading this or some of
you who have access to talk to such people could spread the news about this
and possibly get involved into making a Godot-dedicated JIT compiler that
might even be a much greater alternative to all LLVMs and things that we
can see on the internet. I mean, if Terry Davison could make a 2MB OS with
his own programming language and everything all by himself and if it took
him 10 years, then imagine how much it would take those who truly love the
true open-source no-strings-attached free software development software to
make this Godot dream became a reality.
I hope that I've inspired people a huge lot and that the Godot Engine
causes a total disruption in the gamedev software and software development
software market in such a way that even the copyright laws start legalizing
and indemnifying and extending Fair Use and memes and fan works (fan art,
fan fiction, fan characters, video game music remixes, etc.) and other
transformative works in which case the avalanche of copyright/patent
liberalization might even kill some of our biggest enemy licenses; causing
them to be forced to release their MIT-license-incompatible software under
the MIT license.
This would be the disruption of the century! And we've been waiting for
this for so long! Waiting for Godot! And we shall await him!
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#11068 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAUFIAHQKJ3FWAS5SHQDWPLPU55CBANCNFSM4D2E5KZA>
.
|
Well, I'm sorry. I wrongly said. JIT compiling should only be for loading things in runtime such as mods, plugins, customized multiplayer features (like custom characters with custom abilities), etc.. AOT compiling should be for everything that can be compiled at export time. Now, how far has Godot went with this JIT/AOT feature?
|
No work has been done on JIT, and I don’t think that it will be.
I have been working on an AoT module and it is very rudimentary.
http://blog.moblcade.com
…On Sun, May 12, 2019 at 9:59 AM RetroZvoc ***@***.***> wrote:
Well, I'm sorry. I wrongly said. JIT compiling should only be for loading
things in runtime such as mods, plugins, customized multiplayer features
(like custom characters with custom abilities), etc.. AOT compiling should
be for everything that can be compiled at export time.
Now, how far has Godot went with this JIT/AOT feature?
JIT is a waste of time because it’s not supported on some important
platforms. It is easier to compile GDScript ahead of time than to build a
JIT. Precompiled code is also more efficient and performs better in nearly
all cases.
… <#m_-7560708296574458465_>
On Sat, May 11, 2019 at 9:19 PM RetroZvoc *@*.***> wrote: Alright. I see
the issue. What makes Godot Engine stand out from all other engines is that
Godot isn't some old or proprietary or GPL/ShareAlike or non-commercial
piece of software, but that it's an actual actually true truly open-source
and free (free=NO STRINGS ATTACHED!) game engine that can do many things
that aren't just a simple game engine such as a text editor, media player,
etc.. One might as well make a simple BSD-powered permissive-licensed MIPS
SoC devboard running Godot Engine as a desktop environment! I'm actually
thinking about that. Imagine if we called it GodotOS or GodOS. LOL. So, to
get serious, here's my point. Both the gamers/users and the developers want
to have something that will work out of the box on howevermuch old or new
machine they might have. Meaning that it's not the disk space that's such a
big issue, but the real issue is the execution speed, stability,
consistency and RAM usage. One can have 16GB of disk space for a
superpowered Godot with all sorts of JIT compilers for every single CPU and
chipset and platform and OS, but they cannot all have 64GB of RAM! Yes,
16GB is surely a huge issue, but the thing is that if these 16GB mean that
it's not something that will break when you install a different Visual C++
Redistributable or some dependency or get a Windows update, then it's worth
it. At the same time, there are users who want to have it very simple as
how the Godot engine is (cca 50MB iirc). So that way, I guess it would be
the best if every user could choose which version of Godot they'd like to
download. Now, recoding the whole Godot infrastructure is a big problem for
developers because it would create so much delay while everyone gets
synchronized into where to commit which changes and where to do what and
that would slow down bugfixes, security patches, new feature releases, it
would spawn a ton of new bugs and security patches and people might lose
interest in Godot in an instant! This is why the layers of
"bloat"/abstraction should go like this: Dynamically loaded scripts (like
missions; GDscript), your game code (GDscript, C++, C#) > Godot code
(GDscript, C++, C#) > JIT-ter (C++) > Any platform you want the code to run
or to compile to. This way every one of these layers will not have to be
submerged and choked and quenched by another. Instead, everyone will be
doing their job and making sure that their part is done well. If the JIT
compiler is perhaps made from scratch, or imagine if some of professors and
college students and doctors and senior developers who are reading this or
some of you who have access to talk to such people could spread the news
about this and possibly get involved into making a Godot-dedicated JIT
compiler that might even be a much greater alternative to all LLVMs and
things that we can see on the internet. I mean, if Terry Davison could make
a 2MB OS with his own programming language and everything all by himself
and if it took him 10 years, then imagine how much it would take those who
truly love the true open-source no-strings-attached free software
development software to make this Godot dream became a reality. I hope that
I've inspired people a huge lot and that the Godot Engine causes a total
disruption in the gamedev software and software development software market
in such a way that even the copyright laws start legalizing and
indemnifying and extending Fair Use and memes and fan works (fan art, fan
fiction, fan characters, video game music remixes, etc.) and other
transformative works in which case the avalanche of copyright/patent
liberalization might even kill some of our biggest enemy licenses; causing
them to be forced to release their MIT-license-incompatible software under
the MIT license. This would be the disruption of the century! And we've
been waiting for this for so long! Waiting for Godot! And we shall await
him! — You are receiving this because you were mentioned. Reply to this
email directly, view it on GitHub <#11068 (comment)
<#11068 (comment)>>,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAUFIAHQKJ3FWAS5SHQDWPLPU55CBANCNFSM4D2E5KZA
.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#11068 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAUFIAEFLXSTHCM6VTA5UI3PVAWDNANCNFSM4D2E5KZA>
.
|
I hope I can directly write C++ stuff to Godot inside of Godot IDE's text editor since I'm making a desktop environment for BSD in Godot and it will run on a MIPS SoC devboard that won't have enough time for bytecode bloat (or should I say bloatcode). Can I do that?
|
Anything is possible... but I think there are many challenges you will need
to overcome.
…On Sun, May 12, 2019 at 10:22 AM RetroZvoc ***@***.***> wrote:
I hope I can directly write C++ stuff to Godot *inside* of Godot IDE's
text editor since I'm making a desktop environment for BSD in Godot and it
will run on a MIPS SoC devboard that won't have enough time for bytecode
bloat (or should I say bloatcode). Can I do that?
No work has been done on JIT, and I don’t think that it will be. I have
been working on an AoT module and it is very rudimentary.
http://blog.moblcade.com
… <#m_2176608666083770208_>
On Sun, May 12, 2019 at 9:59 AM RetroZvoc *@*.*> wrote: Well, I'm sorry.
I wrongly said. JIT compiling should only be for loading things in runtime
such as mods, plugins, customized multiplayer features (like custom
characters with custom abilities), etc.. AOT compiling should be for
everything that can be compiled at export time. Now, how far has Godot went
with this JIT/AOT feature? JIT is a waste of time because it’s not
supported on some important platforms. It is easier to compile GDScript
ahead of time than to build a JIT. Precompiled code is also more efficient
and performs better in nearly all cases. … <#m_-7560708296574458465_> On
Sat, May 11, 2019 at 9:19 PM RetroZvoc @.*> wrote: Alright. I see the
issue. What makes Godot Engine stand out from all other engines is that
Godot isn't some old or proprietary or GPL/ShareAlike or non-commercial
piece of software, but that it's an actual actually true truly open-source
and free (free=NO STRINGS ATTACHED!) game engine that can do many things
that aren't just a simple game engine such as a text editor, media player,
etc.. One might as well make a simple BSD-powered permissive-licensed MIPS
SoC devboard running Godot Engine as a desktop environment! I'm actually
thinking about that. Imagine if we called it GodotOS or GodOS. LOL. So, to
get serious, here's my point. Both the gamers/users and the developers want
to have something that will work out of the box on howevermuch old or new
machine they might have. Meaning that it's not the disk space that's such a
big issue, but the real issue is the execution speed, stability,
consistency and RAM usage. One can have 16GB of disk space for a
superpowered Godot with all sorts of JIT compilers for every single CPU and
chipset and platform and OS, but they cannot all have 64GB of RAM! Yes,
16GB is surely a huge issue, but the thing is that if these 16GB mean that
it's not something that will break when you install a different Visual C++
Redistributable or some dependency or get a Windows update, then it's worth
it. At the same time, there are users who want to have it very simple as
how the Godot engine is (cca 50MB iirc). So that way, I guess it would be
the best if every user could choose which version of Godot they'd like to
download. Now, recoding the whole Godot infrastructure is a big problem for
developers because it would create so much delay while everyone gets
synchronized into where to commit which changes and where to do what and
that would slow down bugfixes, security patches, new feature releases, it
would spawn a ton of new bugs and security patches and people might lose
interest in Godot in an instant! This is why the layers of
"bloat"/abstraction should go like this: Dynamically loaded scripts (like
missions; GDscript), your game code (GDscript, C++, C#) > Godot code
(GDscript, C++, C#) > JIT-ter (C++) > Any platform you want the code to run
or to compile to. This way every one of these layers will not have to be
submerged and choked and quenched by another. Instead, everyone will be
doing their job and making sure that their part is done well. If the JIT
compiler is perhaps made from scratch, or imagine if some of professors and
college students and doctors and senior developers who are reading this or
some of you who have access to talk to such people could spread the news
about this and possibly get involved into making a Godot-dedicated JIT
compiler that might even be a much greater alternative to all LLVMs and
things that we can see on the internet. I mean, if Terry Davison could make
a 2MB OS with his own programming language and everything all by himself
and if it took him 10 years, then imagine how much it would take those who
truly love the true open-source no-strings-attached free software
development software to make this Godot dream became a reality. I hope that
I've inspired people a huge lot and that the Godot Engine causes a total
disruption in the gamedev software and software development software market
in such a way that even the copyright laws start legalizing and
indemnifying and extending Fair Use and memes and fan works (fan art, fan
fiction, fan characters, video game music remixes, etc.) and other
transformative works in which case the avalanche of copyright/patent
liberalization might even kill some of our biggest enemy licenses; causing
them to be forced to release their MIT-license-incompatible software under
the MIT license. This would be the disruption of the century! And we've
been waiting for this for so long! Waiting for Godot! And we shall await
him! — You are receiving this because you were mentioned. Reply to this
email directly, view it on GitHub <#11068
<#11068> (comment) <#11068
(comment)
<#11068 (comment)>>>,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAUFIAHQKJ3FWAS5SHQDWPLPU55CBANCNFSM4D2E5KZA
. — You are receiving this because you were mentioned. Reply to this email
directly, view it on GitHub <#11068 (comment)
<#11068 (comment)>>,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAUFIAEFLXSTHCM6VTA5UI3PVAWDNANCNFSM4D2E5KZA
.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#11068 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAUFIADIIIPCUME74MBZAWDPVAY3NANCNFSM4D2E5KZA>
.
|
Closing this because we are moving proposals out of this repo to a new proposal repository. Also this feature is very likely coming in the upcoming GDScript rewrite, so there's no need to make a new proposal. |
Shouldn't a proposal be made anyways so the people here have one central
place to track any progress or updates, especially in case it doesn't come
in the GDScript rewrite?
…On Thu, May 28, 2020, 11:57 AM Tomek ***@***.***> wrote:
Closed #11068 <#11068>.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#11068 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABBEIS3RIEDFEG6QT3GLMITRT2JYHANCNFSM4D2E5KZA>
.
|
@Two-Tone GIP is likely not an appropriate place to "track" proposals. For example, I wanted to keep such a tracker proposal here: godotengine/godot-proposals#569, but was suggested to close it unfortunately. Meanwhile, feel free to use Godot Ideas repository for such things (it's unofficial though). |
Actually, reduz has an idea for this and said he will come up with a proposal of how it would work. I'm not against opening a GIP for this in any case. You do need to follow the template though. @Xrayez my comment there is that it was more like a bug than a proposal, so it should be treated as such. If you want to track all issues with module, you can create a tracker here listing all related reports (as we already have a few). |
I am proposing to compile all gdscript code into gdnative C when exporting the game and store/run scripts as gdnative from here on. This conversion from gdscript to gdnative likely will have to change the Export Templates and might require extra work.
But I think this would not only make scripts run faster in the game but also take way less memory and drive space.
Originally I was thinking of JIT compile gdscript to gdnative at game run time but this method would actually be a compromise between interpreting gdscript and JIT.
This method can probably be used for Visual Script as well converted to gdnative which would make VS relatively as fast as gdscript I guess.
You guys decide if is something worth doing or not. Just putting it out there . Thank you.
The text was updated successfully, but these errors were encountered: