Path: ...!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!eternal-september.org!.POSTED!not-for-mail From: olcott Newsgroups: comp.lang.c Subject: Re: DD simulated by HHH cannot possibly halt (Halting Problem) Date: Sat, 5 Apr 2025 18:16:56 -0500 Organization: A noiseless patient Spider Lines: 60 Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Date: Sun, 06 Apr 2025 01:16:56 +0200 (CEST) Injection-Info: dont-email.me; posting-host="ef4cc0d21fd1ecbcf29cd91ea99c5a02"; logging-data="3636667"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18Aicu+jbq6EwFtwASWiZMg" User-Agent: Mozilla Thunderbird Cancel-Lock: sha1:64V8N19+iIPJWA4HBwb1mbxrgnQ= Content-Language: en-US X-Antivirus: Norton (VPS 250405-6, 4/5/2025), Outbound message In-Reply-To: X-Antivirus-Status: Clean Bytes: 3798 On 4/5/2025 5:14 PM, Richard Heathfield wrote: > On 05/04/2025 22:20, olcott wrote: >> On 4/5/2025 3:30 PM, Richard Heathfield wrote: >>> On 05/04/2025 20:21, olcott wrote: >>>> On 4/5/2025 2:12 PM, Richard Heathfield wrote: >>>>> On 05/04/2025 20:01, olcott wrote: >>>>>> As any C programmer can see DDD simulated by HHH would cause >>>>>> any correct simulator to get stuck in recursive simulation >>>>> >>>>> As any C programmer can see, any C compiler is free to reject your >>>>> code, >>>> >>>> typedef void (*ptr)(); >>>> int HHH(ptr P); >>>> >>>> void DDD() >>>> { >>>>    HHH(DDD); >>>>    return; >>>> } >>>> >>>> The above code is correct to the extent that some >>>> HHH is defined somewhere, so it seems that you are >>>> wrong >>> >>> No, you just don't know what I'm talking about. That doesn't surprise >>> me, of course. >>> >>> I'm talking about your HHH code. Any conforming compiler can reject >>> your assembly language inserts. >>> >> >> I am not taking about that code. > > Yes, you are. And I quote: "As any C programmer can see DDD simulated by > HHH" > >> This post has only been about a hypothetical >> HHH that simulates its input. > > If you don't wish to be misunderstood, it would be a good idea for you > to learn to express yourself more clearly. For example, you could choose > better names for your hypothetical functions to avoid confusion between > them and functions for which you've published the code on github. > I am trying to explain how the actual HHH works one step at a time. The first step is knowing how every hypothetical HHH would meet this spec with DDD as input: *Simulating termination analyzer Principle* It is always correct for any simulating termination analyzer to stop simulating and reject any input that would otherwise prevent its own termination. -- Copyright 2025 Olcott "Talent hits a target no one else can hit; Genius hits a target no one else can see." Arthur Schopenhauer