The US Immigration and Customs Service have a large area within DUB Airport where it is done. I think you will be "entering the Republic" but, at present, that is entirely straightforward since UK and R0I are in EU. If Brexit proceeds, and your travel date is afterwards, there may be some extra checks between UK and RoI but, given the Common Travel Agreement (if it continues as stated), that should be minimal. There is a new transit centre being built which should accommodate that type of transfer but I don't know when it is to be operational.