[DGD] Why use callouts in klib to increment resources?

Tony Demetriou tony.demetriou at gmail.com
Mon Oct 22 05:36:14 CEST 2018


I don't know what's happening under-the-hood, but in Skotos world, we did a
*lot* more processing on Ironclaw than other games, and were the first to
start running into those "out of ticks" errors during normal game use.
(Other games only got that error when they made an infinite loop.)

We increased the quota, and didn't spot any negative issues from our
benchmarking before/after the change. In fact, the game ran a little faster
afterwards, because hitting the "out of ticks" error seems to slow down
everything.

I don't know if later on we'll run into problems, but anecdotally the only
thing this limit did for us was decide when to kill an accidental infinite
loop.

(And, of course, I'm talking about infinite loops on the user-scripted
side. What we call "merry" code. Not in your engine code. The joys of
building a game with a staff of non-programmers! Honestly, I miss it.)

Cheers,
Tony


On Mon, Oct 22, 2018 at 8:24 AM Raymond Jennings <shentino at gmail.com> wrote:

> I meant if the admin imposes a quota.
>
> Are you sure that no checks are performed though?
>
> If I'm not mistaken there does appear to be code present in
> /kernel/sys/rsrcd and /kernel/obj/rsrc to enforce that quota, via
> checks performed during call_limited.
>
> I just ran a test against your version and it does in fact cause "out
> of ticks" errors once someone's quota has been exhausted.
> On Sun, Oct 21, 2018 at 8:42 AM Felix A. Croes <felix at dworkin.nl> wrote:
> >
> > Raymond Jennings <shentino at gmail.com> wrote:
> >
> > > Any concerns about causing a DoS by evading a "tick usage" quota?  The
> > > tick updates don't update this resource (and thus trigger a new
> > > rlimits check) immediately.
> >
> > The "tick usage" resource doesn't have a quota, and no checks are
> > performed for it.
> >
> > Regards,
> > Felix Croes
> > ____________________________________________
> > https://mail.dworkin.nl/mailman/listinfo/dgd
> ____________________________________________
> https://mail.dworkin.nl/mailman/listinfo/dgd



More information about the DGD mailing list