Liste des Groupes | Revenir à l c |
On 5/24/2024 5:08 AM, Mikko wrote:I think all C questions are already answered.On 2024-05-23 13:09:01 +0000, olcott said:typedef int (*ptr)(); // ptr is pointer to int function in C
On 5/23/2024 3:23 AM, Mikko wrote:That is possible. What you said is scattered over so many messagesOn 2024-05-22 14:59:24 +0000, olcott said:That assessment can only come from not carefully looking at what I said.
On 5/22/2024 3:50 AM, David Brown wrote:Someone already pointed out that the question is ill-posed (undefinedOn 21/05/2024 22:13, Keith Thompson wrote:*Someone could simply answer the question instead of*David Brown <david.brown@hesbynett.no> writes:I don't consider James' post to be trolling. But of course that in itself does not mean it is appropriate to reply here. However, I replied to that post in the group (rather than email) because it seemed to me that a point I had made previously needed clarification.
[...]However, my point was that the common excuse of "I hate this crime so[...]
much I lashed out" is not a valid excuse.
And you could have made that point without accompanying it by a long
article about various kinds of child abuse in a newsgroup that's
supposed to be about C.
You didn't have to let yourself be trolled.
As has been pointed out by others, topicality in this thread was doomed from the first post. I'd be happier if Olcott had never cross-posted here, but we can't change that.
*spending countless messages on dodging the question*
For every H/D pair matching the following template where
H is a pure function:
Does any D correctly simulated by H reach its own line 06 and
halt or does the fact that D remains stuck in recursive simulation
prevent that?
typedef int (*ptr)(); // ptr is pointer to int function in C
00 int H(ptr p, ptr i);
01 int D(ptr p)
02 {
03 int Halt_Status = H(p, p);
04 if (Halt_Status)
05 HERE: goto HERE;
06 return Halt_Status;
07 }
08
09 int main()
10 {
11 H(D,D);
12 return 0;
13 }
It is trivial to see that for every H/D pair of the infinite
set of H/D pairs that match the above template that
D correctly simulated by H cannot possibly reach its own final
state at line 06 and halt because D correctly simulated by
H remains stuck in recursive simulation.
This provides the basis for simulating termination analyzer H to
correctly determine that the halting problem's counter-example
input D cannot possibly halt.
and insonsistently used symbols). No reason to expect any other answer.
It is dead obvious that D correctly simulated by H remains stuck in
recursive simulation thus cannot possibly reach its own line 06 and
halt.
that nobody can be expedted to carefully look at all of them.
00 int H(ptr p, ptr i);
01 int D(ptr p)
02 {
03 int Halt_Status = H(p, p);
04 if (Halt_Status)
05 HERE: goto HERE;
06 return Halt_Status;
07 }
08
09 int main()
10 {
11 H(D,D);
12 return 0;
13 }
The above template refers to an infinite set of H/D pairs where D is correctly simulated by pure function H. This was done because many reviewers used the shell game ploy to endlessly switch which H/D pair was being referred to.
*Correct Simulation Defined*
This is provided because many reviewers had a different notion of
correct simulation that diverges from this notion.
A simulator is an x86 emulator that correctly emulates at least one
of the x86 instructions of D in the order specified by the x86
instructions of D.
This may include correctly emulating the x86 instructions of H in the
order specified by the x86 instructions of H thus calling H(D,D) in
recursive simulation.
*Execution Trace*
Line 11: main() invokes H(D,D); H(D,D) simulates lines 01, 02, and 03 of D. This invokes H(D,D) again to repeat the process in endless recursive simulation.
Les messages affichés proviennent d'usenet.