Repeat after me: do not mess with the system toolchain.
Upgrading to Slack12 will give you gcc 4.1.2, linked against glibc 2.5 . Off the top of my head I don't know what the requirements to build gcc 4.x.x are, but it is usually possible (if you didn't want to upgrade to 12, for whatever reason) to build another compiler with the libs you already have provided there isn't too much difference between them, as duryodhan mentioned. 3.3.6 -> 4.x.x is doable; 2.95.0 -> 4.x.x is probably not =)
Take a look at the slackbuild script for gcc (the one script generates all the gcc packages) if you want to look at building your own without rebuilding the whole system. For your convenience, here's a link straight to the directory where it's located (through my favourite mirror - adjust as necessary!):
http://ftp.heanet.ie/mirrors/ftp.sla..._source/d/gcc/
The only thing you should be aware of is that when calling a compiler that's installed in a non-standard (ie: outside of your path) place, you need to tweak your environment to ensure you're actually using the right compiler.
Good luck,
- Piete.