| Comment | File | Size | Author |
|---|---|---|---|
| #7 | XHProf__Hierarchical_Profiler_Report.png | 232.87 KB | joelpittet |
| #6 | inline_endswith-2653224-6.patch | 1.68 KB | joelpittet |
| #6 | interdiff.txt | 1.24 KB | joelpittet |
| #2 | inline_endswith-2653224-2.patch | 1.34 KB | joelpittet |
| XHProf__Hierarchical_Profiler_Report.png | 228.16 KB | joelpittet |

Comments
Comment #2
joelpittetRemoved the two private functions as they aren't being used.
Comment #3
joelpittetComment #4
david_garcia commentedJust an observation... 80ms out of ~2500 function calls looks to me more profiler overhead than real savings.
The truth is that views_filters_selective_views_data_alter() gets slower as more fields you have declared to views.
Briniging this micro optimization to the limit I would have liked to see something like this:
But no worries, your patch is more than good. I'll commit it soon.
Comment #5
joelpittetThanks @david_garcia.
The
preg_grep()you have there looks a bit off, shouldn't the$be at the end? And should delta check be removed? What is$default?Was playing around with it and wasn't getting what I expected so did a variation on that with
preg_matchthat I think would work, hopefully I was following what you were suggesting.Comment #6
joelpittetIt does have a performance improvement over my original idea so I like that:) I usually don't write off too many things on profiler overhead. Do you have variance that you write-off?
Found a flag to inverse the
preg_grep(). So that avoids thearray_flip()/array_diff_key()calls from #5Comment #7
joelpittetSaved another ~5ms from that change, hopefully my
preg_foo()is right.Comment #9
david_garcia commentedCommited!
I believe that it is impossible to scrap even a microsecond from your last implementation proposal.
My code from #4 was just written on the fly as a POC - I had the idea of using php array related functions to deal with arrays - that's what they are here for.
Thanks!
Comment #10
joelpittetCool, thanks @david_garcia