Optimize derived buffers' forEachByte(...) implementation

- Related: #1378