There is likely a bug in the odph checksumming functions as well. Due
to the casts to void ptr and function inlining, the compiler can
reorder memory accesses (e.g. move stored to the headers after the
checksumming has been performed). The compiler does not know that
these pointers alias each other (because the pointers have different
types and by the C definition, such pointers do no alias each other).

We need a static_cast type of operator which includes the necessary
compiler barriers which prevent the compiler from reordering memory
accesses over the cast.

On 7 January 2015 at 19:14, Ciprian Barbu <[email protected]> wrote:
> Hi,
>
> I was running the odp_pktio example when I observed a lot of dropped
> frames reported with errors. I described the problem in some level of
> detail here: https://bugs.linaro.org/show_bug.cgi?id=1035
>
> But in a few words, I reversed the order of hl and rsvd3 in
> odph_tcphdr_t structure and I get no more errors.
>
> Can someone else check the example see if they get those errors?
>
> /Ciprian
>
> _______________________________________________
> lng-odp mailing list
> [email protected]
> http://lists.linaro.org/mailman/listinfo/lng-odp

_______________________________________________
lng-odp mailing list
[email protected]
http://lists.linaro.org/mailman/listinfo/lng-odp

Reply via email to