Changes to runtime for read/write lock implementation