Opened 10 months ago

Last modified 8 months ago

#25328 assigned enhancement

cmux: Refactor, test and improve performance of the circuitmux subsystem

Reported by: dgoulet Owned by: dgoulet
Priority: Low Milestone: Tor: unspecified
Component: Core Tor/Tor Version:
Severity: Normal Keywords: tor-cmux, tor-relay, refactoring, 034-triage-20180328, 034-removed-20180328
Cc: Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

The cmux subsystem (src/or/circuitmux.c) is part of tor's fast path. It gets called at every cell or at every few cell and every new or dying circuit.

It is currently in our top 5 of CPU hugger (see #25152) and also has a certain complexity to it. However, in practice, it should be quite simple. #25268 helps a lot by removing dead code and helping making the code more readable.

In order to improve that subsystem, there are few steps that need to be taken before we can address something like #25152. Furthermore, in order to fix some things in the scheduler (#23993), this work should be done so we don't add more complexity to that code.

Refactoring this subsystem to something more simple also will help testing it for which right now, it is virtually untested (see src/test/test_circuitmux.c).

I'm taking this ticket because I do have planned out this work already and it might change over time.

Child Tickets

TicketTypeStatusOwnerSummary
#25268enhancementcloseddgouletcmux: Remove round robin code and make EWMA mandatory
#25312defectassigneddgouletcirc: We can pick an active circuit that is marked for close

Change History (3)

comment:1 Changed 9 months ago by nickm

Keywords: 034-triage-20180328 added

comment:2 Changed 9 months ago by nickm

Keywords: 034-removed-20180328 added

Per our triage process, these tickets are pending removal from 0.3.4.

comment:3 Changed 8 months ago by nickm

Milestone: Tor: 0.3.4.x-finalTor: unspecified

These tickets, tagged with 034-removed-*, are no longer in-scope for 0.3.4. We can reconsider any of them, if time permits.

Note: See TracTickets for help on using tickets.