Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.c > #160177

Re: Infinite recursion detection criteria (Please correct me if I am wrong)

From Kaz Kylheku <563-365-8930@kylheku.com>
Newsgroups comp.lang.c, comp.theory, comp.lang.c++
Subject Re: Infinite recursion detection criteria (Please correct me if I am wrong)
Followup-To comp.theory
Date 2021-04-18 01:57 +0000
Organization A noiseless patient Spider
Message-ID <20210417183423.843@kylheku.com> (permalink)
References (6 earlier) <XcydnYxoMqAmv-b9nZ2dnUU7-eudnZ2d@giganews.com> <20210417113404.674@kylheku.com> <Z5GdnT7RU7qWsub9nZ2dnUU7-d_NnZ2d@giganews.com> <20210417115640.436@kylheku.com> <XsGdnb9T0vcLqOb9nZ2dnUU7-U_NnZ2d@giganews.com>

Cross-posted to 3 groups.

Followups directed to: comp.theory

Show all headers | View raw


On 2021-04-17, olcott <NoOne@NoWhere.com> wrote:
> Can we get back to the actual point or are you afraid to do this because 
> when a point is correct there is no basis for rebuttal?
>
> The halt deciding principle
> If a function X() is called by function Y() twice in sequence from the 
> same machine address of Y() with the same parameters to X() and the 
> execution trace shows no conditional branch instructions in Y() or 
> function call returns from X() then the function call from Y() to X() is 
> infinitely recursive unless X() stops it.

No, I do not agree. If the execution trace shows no conditional branch
instructions, then the situation is runaway recursive, period.
Nothing will stop it but stack exhaustion.

X doesn't do anything such as making a decision to terminate. If it did,
that would contradict the assumption that there are no conditional
instructions being executed in the recursive loop.

In your implementation of this, there are gaps in the instruction trace.
Y (called _H_Hat) invokes X (_Halts) via a CALL 00000883 instruction.
But the next element in the trace is not the address 00000833 which was
called, but, unexpectedy, but the address of _H_Hat itself, 00000a63.

There is a "trace black out" starting with 00000833 until 00000a63.

Your document also does not not show the disassembly listing of the
procedure at 00000833.

(I suspect that CALL 0000833 isn't a function call at all; the simulator
is rigged to recognize this address.  You've hinted at the fact that
_Halts is a built-in simulation primitive and not an actual function.)

What you must do is provide a complete diassembly listing of all code
that is invoked. That code must be executed in accordance with the x86
instruction set architecture from Intel without any sneaky extensions.
There must be no puzzing gaps in the execution traces. If there is a
CALL X, the next instruction to be traced must be X.

You must also trace the value of every register. I.e add columns to the
trace for EAX, EBX, ... to show nothing is messing with their contents.
Just like your current trace  has a surprising discontinuity in the EIP
register, any other register could have a surprising change not
reflected in what the instructions are doing.

