chunks: code cleanups
* Introduce getSegmentFromPacket() helper function
* Use signed arithmetic for some quantities to avoid conversion issues
* Move start time handling to PipelineInterests base class
Change-Id: I275acac1ad93e4a72374d03fad0a1d7348d70976
diff --git a/tools/chunks/catchunks/pipeline-interests-aimd.hpp b/tools/chunks/catchunks/pipeline-interests-aimd.hpp
index c67d5bc..1670fda 100644
--- a/tools/chunks/catchunks/pipeline-interests-aimd.hpp
+++ b/tools/chunks/catchunks/pipeline-interests-aimd.hpp
@@ -1,3 +1,4 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
/**
* Copyright (c) 2016-2017, Regents of the University of California,
* Colorado State University,
@@ -196,12 +197,10 @@
uint64_t m_recPoint; ///< the value of m_highInterest when a packet loss event occurred,
///< it remains fixed until the next packet loss event happens
- uint64_t m_nInFlight; ///< # of segments in flight
- uint64_t m_nReceived; ///< # of segments received
- uint64_t m_nLossEvents; ///< # of loss events occurred
- uint64_t m_nRetransmitted; ///< # of segments retransmitted
-
- time::steady_clock::TimePoint m_startTime; ///< start time of pipelining
+ int64_t m_nInFlight; ///< # of segments in flight
+ int64_t m_nReceived; ///< # of segments received
+ int64_t m_nLossEvents; ///< # of loss events occurred
+ int64_t m_nRetransmitted; ///< # of segments retransmitted
double m_cwnd; ///< current congestion window size (in segments)
double m_ssthresh; ///< current slow start threshold