re2j icon indicating copy to clipboard operation
re2j copied to clipboard

Few minor bugs

Open jpaulynice opened this issue 9 years ago • 2 comments

Hi,

While investigating some slow issue with re2j compared to java regular expression, I found a few issues that I am planning to create a PR for:

See these 2 commits I have in my branch (don't worry about the System.out.print lines):

  1. https://github.com/julesbond007/re2j/commit/af6e399286975d972bfab90bc272e9ffbbcb876e
  2. https://github.com/julesbond007/re2j/commit/3ea3aef9b4d46c57b5687308a12eac3db87a5997

Question: private void free(Thread t) method is not used in Machine.java what was the intention?

Regards,

Jay

jpaulynice avatar Feb 19 '16 19:02 jpaulynice

I think 'free' was a relic from the Go implementation; it used a freelist to reduce the cost of memory allocation, which is (or at least, was then), higher in Go than on the JVM.

adonovan avatar Feb 20 '16 17:02 adonovan

I see thanks!

jpaulynice avatar Feb 21 '16 15:02 jpaulynice