Add a new SQLite backend

This is lacking the hacky changes I had to make to the test runners since those changes broke all the other backends.
rather than getting all events into memory, do an ORDER BY TIME (asc or desc depending on `order`) and then only when two events have the same time value, sort them by timeuuid.