perf: Remove bool_val from Parquet Thrift FieldIdentifier - #9945
Conversation
|
run benchmark metadata |
|
🤖 Arrow criterion benchmark running (GKE) | trigger CPU Details (lscpu)Comparing thrift_bool (92eb8a7) to c2021f1 (merge-base) diff File an issue against this benchmark runner |
|
🤖 Arrow criterion benchmark completed (GKE) | trigger Instance: CPU Details (lscpu)Details
Resource Usagebase (merge-base)
branch
File an issue against this benchmark runner |
bool_val from Parquet Thrift FieldIdentifierbool_val from Parquet Thrift FieldIdentifier
|
run benchmark metadata |
|
🤖 Arrow criterion benchmark running (GKE) | trigger CPU Details (lscpu)Comparing thrift_bool (1081e7a) to 6ce4bc8 (merge-base) diff File an issue against this benchmark runner |
|
🤖 Arrow criterion benchmark completed (GKE) | trigger Instance: CPU Details (lscpu)Details
Resource Usagebase (merge-base)
branch
File an issue against this benchmark runner |
|
bench results look weird. On x86 WS got |
|
run benchmark metadata |
|
run benchmarks metadata |
alamb
left a comment
There was a problem hiding this comment.
The code certainly looks nicer in my mind ❤️
I agree we should sort out the benchmarks
|
Benchmarks seem not to be working. Maybe related to this |
|
run benchmark metadata |
|
🤖 Arrow criterion benchmark running (GKE) | trigger CPU Details (lscpu)Comparing thrift_bool (f58ff9b) to 7abb225 (merge-base) diff File an issue against this benchmark runner |
|
adriangb/datafusion-benchmarking#7 seems to have fixed benchmarks |
|
🤖 Arrow criterion benchmark completed (GKE) | trigger Instance: CPU Details (lscpu)Details
Resource Usagebase (merge-base)
branch
File an issue against this benchmark runner |
|
run benchmark metadata |
|
🤖 Arrow criterion benchmark running (GKE) | trigger CPU Details (lscpu)Comparing thrift_bool (00326ea) to 7abb225 (merge-base) diff File an issue against this benchmark runner |
|
🤖 Arrow criterion benchmark completed (GKE) | trigger Instance: CPU Details (lscpu)Details
Resource Usagebase (merge-base)
branch
File an issue against this benchmark runner |
|
run benchmark metadata |
|
🤖 Arrow criterion benchmark running (GKE) | trigger CPU Details (lscpu)Comparing thrift_bool (99de981) to 7abb225 (merge-base) diff File an issue against this benchmark runner |
|
🤖 Arrow criterion benchmark completed (GKE) | trigger Instance: CPU Details (lscpu)Details
Resource Usagebase (merge-base)
branch
File an issue against this benchmark runner |
|
I ran the benchmarks locally on my machine (Intel Tigerlake), and this branch seems to be around 5% faster on all metadata benchmarks, compared to |
Same, but all on intel as well. I've been playing around on godbolt and honestly do not understand why there's any difference at all. However I write let field_type = self.read_byte()?;
if field_type == 0 {
// exit early
} else if field_type < 16 { // unlikely
// read full i16 field_id and return
} else {
// compute field_id from delta and return
}Lacking an aarch64 machine to profile on, it's hard to see why the benchmarks here are so different. It's possible that the difference comes from either the new |
|
run benchmark metadata |
|
🤖 Arrow criterion benchmark running (GKE) | trigger CPU Details (lscpu)Comparing thrift_bool (876fc37) to 1ffd202 (merge-base) diff File an issue against this benchmark runner |
|
🤖 Arrow criterion benchmark completed (GKE) | trigger Instance: CPU Details (lscpu)Details
Resource Usagebase (merge-base)
branch
File an issue against this benchmark runner |
alamb
left a comment
There was a problem hiding this comment.
I think this is fine and we have done enough diligence
I can turn an agent loose to try and test on an aarch machine and figure out what is going on. However, this seems perhaps unecessary
|
Thanks @alamb. I'll see if I can hunt up some AWS time and see if this is really a thing on ARM. |
I can provide access to an AWS machine -- DM or email me a public SSH key and i'll setup one for you to test on |
Ooh, awesome! Thanks! Just sent you one via email. |
|
Running manually on an ARM instance picked the best run of the current main branch vs 2 runs of this branch. I think we can conclude it's just noise, and if there is a difference it's not really showing up strongly (although on x86 there's a definite advantage to this branch). Thanks @alamb! |
|
Thanks for the diligence everyone. This is great |
…#9945) # Which issue does this PR close? - Closes apache#9946. # Rationale for this change Remove some unnecessary branching from a hot path in the Thrift parser, improving performance and making for easier to read code. # What changes are included in this PR? Removes the `bool_val` field from `FieldIdentifier`. # Are these changes tested? Covered by existing tests # Are there any user-facing changes? No, this is an internal-only API
Which issue does this PR close?
Rationale for this change
Remove some unnecessary branching from a hot path in the Thrift parser, improving performance and making for easier to read code.
What changes are included in this PR?
Removes the
bool_valfield fromFieldIdentifier.Are these changes tested?
Covered by existing tests
Are there any user-facing changes?
No, this is an internal-only API