@thakis I gave this patch a try. It seems to work apart from the i386 tests that will not work on macOS Catalina. We can deal with that later though.
I've never looked at the builtins before. There are some very weird things about the tests here that don't make any sense to me but that's not part of this patch so I won't dwell on them here.