2011/7/3 Karl Williamson <public@khwilliamson.com>: > I know Yves has said that he hates this aspect of this. It looks to me that > it should be easy to remove this pass, and treat regex compilation similarly > to string parsing: if you run out of room from your initial guess, you just > realloc more space, trimming at the end. > > Is there something people are aware of that I'm not seeing here? Performance probably. I had the same problem in my Jit, and Gerard in his codegen. I used two passes because realloc was a performance pain and my blocks were quite large. Gerard used the single-pass realloc approach. Benchmarks are missing to compare both cases. Both versions are "relatively slow". -- ReiniThread Previous