topic/jsiwek/jj-bugs

Description

This branch is in bro, bro-testing, and bro-testing-private repos, fixing problems reported in BIT-1240, BIT-1246, BIT-1247, and BIT-1248.

Environment

None

Activity

Show:
Robin Sommer
September 13, 2014, 2:48 AM

Merged, but two questions:

  • HTTP_Message::entity_data_buffer: that's allocated with every
    HTTP message. Would there be any benefit to allocate it only on
    demand when it's actually used? I can't immediately tell if the
    buffer is indeed going to be accessed generally with every message, or
    only sometimes.

  • I'm seeing somewhat longer execution times:

Could this even be related to that buffer above?

Oddly enough, I'm seeing better times for the v6 trace:

(These failures are consistent across multiple runs; sometimes I get
false alarms with the timing measurements, but normally they
disappear on reruns.)

Closing the individual tickets but leaving this ticket open for now.
Please check and close if everything looks good / you can't reproduce
the timing differences.

Jon Siwek
September 15, 2014, 6:42 PM

HTTP_Message::entity_data_buffer: that's allocated with every
HTTP message. Would there be any benefit to allocate it only on
demand when it's actually used? I can't immediately tell if the
buffer is indeed going to be accessed generally with every message, or
only sometimes.

Good point. It is only used sometimes.

I'm seeing somewhat longer execution times:
Could this even be related to that buffer above?

Doing some quick timings of test.medium I got a similar result: +1.6%. Changing that buffer to be allocated on-demand seemed to make the difference negligible, so I think that explains it. And IIRC, the original code also did allocation on-demand. I'll commit the change to master.

Assignee

Unassigned

Reporter

Jon Siwek

Labels

None

External issue ID

None

Components

Fix versions

Affects versions

Priority

Normal
Configure