-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Failures in rfunge test suite #1
Comments
@tjol I am a fan of differential testing for compilers, and I had considered doing something similar for Funge-98, so I appreciate your efforts on this.
|
Fix make clean when files are deleted.
|
I faintly recall making this mistake myself originally, but RC/Funge-98 is where this fingerprint came from and it implemented it as bitwise operations, so that's just how it is. 🤷🏻
I think you're giving me too much credit there. It was ~15 years ago so I obviously can't be sure, but I suspect I just wrote a simple test without thinking about it too much. At the time I wasn't much good at thinking of tests that could catch incorrect implementations. Mycology saw a lot of updates while cfunge was being developed, to catch more corner cases, but I guess we missed this one. Nice to see some interest in Befunge, btw! |
|
Right, I didn’t think about fingerprints being inherited. I think the REFC test is the only one that actually combines fingerprints and |
I just tested on your feature/fingerprints branch. Some observations:
I hadn't noticed that you have FPDP and FPSP implementations in the other branch. There the tests fail because of formatting. How floats should be printed is not specified and really not important, but just so you know most (all?) other implementations use the defaults for C |
This is good enough for a single universe but might need to change for multiverse.
Hi! I'm working on a Funge-98 interpreter in Rust (rfunge), and I thought I'd run a few other quality befunge interpreters over my test suite – including yours!
My expected outputs are generally generated with either cfunge or CCBI; I do test a few finer points that Mycology doesn't cover.
Funge++ fails a few tests which I rather think it should pass; you can try it yourself using my testing script if you like.
The issues (IMHO) are:
"BOOL"
fingerprint: The docs say these are logic functions, but in every other implementation they’re bitwise operations.; ... ;
takes a tick?"HRTI"
fingerprint: my test starts the timer, checks the number of sub-second microseconds withS
, and then busy-waits until the next second (as determined usingy
). Now we know that at least 1000000 - (result ofS
) μs have passed. We then read the timer, add a small margin of error, and check that enough time has indeed passed. This isn't the most robust test, but even on interpreters where it sometimes fails (like pyfunge), it usually works. On Funge++, it practically always fails...k;
: While there is disagreement about whether0k;@;1
should skip over;@;
or only;
, most interpreters agree that1k;@;1
should skip over;@;
and execute the1
twice, not execute@
(which is what Funge++ currently does)"MODU"
fingerprint: I happen to think the behaviour you have chosen (which is the same as several other interpreters) is mathematically absurd. (see https://github.com/tjol/rfunge/wiki/Fingerprints#modu-0x4d4f4455), but I fully accept that this is my least defensible complaint here"REFC"
test fails – I suspect this is a concurrency issue rather than a problem with the fingerprint.I know this is a lot for one "issue" – just thought it might be of some interest! :-)
The text was updated successfully, but these errors were encountered: