amnuts / opcache-gui

A clean, effective and responsive interface for Zend OPcache
1.21k stars 197 forks source link

jit expansion #79

Closed javiergutierrezchamorro closed 2 years ago

javiergutierrezchamorro commented 2 years ago

There are a few macros for opcache.git:

Would be nice if opcache-gui could expand any of these values showing also is description. For instance tracing will be:

MichaIng commented 2 years ago

The GUI shows the related directives, of course when these are available at all (i.e. PHP8.0 or above running): jit

Or do you mean to have a description of what e.g. tracing means directly in the GUI? I think the added maintenance for this is not worth the outcome, given that you can simply click the directive to get to the official PHP docs which explains everything precisely: https://www.php.net/manual/en/opcache.configuration.php#ini.opcache.jit

javiergutierrezchamorro commented 2 years ago

Thanks. Yes, I was refering to the second point, and understand your thought. Even so, their equivalents could change from one PHP version to another.

MichaIng commented 2 years ago

I wonder whether there are PHP-versioned docs available, cannot find it currently, but I think I remember seeing a page with a banner at the top that it's not the latest PHP version 🤔. However, if behaviour of a directive changes, there is usually a note in the Changelog column of the config list and sometimes also further notes in the dedicated directive section.

amnuts commented 2 years ago

I think that if it's just a description of the advanced usage for the opcache.jit, ie, if someone has used a numeric value rather than tracing, off, etc., then I'm OK with adding it. I would have a similar maintenance overhead with the optimization levels which are fairly hardcoded from the PHP source, so see no real difference with the CRTO values. I think I would just leave tracing, etc., if someone has put in those values and not try to convert them to the more expanded equivalent, though.

So leave it with me and I'll add it when I get some time.

amnuts commented 2 years ago

😂 Well, it seems I'm ahead of myself as I already have the jit expansion in there and just forgot about it 😆

image

MichaIng commented 2 years ago

Ah nice. Then I guess showing the same when the shortcuts are used wouldn't be much overhead? But I agree, if one does not touch the setting or uses a shortcut, then the explanation of the effective optimisation levels is probably not required (and causes probably more confusing as of the bunch of key words and abbreviations thrown in 😄), and that the settings key is a link to related docs is sufficient.

amnuts commented 2 years ago

The confusion was my reasoning for not expanding the tracing, etc. If someone manually put in the value into their ini file and then in the gui it showed a lot more and nothing what they entered, then I can imagine it being odd and them wondering what was wrong with the gui. 😉

amnuts commented 2 years ago

But in saying that, I could always show the value and then expand upon it underneath - best of both worlds 😁

amnuts commented 2 years ago

This is what it now does:

image

image

image

will push a branch and do merges in a bit.

MichaIng commented 2 years ago

Little suggestion: Probably it is possible to visually separate the applied value and the description of the optimisation levels a bit? Also for consistency the applied numerical value could then also be shown.

amnuts commented 2 years ago

I'll give it a whirl with the spacing. The way it renders the directive values is pretty fixed, but I'll have a swing at it.

And yeah, that's a good point about the numeric value being shown - will add that. 👍

amnuts commented 2 years ago

Ah, yeah, this is a little more consistent now and with some spacing...

image

image

amnuts commented 2 years ago

Fixed with the release of 3.3.1