I would love to see some testing on this.
If we're talking about a stretch of road like the picture above (not as steep though), in general, all other things being equal with no stop signs/stop lights/traffic/etc., I pulse downhill and glide uphill. Pulsing uphill uses much more fuel than pulsing downhill. I rarely make up fuel spent from accelerating uphill on the descent even while in DFCO sometimes, but I do make up the fuel spent pulsing downhill while coasting uphill. To be exact, I don't always coast in neutral uphill unless I can make it to the top, but I do try to decelerate all the way to the top.
For this reason, I also accelerate more on a flat stretch if I'm approaching a hill so I don't have to accelerate while on the hill.
With that said, it all depends. All hills are different with many variables thrown in the mix.
I haven't done actual testing on this, but based on my ScanGauge readings, I get better mpg doing these things.