Most clams that like to attach to rocks such as crocea will extend a bit of specialized mantle out of their byssal opening, this mantle secretes an acid that will dissolve calcium carbonate structures to provide the clam with room to grow. This part of the mantle is usually large enough to reach out of the bottom and all the way to the top of the clam.
Sometimes however some parts of the rock are too hard to dissolve, and the clam ends up with a deformed shell, this normally does not hurt the clam.