I have only studied at Trinity, so cant comment on Galway in terms of academics. Trinity is well known and generally seen as the best uni in ireland (know UCD is rank highly though), particularly in terms of lecturer expertise and organisation (I did Psychology). However, as a city i dont think its great, and it is the most expensive city in europe, so definitely factor that into your cost evaluations. Galway is expensive also but not on the same level. Galway is a much smaller and touristy/student focused city, so definitely a nicer place to live. Dublin is less friendly, which comes with much bigger places generally. However, dublin is more diverse in terms of people, race etc, whereas Galway is more traditional in terms of demographics and perhaps attitudes also.
I dont know where you are from in terms of family/supports though. If you are from UK you will be much further awat from major transport hubs to go home of so, as galway does not have a major airport, so would be shannon or knock (2 ish hours for either), whereas dublin has ports and the international airport also.
If i had a choice again I would probably choose Galway as closer to my family and overall a much nicer place to live. Trinity was really good though in terms of experience and student support, but it is not worth it in terms of location. Any despite my comment on trinitys prestige, like most unis, people are impressed by it but does not open any more doors for you.