Skip to content
GitLab
Menu
Why GitLab
Pricing
Contact Sales
Explore
Why GitLab
Pricing
Contact Sales
Explore
Sign in
Get free trial
Changes
Page history
Update ShiftAnalysis
authored
Jun 29, 2018
by
Chris Cox
Show whitespace changes
Inline
Side-by-side
ShiftAnalysis.md
View page @
790ab0be
...
@@ -165,19 +165,42 @@ number time per second test0
...
@@ -165,19 +165,42 @@ number time per second test0
14 "int64_t variable mask low" 16.45 sec 2918.53 M 11.20
14 "int64_t variable mask low" 16.45 sec 2918.53 M 11.20
15 "int64_t variable mask low by shift" 26.89 sec 1784.96 M 18.31
15 "int64_t variable mask low by shift" 26.89 sec 1784.96 M 18.31
```
```
*
Wow, the variable mask low operations are
NOT
being optimized correctly!
*
Wow, the variable mask low operations are
not
being optimized correctly!
*
How the heck are the unsigned mask operations slower?
*
How the heck are the unsigned mask operations
so much
slower?
### Constant Mask High
### Constant Mask High
```
```
test description absolute operations ratio with
number time per second test0
0 "uint8_t constant mask high" 1.06 sec 45481.12 M 1.00
1 "uint8_t constant mask high by shift" 1.05 sec 45609.90 M 1.00
2 "uint16_t constant mask high" 2.10 sec 22910.38 M 1.99
3 "uint16_t constant mask high by shift" 2.09 sec 22994.96 M 1.98
4 "uint32_t constant mask high" 5.86 sec 8186.49 M 5.56
5 "uint32_t constant mask high by shift" 5.86 sec 8186.69 M 5.56
6 "uint64_t constant mask high" 16.45 sec 2918.43 M 15.58
7 "uint64_t constant mask high by shift" 16.43 sec 2920.61 M 15.57
```
```
*
*
These look good.
### Variable Mask High
### Variable Mask High
```
```
test description absolute operations ratio with
number time per second test0
0 "uint8_t variable mask high" 1.06 sec 45269.22 M 1.00
1 "uint8_t variable mask high by shift" 24.66 sec 1946.68 M 23.25
2 "uint16_t variable mask high" 2.09 sec 22933.16 M 1.97
3 "uint16_t variable mask high by shift" 24.69 sec 1943.74 M 23.29
4 "uint32_t variable mask high" 5.88 sec 8166.26 M 5.54
5 "uint32_t variable mask high by shift" 25.43 sec 1887.30 M 23.99
6 "uint64_t variable mask high" 16.61 sec 2889.74 M 15.67
7 "uint64_t variable mask high by shift" 27.18 sec 1766.01 M 25.63
```
```
*
*
And the variable mask high operations are unoptimized, just like the mask low case.
-------
-------
...
@@ -215,4 +238,3 @@ number time per second test0
...
@@ -215,4 +238,3 @@ number time per second test0