>>106223730
aerith, a cod mobile streamer. shes gotten fat recently
>>106220411
go research the michael abrash quote "the fastest optimizer is between your ears". back in the day, optimization used to mean "lowering the number of instructions/cycles used". but even back then in the days of yore, it still wasn't a straight forward calculation because even though some programs had less cycles on paper, they still took longer to run because of how the cpu pipelined (aka fetched and ordered) the instructions themselves. thus abrash posited that we should spend almost all of our time thinking of entirely new algorithmic approaches, and new, more compact ways of representing the data, rather than hand optimizing individual instructions in place based on the current algorithm, which is almost certainly a local minima
fast forward to today, we have the same situation, but much worse. first of all, even if you are getting extremely accurate timings from your gpu, you would be better off testing bulk invocations of shader(s) rather than one invocation. that will smooth out the jitter and noise, and you will no longer need to measure in microseconds.
second of all, you should be searching for ways to either A) completely avoid doing any work on effects that are visually worse AND slower, or B) acceptably approximate an effect while being very clearly faster, such as double or etc. a good example of this would be an LOD system, only drawing nearby lights through some kind of sectoring system, shading large boring objects with extremely cheap materials, making certain dynamic objects and dynamic lights cast shadows while the rest dont, turning path tracing into a "many lights" problem and using traditional hardware instead...