Re: [PATCH net-next] ipv6: Implement optimized IPv6 masked address comparison for ARM64

2017-03-17 Thread Subash Abhinov Kasiviswanathan
That's clearly not right - I'm not sure quite what undefined behaviour assumption convinces GCC to optimise the whole thing away> While the pointer casting is a bit ghastly, I don't actually think that GCC is taking advantage of undefined behaviour here, rather it looks like you have a simpl

Re: [PATCH net-next] ipv6: Implement optimized IPv6 masked address comparison for ARM64

2017-03-17 Thread James Greenhalgh
On Fri, Mar 17, 2017 at 12:00:42PM +, Robin Murphy wrote: > On 17/03/17 04:42, Subash Abhinov Kasiviswanathan wrote: > > Android devices use multiple ip[6]tables for statistics, UID matching > > and other functionality. Perf output indicated that ip6_do_table > > was taking a considerable amoun

Re: [PATCH net-next] ipv6: Implement optimized IPv6 masked address comparison for ARM64

2017-03-17 Thread Robin Murphy
On 17/03/17 04:42, Subash Abhinov Kasiviswanathan wrote: > Android devices use multiple ip[6]tables for statistics, UID matching > and other functionality. Perf output indicated that ip6_do_table > was taking a considerable amount of CPU and more that ip_do_table > for an equivalent rate. ipv6_mask

[PATCH net-next] ipv6: Implement optimized IPv6 masked address comparison for ARM64

2017-03-16 Thread Subash Abhinov Kasiviswanathan
Android devices use multiple ip[6]tables for statistics, UID matching and other functionality. Perf output indicated that ip6_do_table was taking a considerable amount of CPU and more that ip_do_table for an equivalent rate. ipv6_masked_addr_cmp was chosen for optimization as there are more instruc