The B20B came in a few different versions. There’s a low compression one, a high compression one, and a third variant with the P8R head.
Distinguishing a low comp engine from a high comp engine is a little tricky since they don’t have any obvious markings but there is two things you can check. The first is if the block has a knock sensor, and the second is if the pistons are marked with PHK.
Knock Sensor
If a B20B has a knock sensor on the backside of the block just below the intake manifold it’s a high compression model.
In the picture above, the knock sensor is the plug below cyl 2’s intake port and just above the water pipe. The sensor is usually brown, but may appear black if it still has the connector on it.
Low compression models won’t have this sensor but they will have a partially drilled hole where the sensor would go.
PHK Pistons
This isn’t as easy to check since you’ll need to somehow peek at the top of the pistons either with a borescope or by pulling the head.
High compression B20Bs will have “PHK” stamped on the pistons.
Low compression B20Bs will have “P3F” stamped on the pistons.