Re: [dev-servo] RFC: Using fixed-point for percentages

2014-04-17 Thread Simon Sapin
On 15/04/2014 06:00, Patrick Walton wrote: I'm considering using 32-bit fixed-point (16 bits for the fraction, 16 bits for the integer portion) for percentages in CSS. How should numbers (and dimensions and percentages) be represented in the CSS parser? Do you still see performance benefits wh

Re: [dev-servo] RFC: Using fixed-point for percentages

2014-04-16 Thread Patrick Walton
On 4/16/14 1:11 AM, Simon Sapin wrote: On 15/04/2014 06:00, Patrick Walton wrote: Hi everyone, I'm considering using 32-bit fixed-point (16 bits for the fraction, 16 bits for the integer portion) for percentages in CSS. The reason is that we can use the following four SSE4/AVX instructions on x

Re: [dev-servo] RFC: Using fixed-point for percentages

2014-04-16 Thread Simon Sapin
On 15/04/2014 06:00, Patrick Walton wrote: Hi everyone, I'm considering using 32-bit fixed-point (16 bits for the fraction, 16 bits for the integer portion) for percentages in CSS. The reason is that we can use the following four SSE4/AVX instructions on x86 to compute two sides at once: ;

Re: [dev-servo] RFC: Using fixed-point for percentages

2014-04-15 Thread Brian Anderson
Right now rustc has no option to detect CPU features, and advanced features must be enabled explicitly. It seems reasonable to start adding some basic feature detection to rustc as needed. On 04/15/2014 07:15 PM, Jack Moffitt wrote: Assuming this is enough precision for layout, I'd like to see

Re: [dev-servo] RFC: Using fixed-point for percentages

2014-04-15 Thread Jack Moffitt
Assuming this is enough precision for layout, I'd like to see neon versions before we landed anything like this. Will the API a user sees look the same? In other words, is the change localized to MaybeAuto's implementation? Also, speaking of these SIMD optimizations, does rustc have a compiler fla

[dev-servo] RFC: Using fixed-point for percentages

2014-04-14 Thread Patrick Walton
Hi everyone, I'm considering using 32-bit fixed-point (16 bits for the fraction, 16 bits for the integer portion) for percentages in CSS. The reason is that we can use the following four SSE4/AVX instructions on x86 to compute two sides at once: ; xmm0 contains the style values (percentag