The issue comes from the fact `synchronize()` is called in `set()` but not in `setvalueref()`; you need to call it explicitly. 
I guess a wrapper of `synchronize()` like `synchronize(MCExecContext& ctxt, Boolean p_notify)` would come handy