[Click] Free user annotations?

Bart Braem bart.braem at ua.ac.be
Wed Jan 11 11:08:27 EST 2006


Hello,

We would like to use user annotations. But it seems there are no more free 
user annotations. All user annotations seem to be used in packet-anno.hh, 
which led to a large crash in ToDump in one of our scripts...
Most probably increasing the user annotation size will solve this problem at 
the moment but perhaps more a general solution should be used. 
We propose the following:
Each element that wants to use annotations uses a macro e.g. REQUIRE_ANNO with 
two parameters: the annotation length (in bytes) and the annotation name e.g. 
ICMP_PARAMPROB. 'make annolist' will then generate the annotation struct for 
the packet (annotation.hh which is included in each packet). annotation.hh 
also contains the generated getter name_ANNO e.g. ICMP_PARAMPROB_ANNO(p) and 
the generated setter SET_ICMP_PARAMPROB_ANNO(p). Both use the pointer offsets 
safely calculated at compile time.
Do you think this would do the job? If we are right this might forever solve 
the problem of user annotations. We still have a problem if this solution is 
used. Precompiling the annotations will add all annotations to the packets, 
including the ones never used. This might introduce a very large overhead. 

Comments welcome,
Bart, Michael and Nico
-- 
PATS research group
Dept. of Mathematics and Computer Sciences
University of Antwerp
G2.36, Building G
Middelheimlaan 1
2020 Antwerpen, Belgium
Phone: +32 (0)3 265.35.19.
Fax: +32 (0)3 265.37.77.
Web: www.pats.ua.ac.be
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 307 bytes
Desc: not available
Url : https://amsterdam.lcs.mit.edu/pipermail/click/attachments/20060111/026a7b79/attachment.pgp


More information about the click mailing list