[Click] AlignmentInfo Question

Eddie Kohler kohler at cs.ucla.edu
Mon Mar 26 13:05:08 EST 2007


Hi Bill,

I guess you are not running on an x86-compatible machine?  On x86, there 
is no penalty to accessing a word that isn't aligned; on non-x86 it can 
cause a crash.  The "click-align" tool is made to introduce 
AlignmentInfo elements that inform elements of what alignment they 
should expect.  Rather than "click FILE.click", try "click-align 
FILE.click | click".

Eddie


Fischofer William-B09792 wrote:
> I have the following elementclass:
>  
> elementclass TrafficClassifier {
>    $interface |
>    input ->
>    c0 :: Classifier (12/0806 20/0001,            // ARP Requests
>                           12/0806 20/0002,            // ARP Replies
>                           12/0800,                        // IPv4
> Packets
>                            -);                                 //
> Everything else
>    c0[0] -> [0]output;
>    c0[1] -> [1]output;
>    c0[2] -> [2]output;
>    c0[3] -> ToHost($interface);                    // Send all
> "uninteresting" traffic to host
> }
>  
> Which is then used as follows:
>  
> FromDevice(eth0) -> tc0::TrafficClassifier(eth0);
> FromDevice(eth1) -> tc1::TrafficClassifier(eth1);
> ...etc.
>  
> However this results in the following error messages from Click:
>  
> While configuring 'tc0/c0 :: Classifier':
>   no AlignmentInfo available: you may experience unaligned accesses
>  
> I'm not quite sure what this means or what I should do about it.  I can
> make the message go away if I
> insert the line:
>  
> AlignmentInfo(Classifier 4 0);  // Seems to work but is this what I
> really need?
>  
> Into my TrafficClassifier definition but I'd like to understand what's
> really going on here.  The online docs are pretty terse in this
> area.  Any reading suggestions for better understanding this stuff?
>  
> Thanks much.
>  
> Bill Fischofer
> _______________________________________________
> click mailing list
> click at amsterdam.lcs.mit.edu
> https://amsterdam.lcs.mit.edu/mailman/listinfo/click


More information about the click mailing list