Back to comp.lang.c | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Infinite recursion detection criteria (Please correct me if I am olcott <NoOne@nospicedham.NoWhere.com> - 2021-04-17 09:15 -0500
  Re: Infinite recursion detection criteria (Please correct me if I am MrSpook__k@rw5_r42g0rzmn7wwf3izpl4.biz - 2021-04-17 15:16 +0000
    Re: Infinite recursion detection criteria (Please correct me if I am olcott <NoOne@NoWhere.com> - 2021-04-17 10:22 -0500
      Re: Infinite recursion detection criteria (Please correct me if I am MrSpook_ejo78o@4t98owsqx2nlg6yp.com - 2021-04-17 15:32 +0000
      Re: Infinite recursion detection criteria (Please correct me if I am Kaz Kylheku <563-365-8930@kylheku.com> - 2021-04-17 15:41 +0000
        Re: Infinite recursion detection criteria (Please correct me if I am olcott <NoOne@NoWhere.com> - 2021-04-17 11:56 -0500
        Re: Infinite recursion detection criteria (Please correct me if I am olcott <NoOne@NoWhere.com> - 2021-04-17 11:57 -0500
          Re: Infinite recursion detection criteria (Please correct me if I am Kaz Kylheku <563-365-8930@kylheku.com> - 2021-04-17 17:25 +0000
            Re: Infinite recursion detection criteria (Please correct me if I am olcott <NoOne@NoWhere.com> - 2021-04-17 12:43 -0500
              Re: Infinite recursion detection criteria (Please correct me if I am Kaz Kylheku <563-365-8930@kylheku.com> - 2021-04-17 18:33 +0000
            Re: Infinite recursion detection criteria (Please correct me if I am olcott <NoOne@NoWhere.com> - 2021-04-17 13:02 -0500
              Re: Infinite recursion detection criteria (Please correct me if I am Kaz Kylheku <563-365-8930@kylheku.com> - 2021-04-17 18:37 +0000
                Re: Infinite recursion detection criteria (Please correct me if I am olcott <NoOne@NoWhere.com> - 2021-04-17 13:55 -0500
                Re: Infinite recursion detection criteria (Please correct me if I am Kaz Kylheku <563-365-8930@kylheku.com> - 2021-04-17 19:14 +0000
                Re: Infinite recursion detection criteria (Please correct me if I am wrong) olcott <NoOne@NoWhere.com> - 2021-04-17 14:23 -0500
                Re: Infinite recursion detection criteria (Please correct me if I am wrong) Real Troll <rel.troll@trolls.com> - 2021-04-17 20:38 +0100
                Re: Infinite recursion detection criteria (Please correct me if I am wrong) olcott <NoOne@NoWhere.com> - 2021-04-17 15:01 -0500
                Re: Infinite recursion detection criteria (Please correct me if I am wrong) Kaz Kylheku <563-365-8930@kylheku.com> - 2021-04-18 01:57 +0000
                Re: Infinite recursion detection criteria (Please correct me if I am Malcolm McLean <malcolm.arthur.mclean@gmail.com> - 2021-04-17 13:47 -0700
                Re: Infinite recursion detection criteria (dodging the point?) olcott <NoOne@NoWhere.com> - 2021-04-17 15:56 -0500
                Re: Infinite recursion detection criteria (dodging the point?) Malcolm McLean <malcolm.arthur.mclean@gmail.com> - 2021-04-17 14:24 -0700
                Re: Infinite recursion detection criteria (dodging the point?) olcott <NoOne@NoWhere.com> - 2021-04-17 16:26 -0500
        Re: Infinite recursion detection criteria (Please correct me if I am wrong) olcott <NoOne@NoWhere.com> - 2021-04-17 14:02 -0500
  Re: Infinite recursion detection criteria (Please correct me if I am olcott <NoOne@nospicedham.NoWhere.com> - 2021-04-17 11:01 -0500
  Re: Infinite recursion detection criteria (Please correct me if I am Kaz Kylheku <563-365-8930@nospicedham.kylheku.com> - 2021-04-17 15:01 +0000
    Re: Infinite recursion detection criteria (Please correct me if I am olcott <NoOne@NoWhere.com> - 2021-04-17 17:10 -0500
    Re: Infinite recursion detection criteria (Please correct me if I am olcott <NoOne@NoWhere.com> - 2021-04-17 17:30 -0500
      Re: Infinite recursion detection criteria (Please correct me if I am Kaz Kylheku <563-365-8930@kylheku.com> - 2021-04-18 01:58 +0000
  Re: Infinite recursion detection criteria (Please correct me if I am Bonita Montero <Bonita.Montero@gmail.com> - 2021-04-18 00:03 +0200
    Re: Infinite recursion detection criteria (Please correct me if I am olcott <NoOne@NoWhere.com> - 2021-04-17 17:12 -0500
  Re: Infinite recursion detection criteria (Please correct me if I am R Kym Horsell <kym@kymhorsell.com> - 2021-04-18 00:06 +0000

csiph-web