update palette register only on change, otherwise use the cached value