Path: ...!2.eu.feeder.erje.net!3.eu.feeder.erje.net!feeder.erje.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: "Chris M. Thomasson" Newsgroups: comp.lang.c,comp.lang.c++ Subject: Re: Can someone please verify the execution trace of this? Date: Mon, 20 May 2024 13:32:57 -0700 Organization: A noiseless patient Spider Lines: 39 Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Date: Mon, 20 May 2024 22:32:58 +0200 (CEST) Injection-Info: dont-email.me; posting-host="c64270d287de33e0b6496e257486af9b"; logging-data="165370"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18GKyqhbfdSDPUXimnImKxLusQ13VuWlRo=" User-Agent: Mozilla Thunderbird Cancel-Lock: sha1:AAhBoDi39BCrMyHmgnb1ZY4y5aQ= In-Reply-To: Content-Language: en-US Bytes: 3043 On 5/20/2024 1:31 PM, Chris M. Thomasson wrote: > On 5/20/2024 1:30 PM, olcott wrote: >> On 5/20/2024 3:19 PM, Chris M. Thomasson wrote: >>> On 5/20/2024 1:10 PM, olcott wrote: >>>> On 5/20/2024 3:04 PM, Chris M. Thomasson wrote: [...] >>> So, you created a simulator for x86? 32-bit I am assuming. Fwiw, I am >>> interested on how you simulate the cmpxchg8b and/or the cmpxchg16b >>> functions? >>> >> >> I use libx86emu providing an interface so that any C function >> can simulate any other C function in debug step mode. The >> original H can even simulated itself simulating P. > > Can you show me a sample H? Is H a little program? [...] I notice this: typedef int (*ptr)(); // ptr is pointer to int function 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 } But, where is H?