In Ri, shaders are bound the last active Bxdf. In this case, two difference Bxdfs named "disney1" are bound to two different spheres.
Because attribute and transformation hierarchies often don't match material hierarchies, material network may be duplicated in Ri streams. In the above example, the two Bxdfs are identical. RenderMan provides a special "string __materialid" mechanism to identify and re-bind to previously emitted materials. In this case, a single "disney1" material network is emitted but bound to two different spheres. The same "string __materialid" parameter can use used to identify and deduplicate RiBxdf, RiLight, and RiDisplace shading networks.
The same mechanism can be used to late bind materials inside Ri procedurals. In this case, a sphere is bound to material "PxrDiffuse1SG".