Commercial ice cream from reputable brands is considered safe during pregnancy. It's made from pasteurized milk and eggs, eliminating the Listeria and Salmonella concerns that apply to unpasteurized dairy and raw eggs.
The caution areas: soft-serve from machines (bacterial growth risk in dispensers), homemade ice cream with raw eggs, and ice cream from small/artisanal producers that may use unpasteurized dairy.