Who does the price-matching when placing trades?

The stock exchange does the price matching for orders placed by investors like you. The exchange uses an electronic order matching system that matches buy and sell orders for a stock market, commodity market, or other financial exchange.  The order matching system is at the core of all electronic exchanges and is used to execute orders from the participants of the exchange.