On 2023-03-07 20:02, Anders Magnusson wrote:
I have a little hard time believing it's the CAS handling that is having a problem with large memories though. Why do you think it's there?% grep CASMAGIC include/trap.h #define CASMAGIC 0xBEDABABE /* highend of S0 space */ .globl cas32_ras_start, cas32_ras_end cas32_ras_start: movl %r1,(%r4) movl *(%r4), %r0 cmpl %r2,%r0 bneq 1f movl %r3,*(%r4) cas32_ras_end: 1: movl $CASMAGIC, (%r4) rsb
Hmm. Good point. But that thing is only loading CASMAGIC if the address did not contain the value expected. I can't see how any size of memory would be an issue in here.
However, it does remind me that there is code elsewhere that checks if we're currently executing between cas32_ras_start and cas32_ras_end, to ensure the atomicity of the CAS implementation. I wonder if there might be some stupid signed issue with the comparison of those to addresses... This could be something...?
Johnny -- Johnny Billquist || "I'm on a bus || on a psychedelic trip email: bqt%softjar.se@localhost || Reading murder books pdp is alive! || tryin' to stay hip" - B. Idol