use reference to base layer instead of copy in rmm tree
implement next smaller value (nsv) on RMMTree