If I could have talked to him, I would have told him not to come. I knew that the conference would be very boring.
Could have, because I am describing something that could possibly have happened in the past, but did not: third conditional.
Would be, because I am describing the future from the perspective of that past time: second conditional.