In other words, are the scenarios different performance-wise?
A:
for($i = 0; $i < 10; $i++)
{
$pdo->prepare("SELECT :foo;")->execute(['foo' => 'test']);
}
B:
$sth = $pdo->prepare("SELECT :foo;");
for($i = 0; $i < 10; $i++)
{
$sth->execute(['foo' => 'test']);
}