kernelsauce/turbo — pull request #90 by kernelsauce (2013-11-03 19:47:46+00:00)
Title: httputil refactor

Refactoring of HTTPHeaders class into two classes:

HTTPParser - for parsing HTTP headers
HTTPHeaders - for generating HTTP headers

The Ryan Dahl C wrapper has been changed to not dupe strings but rather return offsets and sizes to the parsed const char*. This produces a much lower count of small malloc and subsequent free's increasing performance.

Also contains some movement of ffi.new's to upvalues.

On my Lenovo T430 this leads to roughly 3-4 k extra requests per sec running helloworld.lua...