Inheritance diagram for ACTP_ADC:


Definition at line 53 of file actp-adc.cc.
Public Member Functions | |
| ACTP_ADC () | |
| int | command (int, const char *const *) |
| virtual void | debug (const char *fmt,...) |
| virtual int | delay_bind_dispatch (const char *varName, const char *localName, TclObject *tracer) |
| virtual void | delay_bind_init_all () |
| int | isdebug () const |
| double | peak_rate (int cl, double r, int b) |
| virtual void | recv (Packet *p, const char *s) |
| void | recv (Packet *, Handler *) |
| virtual void | recvOnly (Packet *) |
| void | rej_action (int, double, int) |
| void | setest (int cl, Estimator *est) |
| void | teardown_action (int, double, int) |
| char * | type () |
Protected Member Functions | |
| int | admit_flow (int, double, int) |
| void | handle (Event *) |
| virtual void | reset () |
Protected Attributes | |
| int | backoff_ |
| double | bandwidth_ |
| int | debug_ |
| int | dobump_ |
| int | dst_ |
| Estimator * | est_ [CLASS] |
| int | rejected_ |
| double | s_ |
| int | src_ |
| double | sump_ |
| Tcl_Channel | tchan_ |
| char * | type_ |
|
|
Definition at line 65 of file actp-adc.cc. References s_, and ADC::type_. 00065 : rejected_(0), sump_(0) 00066 { 00067 bind("s_", &s_); 00068 type_ = new char[5]; 00069 strcpy(type_, "ACTP"); 00070 }
|
|
||||||||||||||||
|
Implements ADC. Definition at line 74 of file actp-adc.cc. References ADC::backoff_, ADC::bandwidth_, Estimator::change_avload(), ADC::dobump_, ADC::est_, ADC::peak_rate(), rejected_, s_, and sump_. 00075 { 00076 //get peak rate this class of flow 00077 double p=peak_rate(cl,r,b); 00078 00079 if (backoff_) { 00080 if (rejected_) 00081 return 0; 00082 } 00083 00084 //fprintf (stderr,"%f %f %f\n",sump_*(1-exp(-p*s_)),exp(-p*s_)*est_[cl]->avload(),est_[cl]->avload()); 00085 if (sump_*(1-exp(-p*s_))+exp(-p*s_)*est_[cl]->avload() <= bandwidth_) { 00086 sump_+= p; 00087 if (dobump_) { 00088 est_[cl]->change_avload(p); 00089 } 00090 return 1; 00091 } 00092 else { 00093 rejected_=1; 00094 return 0; 00095 } 00096 }
Here is the call graph for this function: ![]() |
|
||||||||||||
|
Reimplemented from NsObject. Definition at line 58 of file adc.cc. References NsObject::command(), ADC::est_, ADC::setest(), Estimator::setmeasmod(), Estimator::start(), and ADC::tchan_. 00059 { 00060 00061 Tcl& tcl = Tcl::instance(); 00062 if (argc==2) { 00063 if (strcmp(argv[1],"start") ==0) { 00064 /* $adc start */ 00065 est_[1]->start(); 00066 return (TCL_OK); 00067 } 00068 } else if (argc==4) { 00069 if (strcmp(argv[1],"attach-measmod") == 0) { 00070 /* $adc attach-measmod $meas $cl */ 00071 MeasureMod *meas_mod = (MeasureMod *)TclObject::lookup(argv[2]); 00072 if (meas_mod== 0) { 00073 tcl.resultf("no measuremod found"); 00074 return(TCL_ERROR); 00075 } 00076 int cl=atoi(argv[3]); 00077 est_[cl]->setmeasmod(meas_mod); 00078 return(TCL_OK); 00079 } else if (strcmp(argv[1],"attach-est") == 0 ) { 00080 /* $adc attach-est $est $cl */ 00081 Estimator *est_mod = (Estimator *)TclObject::lookup(argv[2]); 00082 if (est_mod== 0) { 00083 tcl.resultf("no estmod found"); 00084 return(TCL_ERROR); 00085 } 00086 int cl=atoi(argv[3]); 00087 setest(cl,est_mod); 00088 return(TCL_OK); 00089 } 00090 } 00091 else if (argc == 3) { 00092 if (strcmp(argv[1], "attach") == 0) { 00093 int mode; 00094 const char* id = argv[2]; 00095 tchan_ = Tcl_GetChannel(tcl.interp(), (char*)id, &mode); 00096 if (tchan_ == 0) { 00097 tcl.resultf("ADC: trace: can't attach %s for writing", id); 00098 return (TCL_ERROR); 00099 } 00100 return (TCL_OK); 00101 00102 } 00103 if (strcmp(argv[1], "setbuf") == 0) { 00104 /* some sub classes actually do something here */ 00105 return(TCL_OK); 00106 } 00107 00108 00109 } 00110 return (NsObject::command(argc,argv)); 00111 }
Here is the call graph for this function: ![]() |
|
||||||||||||
|
Definition at line 102 of file object.cc. References NsObject::debug_. 00103 { 00104 if (!debug_) 00105 return; 00106 va_list ap; 00107 va_start(ap, fmt); 00108 vprintf(fmt, ap); 00109 }
|
|
||||||||||||||||
|
Reimplemented in BayFullTcpAgent, Agent, MPLSAddressClassifier, LDPAgent, HbAfterRtoSctpAgent, MfrHbAfterRtoSctpAgent, MfrTimestampSctpAgent, MultipleFastRtxSctpAgent, NewRenoSctpAgent, TimestampSctpAgent, SctpAgent, FullTcpAgent, SackFullTcpAgent, RFC793eduTcpAgent, TcpSink, TcpAgent, VegasTcpAgent, XcpAgent, and XcpSink. Definition at line 63 of file object.cc. References NsObject::debug_. Referenced by MPLSAddressClassifier::delay_bind_dispatch(), and Agent::delay_bind_dispatch(). 00064 { 00065 if (delay_bind_bool(varName, localName, "debug_", &debug_, tracer)) 00066 return TCL_OK; 00067 return TclObject::delay_bind_dispatch(varName, localName, tracer); 00068 }
|
|
|
Reimplemented in BayFullTcpAgent, Agent, MPLSAddressClassifier, LDPAgent, HbAfterRtoSctpAgent, MfrHbAfterRtoSctpAgent, MfrTimestampSctpAgent, MultipleFastRtxSctpAgent, NewRenoSctpAgent, TimestampSctpAgent, SctpAgent, FullTcpAgent, SackFullTcpAgent, RFC793eduTcpAgent, TcpSink, TcpAgent, VegasTcpAgent, XcpAgent, and XcpSink. Definition at line 57 of file object.cc. Referenced by MPLSAddressClassifier::delay_bind_init_all(), and Agent::delay_bind_init_all().
|
|
|
Implements Handler. Reimplemented in LinkDelay, LL, AckRecons, and Snoop. Definition at line 91 of file object.cc. References NsObject::recv().
Here is the call graph for this function: ![]() |
|
|
Definition at line 61 of file object.h. References NsObject::debug_. 00061 { return debug_; }
|
|
||||||||||||||||
|
Definition at line 60 of file adc.h. References ADC::est_, and Estimator::period(). Referenced by HB_ADC::admit_flow(), admit_flow(), ACTO_ADC::admit_flow(), MSPK_ADC::get_rate(), HB_ADC::rej_action(), rej_action(), HB_ADC::teardown_action(), and teardown_action().
Here is the call graph for this function: ![]() |
|
||||||||||||
|
Reimplemented in CMUTrace. Definition at line 96 of file object.cc. References Packet::free(). 00097 { 00098 Packet::free(p); 00099 }
Here is the call graph for this function: ![]() |
|
||||||||||||
|
Implements NsObject. Definition at line 57 of file adc.h.
|
|
|
Reimplemented in Agent, and Trace. Definition at line 56 of file object.h. Referenced by Trace::recvOnly().
|
|
||||||||||||||||
|
Reimplemented from ADC. Definition at line 99 of file actp-adc.cc. References ADC::peak_rate(), and sump_.
Here is the call graph for this function: ![]() |
|
|
Reimplemented in BayFullTcpAgent, HashClassifier, IvsSource, dsREDQueue, DiffusionRate, SinkAgent, DiffusionAgent, FloodingAgent, OmniMcastAgent, LinkDelay, CBQueue, DropTail, ErrorModel, PIQueue, Queue< T >, RedPDQueue, REDQueue, REMQueue, RIOQueue, Snoop, FackTcpAgent, FullTcpAgent, SackFullTcpAgent, RFC793eduTcpAgent, Sack1TcpAgent, TcpSink, DelAckSink, TcpAgent, VegasTcpAgent, toraAgent, Queue< T >, and XcpSink. Definition at line 70 of file object.cc. Referenced by NsObject::command().
|
|
||||||||||||
|
Definition at line 58 of file adc.h. References ADC::est_, Estimator::setactype(), and ADC::type_. Referenced by ADC::command().
Here is the call graph for this function: ![]() |
|
||||||||||||||||
|
Reimplemented from ADC. Definition at line 106 of file actp-adc.cc. References ADC::peak_rate(), rejected_, and sump_.
Here is the call graph for this function: ![]() |
|
|
Definition at line 61 of file adc.h. References ADC::type_. Referenced by SALink::command(), and SALink::trace(). 00061 {return type_;}
|
|
|
Definition at line 69 of file adc.h. Referenced by ADC::ADC(), HB_ADC::admit_flow(), admit_flow(), and ACTO_ADC::admit_flow(). |
|
|
Definition at line 64 of file adc.h. Referenced by ADC::ADC(), Param_ADC::admit_flow(), MS_ADC::admit_flow(), HB_ADC::admit_flow(), admit_flow(), and ACTO_ADC::admit_flow(). |
|
|
Reimplemented in FECModel, FloodAgent, and LandmarkAgent. Definition at line 66 of file object.h. Referenced by REDQueue::command(), RedPDQueue::command(), PushbackQueue::command(), NsObject::debug(), NsObject::delay_bind_dispatch(), PushbackQueue::enque(), NsObject::isdebug(), NsObject::NsObject(), TfrcAgent::recv(), PushbackQueue::reportDrop(), SctpAgent::Reset(), REDQueue::reset(), DropTail::shrink_queue(), and Delayer::try_send(). |
|
|
Definition at line 70 of file adc.h. Referenced by ADC::ADC(), admit_flow(), and ACTO_ADC::admit_flow(). |
|
|
Definition at line 68 of file adc.h. Referenced by ADC::ADC(), and Param_ADC::trace(). |
|
|
Definition at line 63 of file adc.h. Referenced by MS_ADC::admit_flow(), HB_ADC::admit_flow(), admit_flow(), ACTO_ADC::admit_flow(), ADC::command(), ADC::peak_rate(), MS_ADC::rej_action(), and ADC::setest(). |
|
|
Definition at line 60 of file actp-adc.cc. Referenced by admit_flow(), and teardown_action(). |
|
|
Definition at line 61 of file actp-adc.cc. Referenced by ACTP_ADC(), and admit_flow(). |
|
|
Definition at line 67 of file adc.h. Referenced by ADC::ADC(), and Param_ADC::trace(). |
|
|
Definition at line 62 of file actp-adc.cc. Referenced by admit_flow(), rej_action(), and teardown_action(). |
|
|
Definition at line 66 of file adc.h. Referenced by ADC::command(), and Param_ADC::trace(). |
|
|
Definition at line 65 of file adc.h. Referenced by ACTO_ADC::ACTO_ADC(), ACTP_ADC(), HB_ADC::HB_ADC(), MS_ADC::MS_ADC(), Param_ADC::Param_ADC(), ADC::setest(), Param_ADC::trace(), and ADC::type(). |
1.4.6