Optimize WorldFileData
aikar opened this issue ยท 2 comments
I see you have your own form of RegionFileCache in WorldBorder
I suggest you apply the following improvement to the code to improve IO performance reading Region Files :)
This will improve performance.
Hmm, looks reasonable and straightforward enough. Not gonna lie though, that header.clear() threw me for a loop until I looked into what that clear() actually does (as opposed to what you'd expect) and how asIntBuffer() initializes based on the current position.
I'll probably test and implement this in a little while when I have the time for it.
After some brief testing, doing a timing profile of the specific section of code with 10 runs on the same initial world and Fill task, 5 runs before and 5 after making the suggested change, it indicated a bit over 5x faster execution of that algorithm in my test environment. Nice.
Went ahead with it.
af4727d