- Subject: Re: [slang-users] Using the tcc module
- From: Sebastian Gniazdowski <sgniazdowski@xxxxxxxxx>
- Date: Wed, 27 Jan 2021 07:14:40 -0600
On Thu, 21 Jan 2021 at 01:32, John E. Davis <jed@xxxxxxxxxxx> wrote:
> Sebastian Gniazdowski <sgniazdowski@xxxxxxxxx> wrote:
> > I saw some exciting posts in the archives about an embedded, jit C
> compiler
> > …
The slang interpreter provides interfaces to many C functions,
> including printf. So, I am not sure exactly what you mean.
>
I was only giving an example of a C code to run through tcc.
> The promising thing about tcc is that one would be able to execute
> small code fragments that cannot be vectorized much faster than is
> possible by the interpreter.
>
Yes, I have also realized this, so that TCC is not a toy for me to include
in MC, it's a fully justified feature that when added to the scripting
support of MC/MCEdit, will provide with a concrete gains.
> The one thing stopping me from adding the module to the distribution
> is that current implementation does not guarantee that a user cannot
> crash the interpreter and the application embedding it via interpreter
> statements. For example, suppose the slang interpreter invokes tcc
> via an intrinsic called `tcc`:
>
I think that this is not a problem. If someone codes in C, then he can get
segfaults. However, it's possible to write a segfault-free C code, so with
the top performance of it, it's all fine, IMO.
>
> --John
> _______________________________________________
> For list information, visit <http://jedsoft.org/slang/mailinglists.html>.
>
>
--
Sebastian Gniazdowski
[2021 date index]
[2021 thread index]
[Thread Prev] [Thread Next]
[Date Prev] [Date Next]