Pipe noises are also caused by a valve closing very slowly allowing water to pass through the very constricted valve opening at the end of the fill cycle. Think of letting the air of a balloon while holding the opening nearly closed. Makes noise. This is also solved by replacing the old valve with a fluidmaster which will close faster and more completely than an old worn ballcock valve.