First, appreciate that glass expands as it heats and shrinks as it cools. This is different than water and ice, where water expands as it forms ice.
Second, compression means that the environment surrounding a material is pushing inward on it (making the equilibrium position of the atoms closer together than they would be without the external compression), and tension means that the environment is pulling outward on it (making the equilibrium position of the atoms farther apart than they would be without the external tension).
Third, glass deforms plastically at high temperatures and gradually becomes more rigid as its temperature drops. A plastic deformation will not result in internal stresses (compression or tension), but applying strain to a rigid material will.
Now, picture a pane (or a drop) of glass, initially at a uniformly high temperature, as it cools from the outside. The outer layer cools first, hence shrinks first, plastically at first, then rigidly. The inner layer stays hotter and hence plastic for longer, so it plastically deforms to adjust to the now-cooler (and shrunken) outer layer. Then, the inner layer cools and contracts, but it is no longer able to deform plastically. So, as it contracts, it pulls on the outer layer (parallel to the surface), putting the outer layer in compression and the inner layer in tension.
I have an excellent human-scale example of this. My wife loves to have her back stretched out (put in tension). Often when she hugs me, she also lifts her feet off the floor, hence my back is supporting both her weight and mine. This puts my back in compression (analogous to the outer layer of tempered glass) and her back in tension (analogous to the inner layer of tempered glass).
Then, since glass is stronger when it is in compression, tempered glass is overall stronger than untempered glass. Although if a crack reaches the inner layer, it propagates very quickly, resulting in near-complete shattering of the entire pane of glass.